The X and Y values are pixel coordinates in the potentially subsampled
plane resolution. This must be converted to an octet offset as the type
of the pixel plane pointer is pointer-to-uint8_t.
So the X value must be multiplied by the sample size. The current code
was instead rounding the value down to a multiple of the sample size.
Bug reported by Philipp Marek on IRC.
(cherry picked from commit 87733c5011)
The computations must not be done on the buffer size but on the video one.
Otherwise, we might end up with the sum of all output sizes bigger than the
video itself, which results in a green strip at the bottom of the lowest
outputs, and potentially incorrect display for all of them (with bad width).
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
This patch fixes this build error.
video_splitter/.libs/libpanoramix_plugin_la-panoramix.o: In function `CountMonitors':
modules/video_splitter/panoramix.c:352: undefined reference to `xcb_connect'
modules/video_splitter/panoramix.c:354: undefined reference to `xcb_connection_has_error'
modules/video_splitter/panoramix.c:357: undefined reference to `xcb_get_setup'
modules/video_splitter/panoramix.c:359: undefined reference to `xcb_setup_roots_iterator'
modules/video_splitter/panoramix.c:360: undefined reference to `xcb_screen_next'
modules/video_splitter/panoramix.c:407: undefined reference to `xcb_disconnect'
modules/video_splitter/panoramix.c:407: undefined reference to `xcb_disconnect'
modules/video_splitter/panoramix.c:407: undefined reference to `xcb_disconnect'
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
This might suppress some warnings (and very slightly reduce code size)
when assertions are disabled. Not that I particularly like to create
VLC-specific macros.