diff options
author | James Almer <jamrial@gmail.com> | 2020-07-29 19:08:17 -0300 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2020-07-29 19:34:39 -0300 |
commit | 8a3f561c341fb2c2b7667c38a6801e2633257577 (patch) | |
tree | 508c58fb5f873ea6d44e3b70be45a29b20654e48 | |
parent | 8821df6fcfc0a3b75c7079617f5917c031d0a63c (diff) | |
download | ffmpeg-8a3f561c341fb2c2b7667c38a6801e2633257577.tar.gz |
avcodec/options_table: make AVCodecContext->level search for child constants
This change makes it possible for child encoders to define custom level
option names which can be used for setting the AVCodecContext->level.
Based on 337fe4bcc2
Reviewed-by: jkqxz
Signed-off-by: James Almer <jamrial@gmail.com>
-rw-r--r-- | libavcodec/options_table.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/options_table.h b/libavcodec/options_table.h index 8ba137f51e..1d0db1b5a4 100644 --- a/libavcodec/options_table.h +++ b/libavcodec/options_table.h @@ -264,8 +264,8 @@ static const AVOption avcodec_options[] = { {"profile", NULL, OFFSET(profile), AV_OPT_TYPE_INT, {.i64 = FF_PROFILE_UNKNOWN }, INT_MIN, INT_MAX, V|A|E|CC, "avctx.profile"}, {"unknown", NULL, 0, AV_OPT_TYPE_CONST, {.i64 = FF_PROFILE_UNKNOWN }, INT_MIN, INT_MAX, V|A|E, "avctx.profile"}, {"main10", NULL, 0, AV_OPT_TYPE_CONST, {.i64 = FF_PROFILE_HEVC_MAIN_10 }, INT_MIN, INT_MAX, V|E, "avctx.profile"}, -{"level", NULL, OFFSET(level), AV_OPT_TYPE_INT, {.i64 = FF_LEVEL_UNKNOWN }, INT_MIN, INT_MAX, V|A|E, "level"}, -{"unknown", NULL, 0, AV_OPT_TYPE_CONST, {.i64 = FF_LEVEL_UNKNOWN }, INT_MIN, INT_MAX, V|A|E, "level"}, +{"level", NULL, OFFSET(level), AV_OPT_TYPE_INT, {.i64 = FF_LEVEL_UNKNOWN }, INT_MIN, INT_MAX, V|A|E|CC, "avctx.level"}, +{"unknown", NULL, 0, AV_OPT_TYPE_CONST, {.i64 = FF_LEVEL_UNKNOWN }, INT_MIN, INT_MAX, V|A|E, "avctx.level"}, {"lowres", "decode at 1= 1/2, 2=1/4, 3=1/8 resolutions", OFFSET(lowres), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, INT_MAX, V|A|D}, #if FF_API_PRIVATE_OPT {"skip_threshold", "frame skip threshold", OFFSET(frame_skip_threshold), AV_OPT_TYPE_INT, {.i64 = DEFAULT }, INT_MIN, INT_MAX, V|E}, |