[Mesa-dev] [PATCH] meta: Eliminate samplers[] array in favor of using vec4_prefix.

Eric Anholt eric at anholt.net
Fri Feb 21 19:00:20 PST 2014


Kenneth Graunke <kenneth at whitecape.org> writes:

> We don't need an array mapping the shader index to "sampler2DMS",
> "isampler2DMS", and so on.  We can simply do "%ssampler2DMS" and pass in
> vec4_prefix, which is "", "i", or "u".
>
> This eliminates the use of C99 array initializers and should fix the
> MSVC build.
>
> Cc: Vinson Lee <vlee at freedesktop.org>
> Cc: Eric Anholt <eric at anholt.net>
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=75344
> Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>

I was just thinking about this array today, and the thing we'll need to
add at some point is sampler2DMSArray to handle MSAA blits from that (do
we even have tests for blits with texture_multisample arrays?), but we
could do that with just a one-off check on the target and appending
"Array".

Reviewed-by: Eric Anholt <eric at anholt.net>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 818 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20140221/0278780a/attachment.pgp>


More information about the mesa-dev mailing list