aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorBaptiste Coudurier <baptiste.coudurier@gmail.com>2007-03-08 22:14:04 +0000
committerBaptiste Coudurier <baptiste.coudurier@gmail.com>2007-03-08 22:14:04 +0000
commitdc13d0b5ae2ea60861ad0716ce2b7c92be1a38b2 (patch)
tree4b004b6f35c5aeb295741a6718991141c9a9e0d2 /libavformat
parentb912ef3fc924a2cd2ee29d004b6d2bb9c37862ba (diff)
downloadffmpeg-dc13d0b5ae2ea60861ad0716ce2b7c92be1a38b2.tar.gz
seems safer to set pts timebase to sample rate, fix some mp3
Originally committed as revision 8300 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/swf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/swf.c b/libavformat/swf.c
index 49c43431f4..7d889af7d0 100644
--- a/libavformat/swf.c
+++ b/libavformat/swf.c
@@ -679,7 +679,6 @@ static int swf_read_header(AVFormatContext *s, AVFormatParameters *ap)
v = get_byte(pb);
swf->samples_per_frame = get_le16(pb);
ast = av_new_stream(s, -1); /* -1 to avoid clash with video stream ch_id */
- av_set_pts_info(ast, 64, 256, swf->frame_rate); /* XXX same as video stream */
swf->audio_stream_index = ast->index;
ast->codec->channels = 1 + (v&1);
ast->codec->codec_type = CODEC_TYPE_AUDIO;
@@ -689,6 +688,7 @@ static int swf_read_header(AVFormatContext *s, AVFormatParameters *ap)
if (!sample_rate_code)
return AVERROR_IO;
ast->codec->sample_rate = 11025 << (sample_rate_code-1);
+ av_set_pts_info(ast, 64, 1, ast->codec->sample_rate);
if (len > 4)
url_fskip(pb,len-4);