summaryrefslogtreecommitdiffstats
path: root/video/decode/vd.c
diff options
context:
space:
mode:
Diffstat (limited to 'video/decode/vd.c')
-rw-r--r--video/decode/vd.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/video/decode/vd.c b/video/decode/vd.c
index 9df1d39146..b344491c6b 100644
--- a/video/decode/vd.c
+++ b/video/decode/vd.c
@@ -152,6 +152,8 @@ int mpcodecs_reconfig_vo(sh_video_t *sh, const struct mp_image_params *params)
p.d_w = d_w;
p.d_h = d_h;
+ mp_image_params_guess_csp(&p);
+
vocfg_flags = (opts->fullscreen ? VOFLAG_FULLSCREEN : 0) |
(flip ? VOFLAG_FLIPPING : 0);
@@ -171,8 +173,9 @@ int mpcodecs_reconfig_vo(sh_video_t *sh, const struct mp_image_params *params)
sh->vf_initialized = 1;
- sh->colorspace = p.colorspace;
- sh->color_range = p.colorlevels;
+ if (!sh->vf_input)
+ sh->vf_input = talloc(sh, struct mp_image_params);
+ *sh->vf_input = p;
set_video_colorspace(sh);