Browse Source

mov: Set the timescale for data streams

Data streams have a defined timebase, do not ignore it.
Luca Barbato 11 years ago
parent
commit
3952303010
1 changed files with 2 additions and 0 deletions
  1. 2 0
      libavformat/movenc.c

+ 2 - 0
libavformat/movenc.c

@@ -3126,6 +3126,8 @@ static int mov_write_header(AVFormatContext *s)
             }
         } else if (st->codec->codec_type == AVMEDIA_TYPE_SUBTITLE) {
             track->timescale = st->codec->time_base.den;
+        } else if (st->codec->codec_type == AVMEDIA_TYPE_DATA) {
+            track->timescale = st->codec->time_base.den;
         }
         if (!track->height)
             track->height = st->codec->height;