Fix for QuickTimeAudioFormat


#1

when the reader gets repositioned in readSamples() because

you get frequency-related audioglitches.

Solution:
set the read-position 16384 samples before the current read-Position and read 16384 samples into a dummy-buffer

Quicktime needs the additional (mp3 frequency-related) information, to calculated the right amplitude at the exact reading position.


#2

Well, yes… I’m not too bothered about a glitch when you reposition the stream, if you’re skipping around, then glitches are inevitable, aren’t they?


#3

for my application, i developed a advanced caching algorithm, which loads parts of files regarding there play priority (like a sampler). Also you can skip around and play the same file at different positions.
So it can be that first it read sample #10000 - #20000 first and thereafter 0 - 9999, and put it together later. Somebody has mentioned that QuickTime is introducing some kind of fade-in into the material, but i want to correct this, the codec just needs the information (fft) to reconstruct the amplitude at a certain position. Maybe its a useful information for somebody else, i do this preloading anyway, but i thought it would better fit in the AudioFormat-class.