[Mesa-dev] [PATCH] mesa: fix GLES 3.1 version calculation

Rob Clark robdclark at gmail.com
Tue Jun 19 13:38:22 UTC 2018


On Tue, Jun 19, 2018 at 9:09 AM, Ilia Mirkin <imirkin at alum.mit.edu> wrote:
> On Tue, Jun 19, 2018 at 8:53 AM, Rob Clark <robdclark at gmail.com> wrote:
>> All of ARB_gpu_shader5 is most certainly not required for GLES 3.1
>> (most of it is in OES_gpu_shader5 on top of GLES 3.1).
>>
>> Some of what is required from ARB_gpu_shader5 is provided by
>> ARB_texture_gather, so check for that.  The remaining subset of
>
> ARB_texture_gather is actually a subset of what's needed for ES 3.1,
> gather-wise. I think ES 3.1 has component selection in the shader, and
> potentially non-const offsets (neither of which ARB_texture_gather
> has).
>

hmm, don't we have a lowering pass for some of that (for a4xx)?

>> ARB_gpu_shader5 doesn't have individual extensions to check for,
>> but I guess it is unlikely that some driver has all of these
>> extensions but not, say, integer bitfield manipulation.
>
> Actually I think those are all handled by
> MESA_something_integer_something. Not the ideal way of supporting that
> stuff, but whatever goes. (This is a relatively new ext, compared to
> ES 3.1.) I'd drop that in, if it has an enable. And if not, you're
> covered on that front.
>

good point, I've added locally a check for MESA_shader_integer_functions

BR,
-R

>>
>> Signed-off-by: Rob Clark <robdclark at gmail.com>
>> ---
>>  src/mesa/main/version.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/src/mesa/main/version.c b/src/mesa/main/version.c
>> index 1bdccf4a1df..cc34b4ad62f 100644
>> --- a/src/mesa/main/version.c
>> +++ b/src/mesa/main/version.c
>> @@ -549,7 +549,7 @@ compute_version_es2(const struct gl_extensions *extensions,
>>                           extensions->ARB_shading_language_packing &&
>>                           extensions->ARB_stencil_texturing &&
>>                           extensions->ARB_texture_multisample &&
>> -                         extensions->ARB_gpu_shader5 &&
>> +                         extensions->ARB_texture_gather &&
>>                           extensions->EXT_shader_integer_mix);
>>     const bool ver_3_2 = (ver_3_1 &&
>>                           extensions->EXT_draw_buffers2 &&
>> --
>> 2.17.1
>>


More information about the mesa-dev mailing list