summaryrefslogtreecommitdiffstats
path: root/video/out/opengl/video.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-12-09 00:16:51 +0100
committerwm4 <wm4@nowhere>2015-12-09 00:16:51 +0100
commitc5c7b239b6386940a8063c6954db2a4705ce3251 (patch)
treed5798be4f57ee0df4835a28693819099d61849ab /video/out/opengl/video.c
parentc2d0d7818f1045fbee5f296d614a11d25784215f (diff)
downloadmpv-c5c7b239b6386940a8063c6954db2a4705ce3251.tar.bz2
mpv-c5c7b239b6386940a8063c6954db2a4705ce3251.tar.xz
csputils, vo_opengl: remove XYZ special case in color matrix retrieval
This just seems unnecessary. Refactor it a bit. There should be no functional changes.
Diffstat (limited to 'video/out/opengl/video.c')
-rw-r--r--video/out/opengl/video.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/video/out/opengl/video.c b/video/out/opengl/video.c
index 018a7f8286..7ac56cb414 100644
--- a/video/out/opengl/video.c
+++ b/video/out/opengl/video.c
@@ -1491,12 +1491,7 @@ static void pass_convert_yuv(struct gl_video *p)
// Conversion to RGB. For RGB itself, this still applies e.g. brightness
// and contrast controls, or expansion of e.g. LSB-packed 10 bit data.
struct mp_cmat m = {{{0}}};
- if (p->image_desc.flags & MP_IMGFLAG_XYZ) {
- struct mp_csp_primaries csp = mp_get_csp_primaries(p->image_params.primaries);
- mp_get_xyz2rgb_coeffs(&cparams, csp, MP_INTENT_RELATIVE_COLORIMETRIC, &m);
- } else {
- mp_get_yuv2rgb_coeffs(&cparams, &m);
- }
+ mp_get_yuv2rgb_coeffs(&cparams, &m);
gl_sc_uniform_mat3(sc, "colormatrix", true, &m.m[0][0]);
gl_sc_uniform_vec3(sc, "colormatrix_c", m.c);