[Mesa-dev] [PATCH 2/3] mesa: Handle OES_texture_view tokens
Francesco Ansanelli
francians at gmail.com
Mon Aug 29 05:32:08 UTC 2016
I dropped this patch and replaced with another one.
Thanks
Francesco
2016-08-28 22:38 GMT+02:00 Chris Forbes <chrisf at ijw.co.nz>:
> This patch isn't right. These enum values are the same as the desktop
> version, so your new cases will never actually be used.
>
> On Mon, Aug 29, 2016 at 2:24 AM, Francesco Ansanelli <francians at gmail.com>
> wrote:
>
>> Signed-off-by: Francesco Ansanelli <francians at gmail.com>
>> ---
>> src/mesa/main/texparam.c | 48 ++++++++++++++++++++++++++++++
>> ++++++++++++++++
>> 1 file changed, 48 insertions(+)
>>
>> diff --git a/src/mesa/main/texparam.c b/src/mesa/main/texparam.c
>> index bdd3fcb..4dd97b1 100644
>> --- a/src/mesa/main/texparam.c
>> +++ b/src/mesa/main/texparam.c
>> @@ -1960,6 +1960,30 @@ get_tex_parameterfv(struct gl_context *ctx,
>> *params = (GLfloat) obj->NumLayers;
>> break;
>>
>> + case GL_TEXTURE_VIEW_MIN_LEVEL_OES:
>> + if (!ctx->Extensions.OES_texture_view)
>> + goto invalid_pname;
>> + *params = (GLfloat) obj->MinLevel;
>> + break;
>> +
>> + case GL_TEXTURE_VIEW_NUM_LEVELS_OES:
>> + if (!ctx->Extensions.OES_texture_view)
>> + goto invalid_pname;
>> + *params = (GLfloat) obj->NumLevels;
>> + break;
>> +
>> + case GL_TEXTURE_VIEW_MIN_LAYER_OES:
>> + if (!ctx->Extensions.OES_texture_view)
>> + goto invalid_pname;
>> + *params = (GLfloat) obj->MinLayer;
>> + break;
>> +
>> + case GL_TEXTURE_VIEW_NUM_LAYERS_OES:
>> + if (!ctx->Extensions.OES_texture_view)
>> + goto invalid_pname;
>> + *params = (GLfloat) obj->NumLayers;
>> + break;
>> +
>> case GL_REQUIRED_TEXTURE_IMAGE_UNITS_OES:
>> if (!_mesa_is_gles(ctx) || !ctx->Extensions.OES_EGL_image
>> _external)
>> goto invalid_pname;
>> @@ -2192,6 +2216,30 @@ get_tex_parameteriv(struct gl_context *ctx,
>> *params = (GLint) obj->NumLayers;
>> break;
>>
>> + case GL_TEXTURE_VIEW_MIN_LEVEL_OES:
>> + if (!ctx->Extensions.OES_texture_view)
>> + goto invalid_pname;
>> + *params = (GLint) obj->MinLevel;
>> + break;
>> +
>> + case GL_TEXTURE_VIEW_NUM_LEVELS_OES:
>> + if (!ctx->Extensions.OES_texture_view)
>> + goto invalid_pname;
>> + *params = (GLint) obj->NumLevels;
>> + break;
>> +
>> + case GL_TEXTURE_VIEW_MIN_LAYER_OES:
>> + if (!ctx->Extensions.OES_texture_view)
>> + goto invalid_pname;
>> + *params = (GLint) obj->MinLayer;
>> + break;
>> +
>> + case GL_TEXTURE_VIEW_NUM_LAYERS_OES:
>> + if (!ctx->Extensions.OES_texture_view)
>> + goto invalid_pname;
>> + *params = (GLint) obj->NumLayers;
>> + break;
>> +
>> case GL_REQUIRED_TEXTURE_IMAGE_UNITS_OES:
>> if (!_mesa_is_gles(ctx) || !ctx->Extensions.OES_EGL_image
>> _external)
>> goto invalid_pname;
>> --
>> 1.7.9.5
>>
>> _______________________________________________
>> mesa-dev mailing list
>> mesa-dev at lists.freedesktop.org
>> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160829/4fe3186d/attachment.html>
More information about the mesa-dev
mailing list