[PD] stability of PD on Windows?

Christof Ressi christof.ressi at gmx.at
Fri Sep 27 20:26:59 CEST 2019

In pd's regular scheduler, the main thread computes audio and pushes the samples to a lockfree ringbuffer. The actual audio callback runs in a different thread and polls samples from the ringbuffer as needed. This mechanism is important for Pd because the audio thread performs many unbounded operations which are not real-time-safe. This is a consequence of its deterministic architecture.

On the other hand, an application like supercollider has very strict rules about what shall be done on the audio thread, so audio can be computed directly in the audio callback. Non-realtime operations are performed asynchronously in a worker thread. Both threads communicate via a lockfree command FIFO. One could say that Supercollider's architecture is indeterministic. This indeterminacy can be partially overcome by scheduling commands in advance using timestamps. So there's again a trade-off between latency and accuracy.


> Gesendet: Freitag, 27. September 2019 um 19:31 Uhr
> Von: "Martin Peach" <chakekatzil at gmail.com>
> An: Pd-List <pd-list at lists.iem.at>
> Betreff: Re: [PD] stability of PD on Windows?
> On Fri, Sep 27, 2019 at 12:24 PM Christof Ressi <christof.ressi at gmx.at>
> wrote:
> > > For me the audio is distorted unless I also tick "Use Callbacks".
> >
> > Really, even if you use an ASIO driver? I never had the experience that
> > "Use Callbacks" improves things, on the contrary. Also, it's worth noting
> > that with "Use Callbacks", the "delay" parameter doesn't do any thing, the
> > latency can only be set with the ASIO block size.
> >
> I don't know which ASIO driver I'm using, maybe it came with the interface
> (I selected "ASIO:Focusrite USB 2.0 Audio Driver" in the dialog). I tried
> various delays with no callbacks and now I get no distortion with a delay
> of 11 or more and block size 64. With Delay less than 11 the audio is
> chopped up.
> Without callbacks, I get clicks and dropouts occasionally if I do things
> with the mouse. That's why I assumed it was the better choice. (Doesn't
> audio processing always use callbacks anyway? Otherwise the program must
> sit in a loop serving samples. What callbacks are these?)
> Martin
> _______________________________________________
> Pd-list at lists.iem.at mailing list
> UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list

More information about the Pd-list mailing list