Commit 1955ffed authored by Hyunjun Ko's avatar Hyunjun Ko Committed by Sreerenj Balachandran
Browse files

msdk: dec: set framerate to the driver only if provided

For example, if framerate 0/1 is provided from upstream, the driver
fails to configure and complain about it.

We can let it go and make the driver assuming framerate itself.

https://bugzilla.gnome.org/show_bug.cgi?id=789752
parent 0eaf3bdc
......@@ -256,8 +256,13 @@ gst_msdkdec_init_decoder (GstMsdkDec * thiz)
thiz->param.mfx.FrameInfo.Height = GST_ROUND_UP_32 (info->height);
thiz->param.mfx.FrameInfo.CropW = info->width;
thiz->param.mfx.FrameInfo.CropH = info->height;
/* Set framerate only if provided.
* If not, framerate will be assumed inside the driver */
if (info->fps_n > 0 && info->fps_d > 0) {
thiz->param.mfx.FrameInfo.FrameRateExtN = info->fps_n;
thiz->param.mfx.FrameInfo.FrameRateExtD = info->fps_d;
}
thiz->param.mfx.FrameInfo.AspectRatioW = info->par_n;
thiz->param.mfx.FrameInfo.AspectRatioH = info->par_d;
thiz->param.mfx.FrameInfo.PicStruct = MFX_PICSTRUCT_PROGRESSIVE;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment