From 8479f99c7dd227d9cb94d262602f1298f71cf33b Mon Sep 17 00:00:00 2001 From: Mark Thompson Date: Tue, 18 Sep 2018 23:30:46 +0100 Subject: vaapi_encode: Add support for max QP in rate control This was added in libva 2.1.0 (VAAPI 1.1.0). Use AVCodecContext.qmax, matching the existing behaviour for qmin, and clean up the defaults so that we only pass min/max when explicitly set. --- libavcodec/vaapi_encode_h264.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'libavcodec/vaapi_encode_h264.c') diff --git a/libavcodec/vaapi_encode_h264.c b/libavcodec/vaapi_encode_h264.c index c63766d918..e903b251c0 100644 --- a/libavcodec/vaapi_encode_h264.c +++ b/libavcodec/vaapi_encode_h264.c @@ -1033,7 +1033,8 @@ static const AVCodecDefault vaapi_encode_h264_defaults[] = { { "i_qoffset", "0" }, { "b_qfactor", "6/5" }, { "b_qoffset", "0" }, - { "qmin", "0" }, + { "qmin", "-1" }, + { "qmax", "-1" }, { NULL }, }; -- cgit v1.2.3