Commit 1cc3851b authored by Andriy Gelman's avatar Andriy Gelman

avcodec/v4l2_m2m_enc: Enable frame level rate control by default

Without this setting, bitrate and qmin/qmax options have no
effect on the s5p-mfc hardware encoder.
Reviewed-by: 's avatarMing Qian <ming.qian@nxp.com>
Signed-off-by: 's avatarAndriy Gelman <andriy.gelman@gmail.com>
parent 9b5001a4
......@@ -192,6 +192,7 @@ static int v4l2_prepare_encoder(V4L2m2mContext *s)
/* set ext ctrls */
v4l2_set_ext_ctrl(s, MPEG_CID(HEADER_MODE), MPEG_VIDEO(HEADER_MODE_SEPARATE), "header mode", 0);
v4l2_set_ext_ctrl(s, MPEG_CID(BITRATE) , avctx->bit_rate, "bit rate", 1);
v4l2_set_ext_ctrl(s, MPEG_CID(FRAME_RC_ENABLE), 1, "frame level rate control", 0);
v4l2_set_ext_ctrl(s, MPEG_CID(GOP_SIZE), avctx->gop_size,"gop size", 1);
av_log(avctx, AV_LOG_DEBUG,
......
Markdown is supported
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