aboutsummaryrefslogtreecommitdiffhomepage
path: root/video/out/opengl
diff options
context:
space:
mode:
authorGravatar wm4 <wm4@nowhere>2016-04-27 14:23:03 +0200
committerGravatar wm4 <wm4@nowhere>2016-04-27 14:34:46 +0200
commit0b1ba577b14387ca9547d8700203900e5b213dd3 (patch)
tree131cef3a50b7927b2600c335789193884f33d683 /video/out/opengl
parentdff33893f2ea91f425bceeec6596556d569e0370 (diff)
vo_opengl: d3d11egl: print warning on unsupported colorspaces
Not much we can do about. If there are many complaints, a mechanism to automatically disable interop in such cases could be added.
Diffstat (limited to 'video/out/opengl')
-rw-r--r--video/out/opengl/hwdec_d3d11egl.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/video/out/opengl/hwdec_d3d11egl.c b/video/out/opengl/hwdec_d3d11egl.c
index abb5831670..a63707b887 100644
--- a/video/out/opengl/hwdec_d3d11egl.c
+++ b/video/out/opengl/hwdec_d3d11egl.c
@@ -329,6 +329,17 @@ static int create_video_proc(struct gl_hwdec *hw, struct mp_image_params *params
p->video_proc,
0, FALSE);
+ if ((params->colorspace != MP_CSP_BT_601 &&
+ params->colorspace != MP_CSP_BT_709) ||
+ params->colorlevels != MP_CSP_LEVELS_TV)
+ {
+ MP_WARN(hw, "Unsupported video colorspace (%s/%s). Consider disabling "
+ "hardware decoding, or using --hwdec=d3d11va-copy to get "
+ "correct output.\n",
+ m_opt_choice_str(mp_csp_names, params->colorspace),
+ m_opt_choice_str(mp_csp_levels_names, params->colorlevels));
+ }
+
D3D11_VIDEO_PROCESSOR_COLOR_SPACE csp = {
.YCbCr_Matrix = params->colorspace != MP_CSP_BT_601,
};