[Mesa-dev] [PATCH v2 04/12] mesa: glGet: fix API check for EGL_image_external enums
Imre Deak
imre.deak at intel.com
Tue Sep 11 15:02:47 PDT 2012
On Tue, 2012-09-11 at 09:32 -0600, Brian Paul wrote:
> On 09/10/2012 12:41 AM, Imre Deak wrote:
> > These enums are valid only in ES1 and ES2. So far they were marked valid
> > incorrectly, depending on the previous API mask in the enum list.
> >
> > Signed-off-by: Imre Deak<imre.deak at intel.com>
> > ---
> > src/mesa/main/get.c | 15 +++++++++------
> > 1 file changed, 9 insertions(+), 6 deletions(-)
> >
> > diff --git a/src/mesa/main/get.c b/src/mesa/main/get.c
> > index ce5af04..6800cc3 100644
> > --- a/src/mesa/main/get.c
> > +++ b/src/mesa/main/get.c
> > @@ -789,6 +789,15 @@ static const struct value_desc values[] = {
> >
> > #endif /* FEATURE_GL || FEATURE_ES2 */
> >
> > +#if FEATURE_ES1 || FEATURE_ES2
> > + { 0, 0, TYPE_API_MASK, API_OPENGLES | API_OPENGLES2_BIT, NO_EXTRA },
>
> BTW, what are these { 0, ... } entries for? I see there's several of
> them but no comments about what they're for.
They partition the list into groups of enums. All enums in one group are
valid for the same set of APIs, in the above case GLES and GLES2. A
group ends with the next TYPE_API_MASK entry or at the end of array.
--Imre
More information about the mesa-dev
mailing list