Hi,

On Sat, Jan 14, 2006 at 07:42:05PM +0000, Bluechip wrote:
> 
> >>Pretty much got a proper core written for an Audio file processor now.
> >>I have another simple question about MPEG Audio files.
> >>Am I ever likely to encounter an MPEG Audio file which will contain AUDIO 
> >>frames which differ in VERSION, LAYER, SAMPLERATE and/or CHANNELS?  Eg. 
> >>Some frames are 48KHz and other frames are 44.1KHz ...or some frames in 
> >>Stereo, some in Joint-Stereo?

a change of LAYER or SAMPLERATE requires a restart of the decoder.

> >>I have been unable to find any documentation which explicitly states 
> >>whether this should or shouldn't be allowed by the MPEG standard, and 
> >>nothing to say explicitly whether any players do or don't support this 
> >>type of change.
> >>There is no reason why not, the file would have a valid structure - but 
> >>it seems unlikely.
> >>This is relevant to creating the Xing/Xing or Xing/Info frame for VBRFix.
> >>Thanks for any help,
> >>BC
> >
> >Looking through the setup in Razorlame (a lame frontend for windows) there 
> >is the ability to allow different 'block' sizes between channels, although 
> >this is generally disabled. Another option give the ability to disable 
> >using 'short blocks', suggesting that the default is to allow them. Having 
> >stated this, I'm not too sure exactly what they are refering to with the 
> >term 'blocks'. It may mean the same as frame but I don't know.
> 
> Thanks, I too use razorlame, and also have no idea what short or long 
> blocks are - and google isn't helping much either.  LOL

IIRC, the audio data that belongs to each MPEG-1 layer III audio header
(in fact, the frame header can be located just in the middle of the
audio data it belongs to) is parted into 2 halves AKA granules. Those in
turn are parted into n (frequency) subbands, which can consist of either
1 long or 3 short blocks (windows) of samples (it's even possible to have long
blocks in the lower and short blocks in some upper subbands). The former
have a better frequency resolution, the latter a better time resolution
(eg to reduce pre-echoes). Try a percussive sound like from a
glockenspiel or triangle to hear the difference when short blocks are
disabled. 

Jacob

Reply via email to