[FFmpeg-cvslog] r16723 - trunk/libavcodec/flac.c
jbr
subversion
Thu Jan 22 23:23:59 CET 2009
Author: jbr
Date: Thu Jan 22 23:23:58 2009
New Revision: 16723
Log:
flacdec: add support for 3 additional sample rate codes
Modified:
trunk/libavcodec/flac.c
Modified: trunk/libavcodec/flac.c
==============================================================================
--- trunk/libavcodec/flac.c Thu Jan 22 20:48:10 2009 (r16722)
+++ trunk/libavcodec/flac.c Thu Jan 22 23:23:58 2009 (r16723)
@@ -76,7 +76,8 @@ typedef struct FLACContext {
#define METADATA_TYPE_STREAMINFO 0
static const int sample_rate_table[] =
-{ 0, 0, 0, 0,
+{ 0,
+ 88200, 176400, 192000,
8000, 16000, 22050, 24000, 32000, 44100, 48000, 96000,
0, 0, 0, 0 };
@@ -558,7 +559,7 @@ static int decode_frame(FLACContext *s,
if (sample_rate_code == 0){
samplerate= s->samplerate;
- }else if ((sample_rate_code > 3) && (sample_rate_code < 12))
+ }else if (sample_rate_code < 12)
samplerate = sample_rate_table[sample_rate_code];
else if (sample_rate_code == 12)
samplerate = get_bits(&s->gb, 8) * 1000;
More information about the ffmpeg-cvslog
mailing list