From ab81af477cd58d03a0c2762f4b465a36b2aead34 Mon Sep 17 00:00:00 2001 From: wm4 Date: Sat, 17 Aug 2013 20:05:28 +0200 Subject: vo_vdpau: use color close to black as default colorkey (instead of green) The VDPAU default colorkey, although it seems to be driver specific, is usually green. This is a pretty annoying color, and you usually see it briefly (as flashes) if the VDPAU window resizes. Change it to some shade of black. The new default color is close to what MPlayer picks as colorkey (and apparently it worked well for them): VdpColor vdp_bg = {0.01, 0.02, 0.03, 0}; Since our OPT_COLOR can set 8 bit colors only, we use '#020507' instead, which should be the same assuming 8 bit colors. Obviously, you can't use black, because black is a way too common color, and would make it too easy to observe the colorkey effect when e.g. moving a terminal with black background over the video window. --- video/out/vo_vdpau.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'video') diff --git a/video/out/vo_vdpau.c b/video/out/vo_vdpau.c index addb155c56..9d08ad376b 100644 --- a/video/out/vo_vdpau.c +++ b/video/out/vo_vdpau.c @@ -1556,7 +1556,10 @@ const struct vo_driver video_out_vdpau = { OPT_INT("queuetime_fs", flip_offset_fs, 0, OPTDEF_INT(50)), OPT_INTRANGE("output_surfaces", num_output_surfaces, 0, 2, MAX_OUTPUT_SURFACES, OPTDEF_INT(3)), - OPT_COLOR("colorkey", colorkey, 0), + OPT_COLOR("colorkey", colorkey, 0, + .defval = &(const struct m_color) { + .r = 2, .g = 5, .b = 7, .a = 255, + }), {NULL}, } }; -- cgit v1.2.3