[Mesa-dev] [PATCH] glx: Allow to create any OpenGL ES version.
Emil Velikov
emil.l.velikov at gmail.com
Thu Apr 16 03:40:30 PDT 2015
On 15 April 2015 at 21:39, Chad Versace <chad.versace at intel.com> wrote:
> On Wed 15 Apr 2015, Emil Velikov wrote:
>>
>> On 14 April 2015 at 17:22, Ian Romanick <idr at freedesktop.org> wrote:
>>>
>>> On 04/14/2015 08:36 AM, Emil Velikov wrote:
>>>>
>>>> On 14 April 2015 at 13:52, Jose Fonseca <jfonseca at vmware.com> wrote:
>>>>>
>>>>> On 13/04/15 22:59, Ian Romanick wrote:
>>>>>>
>>>>>>
>>>>>> On 04/10/2015 03:36 PM, Jose Fonseca wrote:
>>>>>>>
>>>>>>>
>>>>>>> From: José Fonseca <jfonseca at vmware.com>
>
>
>>>>> diff --git a/src/glx/dri2_glx.c b/src/glx/dri2_glx.c
>>>>> index 8192c54..192525a 100644
>>>>> --- a/src/glx/dri2_glx.c
>>>>> +++ b/src/glx/dri2_glx.c
>>>>> @@ -1102,7 +1102,7 @@ dri2BindExtensions(struct dri2_screen *psc,
>>>>> struct
>>>>> glx_display * priv,
>>>>> __glXEnableDirectExtension(&psc->base,
>>>>> "GLX_ARB_create_context");
>>>>> __glXEnableDirectExtension(&psc->base,
>>>>> "GLX_ARB_create_context_profile");
>>>>>
>>>>> - if ((mask & (1 << __DRI_API_GLES2)) != 0) {
>>>>> + if ((mask & ((1 << __DRI_API_GLES2) | (1 << __DRI_API_GLES3)))
>>>>> != 0)
>>>
>>>
>>> Since ES3 is a superset of ES2, this shouldn't be necessary. I can't
>>> imagine a driver only setting __DRI_API_GLES3... and the common code may
>>> not even make that possible. We could, however, enable
>>> GLX_EXT_create_context_es2_profile if only __DRI_API_GLES is set. I
>>> don't really feel like testing any drivers that only support ES 1.x, do
>>> you? :)
>
>
>> Think of it as allowing gles1 support via GLX (apart from gles2/3),
>> rather than testing gles1 only drivers. I would assume that you
>> already support gles1 via EGL so things should just work for GLX.
>> Either way the decision is not mine to make ;-)
>
>
> Drivers that support GLES1 but not GLES2 are easily created. All that's
> needed is rebuilding i965 with --enable-gles1 --disable-gles2, right?
>
True, and it works by default via EGL. We'll need the __DRI_API_GLES
check, as Ian mentioned, for GLX to make use of it.
Considering GLES1 is tested (to a degree) over EGL, one might as well
enable it via GLX. Some of the tests might not pass, but there won't
be any regressions at least :-P
> I also have no time to rebuild the xserver. I try that once in a blue
> moon, and everytime it leads to broken input drivers and the need for
> vodka.
Hot potato ;-) I won't mind prepping and testing it over the next week
or so, but I'm not sure when it will end up committed.
My last xserver pull request (trivial fixes) is from 24th May, is not
committed despite a couple of pings. Suspecting that it might have
been redirected to /dev/null :-\
Cheers
Emil
More information about the mesa-dev
mailing list