Paul Berry <stereotype...@gmail.com> writes:

> On 26 November 2013 00:02, Francisco Jerez <curroje...@riseup.net> wrote:
>
>>
>> +enum glsl_image_dim {
>> +   GLSL_IMAGE_DIM_1D,
>> +   GLSL_IMAGE_DIM_2D,
>> +   GLSL_IMAGE_DIM_3D,
>> +   GLSL_IMAGE_DIM_RECT,
>> +   GLSL_IMAGE_DIM_CUBE,
>> +   GLSL_IMAGE_DIM_BUFFER,
>> +   GLSL_IMAGE_DIM_MS
>> +};
>> +
>>
>
> glsl_image_dim seems redundant  with glsl_sampler_dim (they are identical
> except that the order is different, and glsl_sampler_dim includes the extra
> value GLSL_SAMPLER_DIM_EXTERNAL).  I'd prefer to just use one enum for both
> purposes, and don't create any image types using GLSL_SAMPLER_DIM_EXTERNAL.
>

This was a deliberate change.  My intention was to be able to refer to a
surface dimensionality and whether it's an image or sampler type with a
single identifier.  If we use the same type for both we will have to
find another way for overload selection and that will probably make the
notation in the builtin_type_macros.h code in PATCH 16 inconsistent with
the macros for sampler types, unless we change the sampler glsl_type
constructor too.

> With that changed, this patch is:
>
> Reviewed-by: Paul Berry <stereotype...@gmail.com>

Attachment: pgpcexqMRLP6b.pgp
Description: PGP signature

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to