Build against DRI_TEX_BUFFER_VERSION 1

setTexBuffer2 isn't present in this version of the structure, so don't try
to call it.

Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit a7a93c12f9)
This commit is contained in:
Keith Packard 2009-06-29 23:18:55 -07:00 committed by Jeremy Huddleston
parent e34a12b18f
commit c83e842d62

View file

@ -221,12 +221,15 @@ __glXDRIbindTexImage(__GLXcontext *baseContext,
if (texBuffer == NULL)
return Success;
#if __DRI_TEX_BUFFER_VERSION >= 2
if (texBuffer->base.version >= 2 && texBuffer->setTexBuffer2 != NULL) {
(*texBuffer->setTexBuffer2)(context->driContext,
glxPixmap->target,
glxPixmap->format,
drawable->driDrawable);
} else {
} else
#endif
{
texBuffer->setTexBuffer(context->driContext,
glxPixmap->target,
drawable->driDrawable);