I think that's correct... So at all Pd callbacks (new, free, and
message routines, even setup()) the lock would already have been obtained
by Pd, and anytime you want your own thread to call into Pd you just
lock it and go.
On Mon, Jun 02, 2003 at 09:00:21PM +0200, Thomas Grill wrote:
What's wrong with simply putting a mutex around all of Pd? that way other
threads could just make calls right into "receive" objects without having
to set and wait for clock callbacks. Perhaps I'm missing something but
seems the much simpler solution for making threaded externs.
Pd's scheduler would simply lock all pf Pd whenever it issues a message or
runs a DSP tick, and unlock it when it ``idles".
that sounds very reasonable and efficient.
The reason why i preferred the clock functions is probably my lack of
Is my understanding right that there shall be something like pd_lock() and
pd_unlock() functions that are used around every call into the pd API from a