diff options
author | Vittorio Giovara <vittorio.giovara@gmail.com> | 2015-09-09 04:18:26 +0200 |
---|---|---|
committer | Vittorio Giovara <vittorio.giovara@gmail.com> | 2016-01-21 15:33:19 -0500 |
commit | 0e6c8532215790bbe560a9eea4f3cc82bb55cf92 (patch) | |
tree | 0a45577e3a85a8aa3205093c39ef2d8dcca2d4a5 /libavcodec/mpegvideo.h | |
parent | 55c7e5bf7c8d368c9bc60a219b04849ec9f4c84c (diff) | |
download | ffmpeg-0e6c8532215790bbe560a9eea4f3cc82bb55cf92.tar.gz |
lavc: Move b_frame_strategy and b_sensitivity to codec private options
The b_frame_strategy option is only used by mpegvideoenc, qsv, x264, and
xavs, while b_sensitivity is only used by mpegvideoenc.
These are very codec-specific options, so deprecate the global variants.
Set proper limits to the maximum allowed values.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Diffstat (limited to 'libavcodec/mpegvideo.h')
-rw-r--r-- | libavcodec/mpegvideo.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/mpegvideo.h b/libavcodec/mpegvideo.h index 52c6f91d20..ea7a2d01df 100644 --- a/libavcodec/mpegvideo.h +++ b/libavcodec/mpegvideo.h @@ -525,6 +525,8 @@ typedef struct MpegEncContext { /* temporary frames used by b_frame_strategy = 2 */ AVFrame *tmp_frames[MAX_B_FRAMES + 2]; + int b_frame_strategy; + int b_sensitivity; } MpegEncContext; /* mpegvideo_enc common options */ @@ -573,6 +575,8 @@ typedef struct MpegEncContext { { "zero", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_ZERO }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \ { "epzs", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_EPZS }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \ { "xone", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_XONE }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \ +{"b_strategy", "Strategy to choose between I/P/B-frames", FF_MPV_OFFSET(b_frame_strategy), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, 2, FF_MPV_OPT_FLAGS }, \ +{"b_sensitivity", "Adjust sensitivity of b_frame_strategy 1", FF_MPV_OFFSET(b_sensitivity), AV_OPT_TYPE_INT, {.i64 = 40 }, 1, INT_MAX, FF_MPV_OPT_FLAGS }, \ extern const AVOption ff_mpv_generic_options[]; |