From 15513a77fb375acfbda6de36b806c0070472d04d Mon Sep 17 00:00:00 2001 From: iive Date: Sun, 29 May 2011 22:46:52 +0000 Subject: vo_xv: avoid setting background color due to resize flicker Set background color only when using ck-method=background. In the other cases clearing of the non-video image area should be done manually. Not drawing on the video image area prevents flickering (visible when resizing). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33522 b3059339-0415-0410-9bf9-f77b7e298cf2 --- libvo/vo_xv.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'libvo') diff --git a/libvo/vo_xv.c b/libvo/vo_xv.c index 6da354bd5a..cecbc68b7e 100644 --- a/libvo/vo_xv.c +++ b/libvo/vo_xv.c @@ -252,11 +252,12 @@ static int config(struct vo *vo, uint32_t width, uint32_t height, depth = 24; XMatchVisualInfo(x11->display, x11->screen, depth, TrueColor, &vinfo); - xswa.background_pixel = 0; - if (x11->xv_ck_info.method == CK_METHOD_BACKGROUND) - xswa.background_pixel = x11->xv_colorkey; xswa.border_pixel = 0; - xswamask = CWBackPixel | CWBorderPixel; + xswamask = CWBorderPixel; + if (x11->xv_ck_info.method == CK_METHOD_BACKGROUND) { + xswa.background_pixel = x11->xv_colorkey; + xswamask |= CWBackPixel; + } vo_x11_create_vo_window(vo, &vinfo, vo->dx, vo->dy, vo->dwidth, vo->dheight, flags, CopyFromParent, "xv", -- cgit v1.2.3