Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

AUAudioFilePlayer priming for compressed files



For ExtAudioFile/CAAudioFile you can "trick" the AudioConverter into making compressed file reads sample accurate by seeking back a few mp3-sized frames and throwing away the samples up to your desired start point. I'd love to get this working with the AudioFilePlayer AU, as trying to chop up compressed files and play them back in order does not work. But since the AudioFilePlayer does all the seeking/ reading for you, I can't tell if this is possible. I saw the kAudioUnitProperty_ScheduledFilePrime property but no docs for it other than to set it to default. Is there a way to "prime" the file player AU a few frames in the past before scheduling?

We currently do this the long way, using MovieAudioExtraction into an ABL for ScheduledSoundPlayer. We have to start decoding from 0 to be sample accurate in QT's MAE-- an enormous waste of CPU when you're trying to get 0.3s of audio out near the end of a 10m track. AudioFile was better for mp3s-- you only had to go a few frames back, not all the way to the beginning. So we'd love to shoehorn that into AudioFilePlayer and chuck all of the manual management of IO and PCM ram.

-Brian


_______________________________________________ Do not post admin requests to the list. They will be ignored. Coreaudio-api mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/coreaudio-api/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.