[FFmpeg-devel] [PATCH] lavc/qsvenc: disable h264 look_ahead by default
Li, Zhong
zhong.li at intel.com
Tue Mar 6 10:41:03 EET 2018
> From: ffmpeg-devel [mailto:ffmpeg-devel-bounces at ffmpeg.org] On Behalf
> Of Mark Thompson
> Sent: Tuesday, March 6, 2018 8:32 AM
> To: ffmpeg-devel at ffmpeg.org
> Subject: Re: [FFmpeg-devel] [PATCH] lavc/qsvenc: disable h264 look_ahead
> by default
>
> On 01/03/18 05:20, Zhong Li wrote:
> > Look_ahead can provide quality improvements, but would better disable it
> by default due to some reasons:
> > 1. It is only available for some codecs (e.g. HEVC is not supported) on Intel
> > Haswell and plus platforms. Thus means it will be failed on some
> platforms.
> > 2. It significantly increases encoding latency and memory consumption.
> > 3. It may overwrite some other options such as CBR and CAVLC.
> >
> > Signed-off-by: Zhong Li <zhong.li at intel.com>
> > ---
> > libavcodec/qsvenc_h264.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/libavcodec/qsvenc_h264.c b/libavcodec/qsvenc_h264.c index
> > 09e4c0e..e01a2a3 100644
> > --- a/libavcodec/qsvenc_h264.c
> > +++ b/libavcodec/qsvenc_h264.c
> > @@ -109,7 +109,7 @@ static const AVOption options[] = {
> > { "max_dec_frame_buffering", "Maximum number of frames
> buffered in the DPB", OFFSET(qsv.max_dec_frame_buffering),
> AV_OPT_TYPE_INT, { .i64 = 0 }, 0, UINT16_MAX, VE },
> >
> > #if QSV_HAVE_LA
> > - { "look_ahead", "Use VBR algorithm with look ahead",
> OFFSET(qsv.look_ahead), AV_OPT_TYPE_INT, { .i64 = 1 }, 0, 1, VE },
> > + { "look_ahead", "Use VBR algorithm with look ahead",
> OFFSET(qsv.look_ahead), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, 1, VE },
> > { "look_ahead_depth", "Depth of look ahead in number frames",
> > OFFSET(qsv.look_ahead_depth), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, 100,
> > VE }, #endif #if QSV_HAVE_LA_DS
> >
>
> I agree with everything you've said, so applied.
Thanks!
More information about the ffmpeg-devel
mailing list