• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NSSound thread-safety?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSSound thread-safety?


  • Subject: Re: NSSound thread-safety?
  • From: "Adam R. Maxwell" <email@hidden>
  • Date: Mon, 16 Jun 2008 20:45:48 -0400


On Jun 16, 2008, at 8:28 PM, Jens Alfke wrote:

On 16 Jun '08, at 5:15 PM, j o a r wrote:

I think that you can use QTKit to load and play sound files asynchronously.

QuickTime is pretty non-thread-safe too.

And there we're using the definition as "non-thread-safe"=="requires the main thread" :). QTMovie on 10.5 has +enterQTKitOnThread/ exitQTKitOnThread, but I saw regular crashes on secondary threads due to certain codecs trying to display an app-modal panel.


NSSound already plays the sound asynchronously. It's apparently loading the sound that blocks for a long time (although it's lazy enough that it won't actually load the sound till the first time you ask it to play). I'm not sure QT would do any better (especially since NSSound may well be using QT under the hood anyway.)

Or maybe the _initializeCA is setting up CoreAudio? Wild guess...I've never used CoreAudio.


--
Adam

_______________________________________________

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


References: 
 >NSSound thread-safety? (From: Jens Alfke <email@hidden>)
 >Re: NSSound thread-safety? (From: j o a r <email@hidden>)
 >Re: NSSound thread-safety? (From: Jens Alfke <email@hidden>)

  • Prev by Date: Re: NSSound thread-safety?
  • Next by Date: First Responder and taborder?
  • Previous by thread: Re: NSSound thread-safety?
  • Next by thread: Re: NSSound thread-safety?
  • Index(es):
    • Date
    • Thread