mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-26 19:01:44 +02:00
libavcodec/qsvenc.c: Set mjpeg height and width alignment
Currently width_align and height_align are zero when encoding with mjpeg_qsv, which causes "Error submitting the frame for encoding". This patch sets the alignments. There is a little bit more about the problem here http://ffmpeg.org/pipermail/ffmpeg-user/2019-November/046143.html Signed-off-by: JonCookCubic <jon.cook@cubicmotion.com> Signed-off-by: Zhong Li <zhongli_dev@126.com>
This commit is contained in:
parent
601d574440
commit
566de25599
@ -470,6 +470,12 @@ static int init_video_param_jpeg(AVCodecContext *avctx, QSVEncContext *q)
|
||||
q->param.mfx.Quality = av_clip(avctx->global_quality, 1, 100);
|
||||
q->param.mfx.RestartInterval = 0;
|
||||
|
||||
q->width_align = 16;
|
||||
q->height_align = 16;
|
||||
|
||||
q->param.mfx.FrameInfo.Width = FFALIGN(avctx->width, q->width_align);
|
||||
q->param.mfx.FrameInfo.Height = FFALIGN(avctx->height, q->height_align);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user