diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2004-10-18 09:43:39 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2004-10-18 09:43:39 +0000 |
commit | 595bf4ef63fc9a4d863b5ecc53605640301f2273 (patch) | |
tree | b7dddab15a994a4ea2256c94d55ce95fe7526588 /libavformat | |
parent | 15862411e696ffab99821e6204f48806d1b34ead (diff) | |
download | ffmpeg-595bf4ef63fc9a4d863b5ecc53605640301f2273.tar.gz |
set correct timebase
Originally committed as revision 3607 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/au.c | 1 | ||||
-rw-r--r-- | libavformat/raw.c | 1 | ||||
-rw-r--r-- | libavformat/sol.c | 3 | ||||
-rw-r--r-- | libavformat/wav.c | 4 |
4 files changed, 7 insertions, 2 deletions
diff --git a/libavformat/au.c b/libavformat/au.c index 6ce326f57a..1721902623 100644 --- a/libavformat/au.c +++ b/libavformat/au.c @@ -148,6 +148,7 @@ static int au_read_header(AVFormatContext *s, st->codec.codec_id = codec; st->codec.channels = channels; st->codec.sample_rate = rate; + av_set_pts_info(st, 64, 1, rate); return 0; } diff --git a/libavformat/raw.c b/libavformat/raw.c index 23ba5006be..2ae744943d 100644 --- a/libavformat/raw.c +++ b/libavformat/raw.c @@ -60,6 +60,7 @@ static int raw_read_header(AVFormatContext *s, AVFormatParameters *ap) case CODEC_TYPE_AUDIO: st->codec.sample_rate = ap->sample_rate; st->codec.channels = ap->channels; + av_set_pts_info(st, 64, 1, st->codec.sample_rate); break; case CODEC_TYPE_VIDEO: st->codec.frame_rate = ap->frame_rate; diff --git a/libavformat/sol.c b/libavformat/sol.c index 2631310c9b..038feeaac6 100644 --- a/libavformat/sol.c +++ b/libavformat/sol.c @@ -117,7 +117,8 @@ static int sol_read_header(AVFormatContext *s, st->codec.codec_tag = id; st->codec.codec_id = codec; st->codec.channels = channels; - st->codec.sample_rate = rate; + st->codec.sample_rate = rate; + av_set_pts_info(st, 64, 1, rate); return 0; } diff --git a/libavformat/wav.c b/libavformat/wav.c index a85e9d6665..2d28b8f2cf 100644 --- a/libavformat/wav.c +++ b/libavformat/wav.c @@ -301,7 +301,9 @@ static int wav_read_header(AVFormatContext *s, get_wav_header(pb, &st->codec, size); st->need_parsing = 1; - + + av_set_pts_info(st, 64, 1, st->codec.sample_rate); + size = find_tag(pb, MKTAG('d', 'a', 't', 'a')); if (size < 0) return -1; |