From ea03cc67122ad8b47e640c868d108d7531536a21 Mon Sep 17 00:00:00 2001 From: wm4 Date: Sun, 17 Mar 2013 23:01:33 +0100 Subject: x11_common: remove assumption that video is always centered The vo_x11_clearwindow_part() function assumed that the video is always centered. Replace it with a new vo_x11_clear_background() function instead, which essentially does the same as the old function. It takes the video rectangle instead of just the video size, and doesn't have to make the assumption that the video rectangle is centered. Also make vo_x11 use it (seems advantageous). --- video/out/x11_common.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'video/out/x11_common.h') diff --git a/video/out/x11_common.h b/video/out/x11_common.h index c54404fb7f..2ac3da2864 100644 --- a/video/out/x11_common.h +++ b/video/out/x11_common.h @@ -27,6 +27,7 @@ #include "config.h" struct vo; +struct mp_rect; struct vo_x11_state { Display *display; @@ -136,8 +137,7 @@ void vo_x11_config_vo_window(struct vo *vo, XVisualInfo *vis, int x, int y, unsigned int width, unsigned int height, int flags, const char *classname); -void vo_x11_clearwindow_part(struct vo *vo, Window vo_window, - int img_width, int img_height); +void vo_x11_clear_background(struct vo *vo, const struct mp_rect *rc); void vo_x11_clearwindow(struct vo *vo, Window vo_window); void vo_x11_ontop(struct vo *vo); void vo_x11_border(struct vo *vo); -- cgit v1.2.3