[FFmpeg-cvslog] lavc/qsvenc: disable h264 look_ahead by default

Zhong Li git at videolan.org
Tue Mar 6 02:29:29 EET 2018


ffmpeg | branch: master | Zhong Li <zhong.li at intel.com> | Thu Mar  1 13:20:19 2018 +0800| [0645698ecc2021ec422b625a6c1d235d2f252563] | committer: Mark Thompson

lavc/qsvenc: disable h264 look_ahead by default

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>
Signed-off-by: Mark Thompson <sw at jkqxz.net>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0645698ecc2021ec422b625a6c1d235d2f252563
---

 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 09e4c0e599..e01a2a3369 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



More information about the ffmpeg-cvslog mailing list