• 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: NSTimer and trackpad and mouse clicks
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTimer and trackpad and mouse clicks


  • Subject: Re: NSTimer and trackpad and mouse clicks
  • From: Paul Davis <email@hidden>
  • Date: Tue, 08 Nov 2011 14:31:19 -0500

On Tue, Nov 8, 2011 at 2:17 PM, Mark Pauley <email@hidden> wrote:

> I agree here.  My caveat: be very averse to creating a new NSThread.  You
> have k problems, so you spawn a new thread... now you have 2^k problems ;)
> When at all possible: prefer asynchronous / event-driven solutions to
> synchronous / concurrent solutions.

you cannot do realtime programming in this way. why? because there is
absolutely no bound on how long the event handlers will take. the
sensible thing to do, which almost everybody who writes audio & MIDI
software does, is to split things into (at least) two threads, one
with RT constraints imposed on it, and the other one free to do
basically whatever it wants, whenever it wants (GUI event handling,
redraws, chatting over the network, whatever).

multithreaded programming is hard, yes. but RT programming is hard
too. you make it harder by trying to do non-RT and RT work in the same
thread.
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >NSTimer and trackpad and mouse clicks (From: Tom Jeffries <email@hidden>)
 >Re: NSTimer and trackpad and mouse clicks (From: Mark Pauley <email@hidden>)
 >Re: NSTimer and trackpad and mouse clicks (From: Tom Jeffries <email@hidden>)
 >Re: NSTimer and trackpad and mouse clicks (From: Mark Pauley <email@hidden>)
 >Re: NSTimer and trackpad and mouse clicks (From: Brian Willoughby <email@hidden>)
 >Re: NSTimer and trackpad and mouse clicks (From: Mark Pauley <email@hidden>)

  • Prev by Date: Re: NSTimer and trackpad and mouse clicks
  • Next by Date: Re: kAudioFormatUnsupportedDataFormatError
  • Previous by thread: Re: NSTimer and trackpad and mouse clicks
  • Next by thread: Re: NSTimer and trackpad and mouse clicks
  • Index(es):
    • Date
    • Thread