diff mbox series

[FFmpeg-devel] libavcodec/qsvenc.c: Set height and width alignment when using mjpeg_qsv

Message ID 20200120095838.165480-1-jon.cook@cubicmotion.com
State Withdrawn
Headers show
Series [FFmpeg-devel] libavcodec/qsvenc.c: Set height and width alignment when using mjpeg_qsv
Related show

Checks

Context Check Description
andriy/ffmpeg-patchwork pending
andriy/ffmpeg-patchwork success Applied patch
andriy/ffmpeg-patchwork success Configure finished
andriy/ffmpeg-patchwork success Make finished
andriy/ffmpeg-patchwork success Make fate finished

Commit Message

Jon Cook Jan. 20, 2020, 9:58 a.m. UTC
From: JonCookCubic <jon.cook@cubicmotion.com>

Currently width_align and height_align are zero which cases "Error submitting the frame for encoding". This change sets the alignments.

Signed-off-by: Jon Cook <jon.cook@cubicmotion.com>
---
 libavcodec/qsvenc.c | 3 +++
 1 file changed, 3 insertions(+)
diff mbox series

Patch

diff --git a/libavcodec/qsvenc.c b/libavcodec/qsvenc.c
index 9e416500e9..b18393532f 100644
--- a/libavcodec/qsvenc.c
+++ b/libavcodec/qsvenc.c
@@ -470,6 +470,9 @@  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;
+
     return 0;
 }