viddec: Replicate any 3D/multiview info from input caps onto output

This commit is contained in:
Jan Schmidt 2014-10-07 16:33:07 +11:00
parent 0fc0584210
commit 1f1e24f63f

View file

@ -1026,6 +1026,7 @@ gst_ffmpegviddec_negotiate (GstFFMpegVidDec * ffmpegdec,
fps_d = 1;
}
}
GST_LOG_OBJECT (ffmpegdec, "setting framerate: %d/%d", fps_n, fps_d);
out_info->fps_n = fps_n;
out_info->fps_d = fps_d;
@ -1033,6 +1034,14 @@ gst_ffmpegviddec_negotiate (GstFFMpegVidDec * ffmpegdec,
/* calculate and update par now */
gst_ffmpegviddec_update_par (ffmpegdec, in_info, out_info);
/* Copy stereo/multiview info from upstream if set */
if (GST_VIDEO_INFO_MULTIVIEW_MODE (in_info) != GST_VIDEO_MULTIVIEW_MODE_NONE) {
GST_VIDEO_INFO_MULTIVIEW_MODE (out_info) =
GST_VIDEO_INFO_MULTIVIEW_MODE (in_info);
GST_VIDEO_INFO_MULTIVIEW_FLAGS (out_info) =
GST_VIDEO_INFO_MULTIVIEW_FLAGS (in_info);
}
if (!gst_video_decoder_negotiate (GST_VIDEO_DECODER (ffmpegdec)))
goto negotiate_failed;