Hi Emil, On Tue, May 2, 2017 at 3:43 AM, Emil Velikov <emil.l.veli...@gmail.com> wrote: > From: Emil Velikov <emil.veli...@collabora.com> > > Thus we can use the value to explicitly size arrays, insteads of > __DRI_ATTRIB_FRAMEBUFFER_SRGB_CAPABLE. > > The latter seems magical and is error prone, as we add more dri > attributes. > > Cc: Tomasz Figa <tf...@chromium.org> > Signed-off-by: Emil Velikov <emil.veli...@collabora.com> > --- > include/GL/internal/dri_interface.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/include/GL/internal/dri_interface.h > b/include/GL/internal/dri_interface.h > index 86efd1bdc98..d450109d60f 100644 > --- a/include/GL/internal/dri_interface.h > +++ b/include/GL/internal/dri_interface.h > @@ -702,6 +702,7 @@ struct __DRIuseInvalidateExtensionRec { > #define __DRI_ATTRIB_BIND_TO_TEXTURE_TARGETS 46 > #define __DRI_ATTRIB_YINVERTED 47 > #define __DRI_ATTRIB_FRAMEBUFFER_SRGB_CAPABLE 48 > +#define __DRI_ATTRIB_MAX __DRI_ATTRIB_FRAMEBUFFER_SRGB_CAPABLE
Perhaps (__DRI_ATTRIB_FRAMEBUFFER_SRGB_CAPABLE + 1)? This way we don't have to use (__DRI_ATTRIB_MAX + 1) for array sizes. Best regards, Tomasz _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev