1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-26 19:01:44 +02:00

lavc/qsv: handle MFX_FRAMETYPE_UNKNOWN case

Signed-off-by: Zhong Li <zhong.li@intel.com>
This commit is contained in:
Zhong Li 2018-07-03 16:01:30 +08:00
parent 3ce4034308
commit 3c26ce4644

View File

@ -198,7 +198,7 @@ int ff_qsv_find_surface_idx(QSVFramesContext *ctx, QSVFrame *frame)
enum AVPictureType ff_qsv_map_pictype(int mfx_pic_type)
{
enum AVPictureType type = AV_PICTURE_TYPE_NONE;
enum AVPictureType type;
switch (mfx_pic_type & 0x7) {
case MFX_FRAMETYPE_I:
if (mfx_pic_type & MFX_FRAMETYPE_S)
@ -215,6 +215,9 @@ enum AVPictureType ff_qsv_map_pictype(int mfx_pic_type)
else
type = AV_PICTURE_TYPE_P;
break;
case MFX_FRAMETYPE_UNKNOWN:
type = AV_PICTURE_TYPE_NONE;
break;
default:
av_assert0(0);
}