mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-05-31 08:57:49 +00:00
lavf/utils: only complain about aspect missmatch when the difference is "meassureable"
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
f9bb7395a1
commit
e8d8517b16
1 changed files with 3 additions and 1 deletions
|
@ -3012,7 +3012,9 @@ int avformat_write_header(AVFormatContext *s, AVDictionary **options)
|
||||||
ret = AVERROR(EINVAL);
|
ret = AVERROR(EINVAL);
|
||||||
goto fail;
|
goto fail;
|
||||||
}
|
}
|
||||||
if(av_cmp_q(st->sample_aspect_ratio, st->codec->sample_aspect_ratio)){
|
if(av_cmp_q(st->sample_aspect_ratio, st->codec->sample_aspect_ratio)
|
||||||
|
&& FFABS(av_q2d(st->sample_aspect_ratio) - av_q2d(st->codec->sample_aspect_ratio)) > 0.001
|
||||||
|
){
|
||||||
av_log(s, AV_LOG_ERROR, "Aspect ratio mismatch between encoder and muxer layer\n");
|
av_log(s, AV_LOG_ERROR, "Aspect ratio mismatch between encoder and muxer layer\n");
|
||||||
ret = AVERROR(EINVAL);
|
ret = AVERROR(EINVAL);
|
||||||
goto fail;
|
goto fail;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue