From: Carl Eugen Hoyos <[email protected]>

Old versions of libxcb do not provide xcb_shape_rectangles().
The issue can be fixed differently but this small change fixes
some fate platforms and a user reported compilation problem.

Reported and tested by trac user kevmitch.
Fixes ticket #4067.
---
 libavdevice/xcbgrab.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavdevice/xcbgrab.c b/libavdevice/xcbgrab.c
index 0cbfd4f..994f160 100644
--- a/libavdevice/xcbgrab.c
+++ b/libavdevice/xcbgrab.c
@@ -583,11 +583,13 @@ static void setup_window(AVFormatContext *s)
                       XCB_COPY_FROM_PARENT,
                       mask, values);
 
+#if XCB_SHAPE_RECTANGLES
     xcb_shape_rectangles(c->conn, XCB_SHAPE_SO_SUBTRACT,
                          XCB_SHAPE_SK_BOUNDING, XCB_CLIP_ORDERING_UNSORTED,
                          c->window,
                          c->region_border, c->region_border,
                          1, &rect);
+#endif
 
     xcb_map_window(c->conn, c->window);
 
-- 
1.7.10.4

_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to