[FFmpeg-devel,2/2] vaapi_h264: fix quality level setting range

Submitted by Zhong Li on Aug. 21, 2017, 3:05 a.m.

Details

Message ID 20170821030502.14430-1-zhong.li@intel.com
State New
Headers show

Commit Message

Zhong Li Aug. 21, 2017, 3:05 a.m.
The max value of quality should be 7 instead of 8.
It has been fixed in intel-vaapi-driver(https://github.com/01org/intel-vaapi-driver/commit/53fa3daa12f6dbdd391d24ab479dc601ae37a89d)

Signed-off-by: Zhong Li <zhong.li@intel.com>
---
 libavcodec/vaapi_encode_h264.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/libavcodec/vaapi_encode_h264.c b/libavcodec/vaapi_encode_h264.c
index f9fcd805a4..cf48cc9340 100644
--- a/libavcodec/vaapi_encode_h264.c
+++ b/libavcodec/vaapi_encode_h264.c
@@ -1279,7 +1279,7 @@  static const AVOption vaapi_encode_h264_options[] = {
     { "qp", "Constant QP (for P-frames; scaled by qfactor/qoffset for I/B)",
       OFFSET(qp), AV_OPT_TYPE_INT, { .i64 = 20 }, 0, 52, FLAGS },
     { "quality", "Set encode quality (trades off against speed, higher is faster)",
-      OFFSET(quality), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, 8, FLAGS },
+      OFFSET(quality), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, 7, FLAGS },
     { "low_power", "Use low-power encoding mode (experimental: only supported "
       "on some platforms, does not support all features)",
       OFFSET(low_power), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, 1, FLAGS },