From 9a88b118b4ffe22f1747375b42bc57f3b5d33ed0 Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 14 Jan 2016 00:18:48 +0100 Subject: video: decouple filtering/decoding slightly more Lots of noise to remove the vfilter/vo fields from dec_video. From now on, video filtering and output will still be done together, summarized under struct vo_chain. There is the question where exactly the vf_chain should go in such a decoupled architecture. The end goal is being able to place a "complex" filter between video decoders and output (which will culminate in natural integration of A->V filters for natural integration of libavfilter audio visualizations). The vf_chain is still useful for "final" processing, such as format conversions and deinterlacing. Also, there's only 1 VO and 1 --vf option. So having 1 vf_chain for a VO seems ideal, since otherwise there would be no natural way to handle all these existing options and mechanisms. There is still some work required to truly decouple decoding. --- player/sub.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'player/sub.c') diff --git a/player/sub.c b/player/sub.c index c20df53c60..0633ebaea1 100644 --- a/player/sub.c +++ b/player/sub.c @@ -77,8 +77,8 @@ static bool update_subtitle(struct MPContext *mpctx, double video_pts, int order if (!track || !dec_sub || video_pts == MP_NOPTS_VALUE) return true; - if (mpctx->d_video) { - struct mp_image_params params = mpctx->d_video->vfilter->input_params; + if (mpctx->vo_chain) { + struct mp_image_params params = mpctx->vo_chain->vf->input_params; if (params.imgfmt) sub_control(dec_sub, SD_CTRL_SET_VIDEO_PARAMS, ¶ms); } -- cgit v1.2.3