1
0
mirror of https://github.com/mpv-player/mpv synced 2025-01-01 12:22:22 +00:00
mpv/libvo
wm4 75eab4f72a video, options: implement better YUV->RGB conversion control
Rewrite control of the colorspace and input/output level parameters
used in YUV-RGB conversions, replacing VO-specific suboptions with new
common options and adding configuration support to more cases.

Add new option --colormatrix which selects the colorspace the original
video is assumed to have in YUV->RGB conversions. The default
behavior changes from assuming BT.601 to colorspace autoselection
between BT.601 and BT.709 using a simple heuristic based on video
size. Add new options --colormatrix-input-range and
--colormatrix-output-range which select input YUV and output RGB range.
Disable the previously existing VO-specific colorspace and level
conversion suboptions in vo_gl and vo_vdpau. Remove the
"yuv_colorspace" property and replace it with one named "colormatrix"
and semantics matching the new option. Add new properties matching the
options for level conversion.

Colorspace selection is currently supported by vo_gl, vo_vdpau, vo_xv
and vf_scale, and all can change it at runtime (previously only
vo_vdpau and vo_xv could). vo_vdpau now uses the same conversion
matrix generation as vo_gl instead of libvdpau functionality; the main
functional difference is that the "contrast" equalizer control behaves
somewhat differently (it scales the Y component around 1/2 instead of
around 0, so that contrast 0 makes the image gray rather than black).
vo_xv does not support level conversion. vf_scale supports range
setting for input, but always outputs full-range RGB.

The value of the slave properties is the policy setting used for
conversions. This means they can be set to any value regardless of
whether the current VO supports that value or whether there currently
even is any video. Possibly separate properties could be added to
query the conversion actually used at the moment, if any.

Because the colorspace and level settings are now set with a single
VF/VO control call, the return value of that is no longer used to
signal whether all the settings are actually supported. Instead code
should set all the details it can support, and ignore the rest. The
core will use GET_YUV_COLORSPACE to check which colorspace details
have been set and which not. In other words, the return value for
SET_YUV_COLORSPACE only signals whether any kind of YUV colorspace
conversion handling exists at all, and VOs have to take care to return
the actual state with GET_YUV_COLORSPACE instead.

