[FFmpeg-devel] [PATCH] iff: MAUD support

Piotr Bandurski ami_stuff at o2.pl
Thu Nov 29 23:04:24 CET 2012


Hi,

> + st->codec->sample_rate = avio_rb32(pb);

It looks like this should be changed to mhdr_RateSource / mhdr_RateDevide
even if we get correct frequency without division (this may not be
the case in all situations):

I found this in the Toccata's sound card documentation:

"
- mhdr_RateSource
- mhdr_RateDevide
To figure out the sample frequency you MUST devide mhdr_RateSource by
mhdr_RateDevide!   Hardware  devices  often  calculate  their  sample
frequency  by  deviding  a  clock  source  (crystal  oscillator) by a
special value.

Examples:
mhdr_RateSource = 48000, mhdr_RateDevide = 1
  ==> SampleFrequency = 48000 / 1 = 48000
mhdr_RateSource = 24576000, mhdr_RateDevide = 768
  ==> SampleFrequency = 24576000 / 768 = 32000
"

Regards



More information about the ffmpeg-devel mailing list