# HG changeset patch # User bcoudurier # Date 1283977094 0 # Node ID 35bb7cdfe337f28cde6ef160ce86c3728ad51cf9 # Parent e0d8a52ce091b9f329c000371b55c178c258b141 In mov demuxer, do not override aspect ratio in tkhd by pasp like quicktime, fix issue #1539 diff -r e0d8a52ce091 -r 35bb7cdfe337 mov.c --- a/mov.c Tue Sep 07 21:06:21 2010 +0000 +++ b/mov.c Wed Sep 08 20:18:14 2010 +0000 @@ -584,12 +584,13 @@ return 0; st = c->fc->streams[c->fc->nb_streams-1]; - if (den != 0) { - if ((st->sample_aspect_ratio.den != 1 || st->sample_aspect_ratio.num) && // default - (den != st->sample_aspect_ratio.den || num != st->sample_aspect_ratio.num)) - av_log(c->fc, AV_LOG_WARNING, - "sample aspect ratio already set to %d:%d, overriding by 'pasp' atom\n", - st->sample_aspect_ratio.num, st->sample_aspect_ratio.den); + if ((st->sample_aspect_ratio.den != 1 || st->sample_aspect_ratio.num) && // default + (den != st->sample_aspect_ratio.den || num != st->sample_aspect_ratio.num)) { + av_log(c->fc, AV_LOG_WARNING, + "sample aspect ratio already set to %d:%d, ignoring 'pasp' atom (%d:%d)\n", + st->sample_aspect_ratio.num, st->sample_aspect_ratio.den, + num, den); + } else if (den != 0) { st->sample_aspect_ratio.num = num; st->sample_aspect_ratio.den = den; }