diff options
author | Kristian Høgsberg <krh@redhat.com> | 2009-04-01 17:42:33 -0400 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2009-06-29 14:10:40 -0700 |
commit | 6056d429e7dcc37fe706dd7bc8d3429fdb635e14 (patch) | |
tree | c60dd9e624965be66b44a98c180200ce14c62c11 /glx/glxdri2.c | |
parent | 7cae08d21952b02ef664641af6588ef6bd727bf8 (diff) |
Support setTexBuffer2 in AIGLX.
Fixes broken GLX_tfp, specifically, lets compositors ignore un-defined
alpha channel for pixmaps.
(cherry picked from commit 91b697efdefba125348dbcaf584ee51a7f8c9bf6)
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'glx/glxdri2.c')
-rw-r--r-- | glx/glxdri2.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/glx/glxdri2.c b/glx/glxdri2.c index f2682d4d9..0b64298ca 100644 --- a/glx/glxdri2.c +++ b/glx/glxdri2.c @@ -222,9 +222,16 @@ __glXDRIbindTexImage(__GLXcontext *baseContext, if (texBuffer == NULL) return Success; - texBuffer->setTexBuffer(context->driContext, - glxPixmap->target, - drawable->driDrawable); + if (texBuffer->base.version >= 2 && texBuffer->setTexBuffer2 != NULL) { + (*texBuffer->setTexBuffer2)(context->driContext, + glxPixmap->target, + glxPixmap->format, + drawable->driDrawable); + } else { + texBuffer->setTexBuffer(context->driContext, + glxPixmap->target, + drawable->driDrawable); + } return Success; } |