[FFmpeg-devel] [PATCH v6 1/2] lavc, doc, configure: add libxavs2 video encoder wrapper
Huiwen Ren
hwrenx at 126.com
Thu Sep 6 16:46:49 EEST 2018
At 2018-09-06 08:43:05, "Mark Thompson" <sw at jkqxz.net> wrote:
>On 05/09/18 14:38, hwren wrote:
>> Signed-off-by: hwren <hwrenx at 126.com>
[...]
>> + if (cae->xavs2_opts) {
>> + AVDictionary *dict = NULL;
>> + AVDictionaryEntry *en = NULL;
>> +
>> + if (!av_dict_parse_string(&dict, cae->xavs2_opts, "=", ":", 0)) {
>> + while ((en = av_dict_get(dict, "", en, AV_DICT_IGNORE_SUFFIX))) {
>> + xavs2_opt_set2(en->key, "%s", en->value);
>
>Should you check the result of this one? The user might pass soemthing completely invalid, which probably wants a warning at least.
Added into the macro function :)
[...]
>> + { "i_initial_qp" , "Quantization parameter" , OFFSET(i_initial_qp) , AV_OPT_TYPE_INT, {.i64 = 34 }, 1, 63, VE },
>
>If I understand what you said previously correctly, this is only used in constant-QP mode, and there it is used as the QP for every frame (not just the initial one)?
>
>If that's the case then it should probably not say "initial" - I would read "initial_qp" as meaning the QP used for the first frame only, so probably in modes with a bitrate target. Maybe change it to just be "qp"? That name is used by several other encoders, including libx264 and libxavs.
If "RateControl" is opened, the "initial_qp" will be used for the first frame and kept for all the other frames (constant-QP) and if there is no rate control, the initial_qp will only work for the first frame (xavs2 will always initial the qp for the first frame). So...maybe better with "initial"?
Thanks,
Huiwen Ren
More information about the ffmpeg-devel
mailing list