@@ -697,10 +697,13 @@ profiles are documented in the relevant encoder documentation.
@item level @var{integer} (@emph{encoding,audio,video})
+Set the encoder level. This level depends on the specific codec, and
+might correspond to the profile level. It is set by default to
+@samp{unknown}.
+
Possible values:
@table @samp
@item unknown
-
@end table
@item lowres @var{integer} (@emph{decoding,audio,video})
@@ -1722,7 +1722,9 @@ typedef struct AVCodecContext {
/**
* level
- * - encoding: Set by user.
+ * - encoding: Set by user, corresponds to a specific level defined by the
+ * codec, usually corresponding to the profile level, if not specified it
+ * set to FF_LEVEL_UNKNOWN
* - decoding: Set by libavcodec.
*/
int level;
@@ -226,7 +226,7 @@ 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|CC, "avctx.level"},
+{"level", "encoding level, usually corresponding to the profile level, codec-specific", 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},
{"cmp", "full-pel ME compare function", OFFSET(me_cmp), AV_OPT_TYPE_INT, {.i64 = DEFAULT }, INT_MIN, INT_MAX, V|E, "cmp_func"},