To be changed in later commits: add missing option documentation.
2011-10-16 21:11:11 +03:00
..
aclib_template.c cosmetics: Remove pointless empty lines at EOF. 2010-02-20 21:02:49 +00:00
aclib.c Merge svn changes up to r30185 2010-01-08 01:36:05 +02:00
aspect.c VO: silence "[ASPECT] Warning: No suitable new res found!" 2011-07-05 00:38:34 +03:00
aspect.h Merge svn changes up to r29644 2009-09-04 19:49:35 +03:00
csputils.c video, options: implement better YUV->RGB conversion control 2011-10-16 21:11:11 +03:00
csputils.h video, options: implement better YUV->RGB conversion control 2011-10-16 21:11:11 +03:00
fastmemcpy.h Fix compilation with --disable-fastmemcpy on x86 2010-05-11 09:23:31 +00:00
geometry.c Add support for -geometry x syntax since the documentation claims 2010-06-05 06:28:58 +00:00
geometry.h Replace casual GPL notices by proper license headers. 2008-09-07 14:09:51 +00:00
gl_common.c vo_gl: fix YUY2/YVYU colorspace mixup 2011-07-06 13:01:07 +03:00
gl_common.h vo_gl: Support 9- and 10-bit YUV input for OpenGL VOs 2011-07-06 07:31:54 +03:00
gtf.c cosmetics: Remove pointless empty lines at EOF. 2010-02-20 21:02:49 +00:00
gtf.h Remove trailing whitespace from most files 2009-07-07 02:34:35 +03:00
matrixview_font.h Add missing license headers for vo_matrixview code. 2010-01-04 13:05:52 +00:00
matrixview.c Add mpgl prefix to all OpenGL-related function pointers. 2010-04-03 07:08:07 +00:00
matrixview.h Add missing license headers for vo_matrixview code. 2010-01-04 13:05:52 +00:00
mga_template.c cleanup: silence some clang warnings 2011-07-06 13:01:08 +03:00
old_vo_defines.h Merge svn changes up to r28549 2009-02-13 03:52:51 +02:00
old_vo_wrapper.c sub/OSD: move some related files to sub/ 2011-01-26 20:39:05 +02:00
old_vo_wrapper.h Merge svn changes up to r28310 2009-01-15 05:57:31 +02:00
osd_template.c Replace WORDS_BIGENDIAN by HAVE_BIGENDIAN in all internal code. 2009-07-26 19:53:00 +00:00
osd.c Add missing RGB12 version of the fast OSD table. 2010-05-26 00:47:22 +00:00
osd.h Add support for 12-bit color mode on framebuffer devices. 2010-05-06 10:18:25 +00:00
osx_common.c input: move all key code lists to input/keycodes.h 2011-05-02 00:43:31 +03:00
osx_common.h Refactor OS X foreground process setting into a separate function. 2010-03-26 15:02:14 +00:00
sdl_common.c input: move all key code lists to input/keycodes.h 2011-05-02 00:43:31 +03:00
sdl_common.h Add comment for endif. 2010-04-25 15:39:22 +00:00
spuenc.c Move struct typedef pixbuf into the only .c file where it is used. 2010-02-16 19:39:30 +00:00
spuenc.h Move struct typedef pixbuf into the only .c file where it is used. 2010-02-16 19:39:30 +00:00
vdpau_template.c vo_vdpau: Add support for high-quality scaling feature 2009-11-15 18:39:48 +02:00
vesa_lvo.c sub/OSD: move some related files to sub/ 2011-01-26 20:39:05 +02:00
vesa_lvo.h vesa_lvo.c: make functions static 2010-11-02 04:16:56 +02:00
video_out_internal.h cleanup: remove more warnings 2011-05-02 00:46:48 +03:00
video_out.c input: rework event reading and command queuing 2011-07-17 07:36:09 +03:00
video_out.h video, options: implement better YUV->RGB conversion control 2011-10-16 21:11:11 +03:00
videodev_mjpeg.h Remove trailing whitespace from most files 2009-07-07 02:34:35 +03:00
vo_3dfx.c vo_dga: replace xf86dga.h with Xxf86dga.h 2011-04-20 04:22:53 +03:00
vo_aa.c cleanup: shut up more warnings 2011-05-06 18:33:16 +03:00
vo_bl.c Remove trailing whitespace from most files 2009-07-07 02:34:35 +03:00
vo_caca.c input: move all key code lists to input/keycodes.h 2011-05-02 00:43:31 +03:00
vo_corevideo.h vo_corevideo.h: Add standard multiple inclusion guards 2010-11-02 04:16:46 +02:00
vo_corevideo.m input: move all key code lists to input/keycodes.h 2011-05-02 00:43:31 +03:00
vo_dfbmga.c cleanup: some warning fixes and minor cleanups 2011-06-29 09:17:19 +03:00
vo_dga.c vo_dga: replace xf86dga.h with Xxf86dga.h 2011-04-20 04:22:53 +03:00
vo_direct3d.c cleanup: vo_direct3d: Mark a function static 2011-07-06 07:24:52 +03:00
vo_directfb2.c cleanup: mark some vo_directfb2.c and vo_s3fb.c functions static 2011-06-29 11:43:19 +03:00
vo_directx.c vo_directx: include <libavutil/common.h> for FFMIN 2011-07-07 22:58:34 +03:00
vo_dxr3.c sub/OSD: move some related files to sub/ 2011-01-26 20:39:05 +02:00
vo_fbdev2.c cleanup: vo_fbdev: simplify some code 2011-05-02 00:36:20 +03:00
vo_fbdev.c Merge branch 'mplayer1_changes' 2011-05-02 00:46:03 +03:00
vo_ggi.c input: move all key code lists to input/keycodes.h 2011-05-02 00:43:31 +03:00
vo_gif89a.c cleanup: remove NULL checks before free() all over the code 2010-11-14 13:11:20 +02:00
vo_gl2.c video, options: implement better YUV->RGB conversion control 2011-10-16 21:11:11 +03:00
vo_gl.c video, options: implement better YUV->RGB conversion control 2011-10-16 21:11:11 +03:00
vo_ivtv.c ao_ivtv: Add header for ivtv_write() instead of forward declaring it 2010-11-02 04:09:18 +02:00
vo_ivtv.h vo_ivtv; Move ivtv_fd extern variable declaration to vo_ivtv.h 2010-11-02 04:16:46 +02:00
vo_jpeg.c cleanup: silence some clang warnings 2011-07-06 13:01:08 +03:00
vo_kva.c input: move all key code lists to input/keycodes.h 2011-05-02 00:43:31 +03:00
vo_matrixview.c cleanup: shut up more warnings 2011-05-06 18:33:16 +03:00
vo_md5sum.c cleanup: vo_md5sum: Remove unused define/undef 2011-01-31 16:03:10 +02:00
vo_mga.c sub/OSD: move some related files to sub/ 2011-01-26 20:39:05 +02:00
vo_mpegpes.c cleanup: silence some clang warnings 2011-07-06 13:01:08 +03:00
vo_null.c Delete things related to old translation system 2010-03-10 03:47:14 +02:00
vo_png.c cleanup: do libav* initialization on startup 2011-07-18 00:57:05 +03:00
vo_pnm.c cleanup: remove NULL checks before free() all over the code 2010-11-14 13:11:20 +02:00
vo_quartz.c input: move all key code lists to input/keycodes.h 2011-05-02 00:43:31 +03:00
vo_s3fb.c cleanup: mark some vo_directfb2.c and vo_s3fb.c functions static 2011-06-29 11:43:19 +03:00
vo_sdl.c cleanup: remove more warnings 2011-05-02 00:46:48 +03:00
vo_svga.c vo_svga: fix build after previous commit 6506d4ad 2011-05-03 12:21:59 +03:00
vo_tdfx_vid.c Delete things related to old translation system 2010-03-10 03:47:14 +02:00
vo_tdfxfb.c sub/OSD: move some related files to sub/ 2011-01-26 20:39:05 +02:00
vo_tga.c vo_tga: specify 15 bpp tga format endianness 2010-11-02 04:14:44 +02:00
vo_v4l2.c Merge svn changes up to r30694 2010-03-10 01:01:15 +02:00
vo_v4l2.h vo_v4l2: Move v4l2_fd extern declaration to vo_v4l2.h 2010-11-02 04:16:46 +02:00
vo_vdpau.c video, options: implement better YUV->RGB conversion control 2011-10-16 21:11:11 +03:00
vo_vesa.c vidix: drop VIDIX support 2011-01-31 16:03:10 +02:00
vo_wii.c sub/OSD: move some related files to sub/ 2011-01-26 20:39:05 +02:00
vo_x11.c vo_xv: avoid clearing too much on resize 2011-07-06 08:36:46 +03:00
vo_xmga.c sub/OSD: move some related files to sub/ 2011-01-26 20:39:05 +02:00
vo_xover.c libvo: remove UNUSED() macros 2010-11-02 04:18:08 +02:00
vo_xv.c video, options: implement better YUV->RGB conversion control 2011-10-16 21:11:11 +03:00
vo_xvr100.c sub/OSD: move some related files to sub/ 2011-01-26 20:39:05 +02:00
vo_yuv4mpeg.c sub/OSD: move some related files to sub/ 2011-01-26 20:39:05 +02:00
w32_common.c VO: w32_common: also generate VO_EVENT_MOVE 2011-07-06 13:01:07 +03:00
w32_common.h 100l, forgot to apply vo_w32_get_dc/vo_w32_release_dc declarations in w32_common.h 2009-11-22 14:46:43 +00:00
wskeys.h vo: X key input: remove ambiguous KeySym remapping 2011-07-29 08:46:50 +03:00
x11_common.c vo: X key input: remove ambiguous KeySym remapping 2011-07-29 08:46:50 +03:00
x11_common.h vo_xv: avoid clearing too much on resize 2011-07-06 08:36:46 +03:00