works with (--enable-libxcb-shape) and without (--disable-libxcb-shape) now.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
... | ... |
@@ -254,6 +254,7 @@ External library support: |
254 | 254 |
--enable-libxcb enable X11 grabbing using XCB [auto] |
255 | 255 |
--enable-libxcb-shm enable X11 grabbing shm communication [auto] |
256 | 256 |
--enable-libxcb-xfixes enable X11 grabbing mouse rendering [auto] |
257 |
+ --enable-libxcb-shape enable X11 grabbing shape rendering [auto] |
|
257 | 258 |
--enable-libxvid enable Xvid encoding via xvidcore, |
258 | 259 |
native MPEG-4/Xvid encoder exists [no] |
259 | 260 |
--enable-libzmq enable message passing via libzmq [no] |
... | ... |
@@ -1386,6 +1387,7 @@ EXTERNAL_LIBRARY_LIST=" |
1386 | 1386 |
libxavs |
1387 | 1387 |
libxcb |
1388 | 1388 |
libxcb_shm |
1389 |
+ libxcb_shape |
|
1389 | 1390 |
libxcb_xfixes |
1390 | 1391 |
libxvid |
1391 | 1392 |
libzmq |
... | ... |
@@ -5047,8 +5049,13 @@ if enabled libxcb; then |
5047 | 5047 |
enabled libxcb_xfixes && die "ERROR: libxcb_xfixes not found"; |
5048 | 5048 |
} && enable libxcb_xfixes; } |
5049 | 5049 |
|
5050 |
- add_cflags $xcb_cflags $xcb_shm_cflags $xcb_xfixes_cflags |
|
5051 |
- add_extralibs $xcb_libs $xcb_shm_libs $xcb_xfixes_libs |
|
5050 |
+ disabled libxcb_shape || { |
|
5051 |
+ check_pkg_config xcb-shape xcb/shape.h xcb_shape_get_rectangles || { |
|
5052 |
+ enabled libxcb_shape && die "ERROR: libxcb_shape not found"; |
|
5053 |
+ } && enable libxcb_shape; } |
|
5054 |
+ |
|
5055 |
+ add_cflags $xcb_cflags $xcb_shm_cflags $xcb_xfixes_cflags $xcb_shape_cflags |
|
5056 |
+ add_extralibs $xcb_libs $xcb_shm_libs $xcb_xfixes_libs $xcb_shape_libs |
|
5052 | 5057 |
fi |
5053 | 5058 |
fi |
5054 | 5059 |
|
... | ... |
@@ -33,6 +33,10 @@ |
33 | 33 |
#include <xcb/shm.h> |
34 | 34 |
#endif |
35 | 35 |
|
36 |
+#if CONFIG_LIBXCB_SHAPE |
|
37 |
+#include <xcb/shape.h> |
|
38 |
+#endif |
|
39 |
+ |
|
36 | 40 |
#include "libavformat/avformat.h" |
37 | 41 |
#include "libavformat/internal.h" |
38 | 42 |
|
... | ... |
@@ -576,7 +580,7 @@ static void setup_window(AVFormatContext *s) |
576 | 576 |
XCB_COPY_FROM_PARENT, |
577 | 577 |
mask, values); |
578 | 578 |
|
579 |
-#if XCB_SHAPE_RECTANGLES |
|
579 |
+#if CONFIG_LIBXCB_SHAPE |
|
580 | 580 |
xcb_shape_rectangles(c->conn, XCB_SHAPE_SO_SUBTRACT, |
581 | 581 |
XCB_SHAPE_SK_BOUNDING, XCB_CLIP_ORDERING_UNSORTED, |
582 | 582 |
c->window, |