summaryrefslogtreecommitdiff
path: root/glx/glxdri2.c
diff options
context:
space:
mode:
Diffstat (limited to 'glx/glxdri2.c')
-rw-r--r--glx/glxdri2.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/glx/glxdri2.c b/glx/glxdri2.c
index 0b64298ca..836fea4d8 100644
--- a/glx/glxdri2.c
+++ b/glx/glxdri2.c
@@ -222,12 +222,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);