[FFmpeg-devel] [PATCH v2] libavcodec/qsvence: Use QSV encoder defaults as ffmpeg defaults

James Almer jamrial at gmail.com
Wed Aug 11 15:54:54 EEST 2021


On 8/10/2021 11:55 PM, Xiang, Haihao wrote:
> On Tue, 2021-08-10 at 08:53 +0000, Soft Works wrote:
>> Signed-off-by: softworkz <softworkz at hotmail.com>
>> ---
>>   libavcodec/qsvenc.h | 4 ++--
>>   1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/libavcodec/qsvenc.h b/libavcodec/qsvenc.h
>> index fc8a14143e..58984f996f 100644
>> --- a/libavcodec/qsvenc.h
>> +++ b/libavcodec/qsvenc.h
>> @@ -76,8 +76,8 @@
>>   
>>   #define QSV_COMMON_OPTS \
>>   { "async_depth", "Maximum processing parallelism", OFFSET(qsv.async_depth),
>> AV_OPT_TYPE_INT, { .i64 = ASYNC_DEPTH_DEFAULT }, 1, INT_MAX, VE
>> },                          \
>> -{ "avbr_accuracy",    "Accuracy of the AVBR
>> ratecontrol",    OFFSET(qsv.avbr_accuracy),    AV_OPT_TYPE_INT, { .i64 = 0 },
>> 0, INT_MAX, VE },                             \
>> -{ "avbr_convergence", "Convergence of the AVBR ratecontrol",
>> OFFSET(qsv.avbr_convergence), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, INT_MAX, VE
>> },                             \
>> +{ "avbr_accuracy",    "Accuracy of the AVBR ratecontrol (unit of tenth of
>> percent)",    OFFSET(qsv.avbr_accuracy),    AV_OPT_TYPE_INT, { .i64 = 1 }, 1,
>> UINT16_MAX, VE },                             \
>> +{ "avbr_convergence", "Convergence of the AVBR ratecontrol (unit of 100
>> frames)", OFFSET(qsv.avbr_convergence), AV_OPT_TYPE_INT, { .i64 = 1 }, 1,
>> UINT16_MAX, VE },                             \
>>   { "preset", NULL, OFFSET(qsv.preset), AV_OPT_TYPE_INT, { .i64 =
>> MFX_TARGETUSAGE_BALANCED }, MFX_TARGETUSAGE_BEST_QUALITY,
>> MFX_TARGETUSAGE_BEST_SPEED,   VE, "preset" }, \
>>   { "veryfast",    NULL, 0, AV_OPT_TYPE_CONST, { .i64 =
>> MFX_TARGETUSAGE_BEST_SPEED  },   INT_MIN, INT_MAX, VE, "preset"
>> },                                                \
>>   { "faster",      NULL, 0, AV_OPT_TYPE_CONST, { .i64 =
>> MFX_TARGETUSAGE_6  },            INT_MIN, INT_MAX, VE, "preset"
>> },
> 
> lgtm. thx!

Applied.


More information about the ffmpeg-devel mailing list