[FFmpeg-devel] [PATCH 15/18] ffmpeg: stop using non-public AVStream fields
Anton Khirnov
anton at khirnov.net
Fri Oct 9 16:04:27 EEST 2020
This effectively reverts ae2cb9290ac and 52c5521877a.
---
fftools/ffmpeg_opt.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fftools/ffmpeg_opt.c b/fftools/ffmpeg_opt.c
index 19f719e3ff..a5c92bf461 100644
--- a/fftools/ffmpeg_opt.c
+++ b/fftools/ffmpeg_opt.c
@@ -2215,7 +2215,7 @@ static int open_output_file(OptionsContext *o, const char *filename)
for (i = 0; i < nb_input_streams; i++) {
int new_area;
ist = input_streams[i];
- new_area = ist->st->codecpar->width * ist->st->codecpar->height + 100000000*!!ist->st->codec_info_nb_frames
+ new_area = ist->st->codecpar->width * ist->st->codecpar->height
+ 5000000*!!(ist->st->disposition & AV_DISPOSITION_DEFAULT);
if (ist->user_set_discard == AVDISCARD_ALL)
continue;
@@ -2239,7 +2239,7 @@ static int open_output_file(OptionsContext *o, const char *filename)
for (i = 0; i < nb_input_streams; i++) {
int score;
ist = input_streams[i];
- score = ist->st->codecpar->channels + 100000000*!!ist->st->codec_info_nb_frames
+ score = ist->st->codecpar->channels
+ 5000000*!!(ist->st->disposition & AV_DISPOSITION_DEFAULT);
if (ist->user_set_discard == AVDISCARD_ALL)
continue;
--
2.28.0
More information about the ffmpeg-devel
mailing list