Fixes ticket #11460.
Unified · Split
| @@ -5186,7 +5186,7 @@ static int mov_read_trak(MOVContext *c, AVIOContext *pb, MOVAtom atom) · 5185 unmodified lines | |||
| 5186 | } | 5186 | } |
| 5187 | 5187 | ||
| 5188 | if (st->codecpar->codec_type == AVMEDIA_TYPE_VIDEO) { | 5188 | if (st->codecpar->codec_type == AVMEDIA_TYPE_VIDEO) { |
| 5189 | int stts_constant = !!sc->stts_count; | 5189 | int stts_constant = sc->stts_count && sc->tts_count; |
| 5190 | if (sc->h_spacing && sc->v_spacing) | 5190 | if (sc->h_spacing && sc->v_spacing) |
| 5191 | av_reduce(&st->sample_aspect_ratio.num, &st->sample_aspect_ratio.den, | 5191 | av_reduce(&st->sample_aspect_ratio.num, &st->sample_aspect_ratio.den, |
| 5192 | sc->h_spacing, sc->v_spacing, INT_MAX); | 5192 | sc->h_spacing, sc->v_spacing, INT_MAX); |