Re: Design issue related to my problem with NSSound -isPlaying
Re: Design issue related to my problem with NSSound -isPlaying
- Subject: Re: Design issue related to my problem with NSSound -isPlaying
- From: Jens Alfke <email@hidden>
- Date: Mon, 23 Jul 2012 09:44:24 -0700
On Jul 23, 2012, at 7:53 AM, Kyle Sluder <email@hidden> wrote:
> NSSound is not the appropriate API for this. It makes no guarantees about its responsiveness. Look into AVFoundation.
Agreed. NSSound is basically a convenience for playing beep sounds as UI feedback, nothing more. It's not even guaranteed to _start_ the sound when you want: I've had trouble in the past with it blocking for up to a second while reading and decoding the audio file from disk.
If you need synchronization, why not just make a movie with an embedded soundtrack and play that? Synchronization of audio to video is exactly what AV playback frameworks excel at — there is a lot of complexity to it, as you're discovering, and why should you have to re-invent the wheel?
—Jens
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden