# HG changeset patch # User bcoudurier # Date 1224873386 0 # Node ID cf359952a1fc4c0cfbc55c587f548c6a016de597 # Parent 476a5d7182db621e9fc26b8c968332f10cb762ae force sample rate to 16khz for speex in flv, fix speexaudio.flv diff -r 476a5d7182db -r cf359952a1fc flvdec.c --- a/flvdec.c Fri Oct 24 16:46:43 2008 +0000 +++ b/flvdec.c Fri Oct 24 18:36:26 2008 +0000 @@ -53,7 +53,10 @@ acodec->codec_id = acodec->bits_per_coded_sample == 8 ? CODEC_ID_PCM_S8 : CODEC_ID_PCM_S16LE; break; case FLV_CODECID_AAC : acodec->codec_id = CODEC_ID_AAC; break; case FLV_CODECID_ADPCM: acodec->codec_id = CODEC_ID_ADPCM_SWF; break; - case FLV_CODECID_SPEEX: acodec->codec_id = CODEC_ID_SPEEX; break; + case FLV_CODECID_SPEEX: + acodec->codec_id = CODEC_ID_SPEEX; + acodec->sample_rate = 16000; + break; case FLV_CODECID_MP3 : acodec->codec_id = CODEC_ID_MP3 ; astream->need_parsing = AVSTREAM_PARSE_FULL; break; case FLV_CODECID_NELLYMOSER_8KHZ_MONO: acodec->sample_rate = 8000; //in case metadata does not otherwise declare samplerate