diff options
author | Benjamin Larsson <banan@ludd.ltu.se> | 2007-12-20 11:21:10 +0000 |
---|---|---|
committer | Benjamin Larsson <banan@ludd.ltu.se> | 2007-12-20 11:21:10 +0000 |
commit | 7b76c22465b3973b2bfc1669f2605d196500f095 (patch) | |
tree | b35948ff42cbad0c8f20813329cd4abec6ea7d31 /libavformat/flvdec.c | |
parent | 5efaf00029489202b0d42cfedb484ecfc925a639 (diff) | |
download | ffmpeg-7b76c22465b3973b2bfc1669f2605d196500f095.tar.gz |
Correctly handle FLV_CODECID_NELLYMOSER_8HZ_MONO files
Originally committed as revision 11284 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/flvdec.c')
-rw-r--r-- | libavformat/flvdec.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/flvdec.c b/libavformat/flvdec.c index 885c4a6fe5..b253b954b2 100644 --- a/libavformat/flvdec.c +++ b/libavformat/flvdec.c @@ -179,6 +179,7 @@ static int amf_parse_object(AVFormatContext *s, AVStream *astream, AVStream *vst } else if(!strcmp(key, "audiosamplerate") && acodec && num_val >= 0) { //some tools, like FLVTool2, write consistently approximate metadata sample rates + if (!acodec->sample_rate) { switch((int)num_val) { case 44000: acodec->sample_rate = 44100 ; break; case 22000: acodec->sample_rate = 22050 ; break; @@ -186,6 +187,7 @@ static int amf_parse_object(AVFormatContext *s, AVStream *astream, AVStream *vst case 5000 : acodec->sample_rate = 5512 ; break; default : acodec->sample_rate = num_val; } + } } } } |