Re: Newbie documentation for MIDI
Re: Newbie documentation for MIDI
- Subject: Re: Newbie documentation for MIDI
- From: Benjamin Golinvaux <email@hidden>
- Date: Tue, 26 Nov 2002 23:59:16 +0100
since 10.2, you can use
- (void)performSelectorOnMainThread:(SEL)aSelector withObject:(id)arg
waitUntilDone:(BOOL)wait
in NSObject
That's a wonderfully simple way to schedule a selector to be executed
on the receiver in the main AppKit thread
(the main( ) thread). Passing NO for 'wait' ensures the function
returns immediatly(***)
HTH
Benjamin
(***)However, i do NOT know if this is a blocking call or not. If
someone can give me this info, i'd be very happy.
In order to avoid any trouble, I ended up using a 3rd thread with a
small message queue and use semaphore_signal
(that does not block) in the RT thread and semaphore_wait in that 3rd
thread which, in turn, posts messages in the main
thread. Thus blocking or non-blocking was a non-issue for me by using
this "indirection" scheme (unless i've missed
something ;-( )
On Tuesday, Nov 26, 2002, at 22:18 Europe/Paris, Chris Reed wrote:
Owww.... :)
DO is *much* simpler to use than NSPorts or mach_ports, etc. Even for
inter-machine messaging, DO is quite simple.
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.