aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/vl
diff options
context:
space:
mode:
authorLeo Liu <[email protected]>2016-06-09 12:53:54 -0400
committerLeo Liu <[email protected]>2016-06-10 11:24:24 -0400
commit2ad443e4cc0a72b7d0b28195b5810cbf197961cb (patch)
tree91f859f31cf2e256d81a81ed32ec29acef164292 /src/gallium/auxiliary/vl
parent0ef8500aabb5430eae76919438fcf61020b7eb8e (diff)
vl/dri3: support receiving new pixmap for front buffer
With glx of gstreamer-vaapi, the temporary pixmap for front buffer gets renewed in each frame, so when we receive a new pixmap, should get a new front buffer for it. This also fixes Totem player playback corruption. Signed-off-by: Leo Liu <[email protected]> Reviewed-by: Michel Dänzer <[email protected]> Cc: "12.0" <[email protected]>
Diffstat (limited to 'src/gallium/auxiliary/vl')
-rw-r--r--src/gallium/auxiliary/vl/vl_winsys_dri3.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/vl/vl_winsys_dri3.c b/src/gallium/auxiliary/vl/vl_winsys_dri3.c
index c69e67796c0..f7f572ea5c2 100644
--- a/src/gallium/auxiliary/vl/vl_winsys_dri3.c
+++ b/src/gallium/auxiliary/vl/vl_winsys_dri3.c
@@ -358,8 +358,13 @@ dri3_set_drawable(struct vl_dri3_screen *scrn, Drawable drawable)
if (error) {
if (error->error_code != BadWindow)
ret = false;
- else
+ else {
scrn->is_pixmap = true;
+ if (scrn->front_buffer) {
+ dri3_free_front_buffer(scrn, scrn->front_buffer);
+ scrn->front_buffer = NULL;
+ }
+ }
free(error);
} else
scrn->special_event =