<div dir="ltr">Great, thanks for the help. I'm looking forward to learning how PD does it. I'm sure I'll have questions for the dev list as I go!<div><br></div><div>iain</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Oct 23, 2020 at 5:05 PM Miller Puckette <<a href="mailto:msp@ucsd.edu">msp@ucsd.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">It's all done via clock_new(), clock_delay(), clock_getlogicaltime(),<br>
clock_gettimesince(), clock_gettimesincewithunits() and clock_free()<br>
calls - examples in the delay and timer objects, in x_time.c.<br>
<br>
When it's real time, stupider is better :)<br>
<br>
cheers<br>
Miller<br>
<br>
On Fri, Oct 23, 2020 at 04:58:09PM -0700, Iain Duncan wrote:<br>
> Oh sweeeet.  Yeah so far it's looking like this will be pretty<br>
> straightforward in comparison. :-)<br>
> <br>
> Can anyone point me at docs or resources on that part of PD? Or do I just<br>
> need to go to the code? I've read through the git repo on learning to write<br>
> an external but didn't see much on how to interact with the scheduler. (the<br>
> stuff that in max uses the clocks and time objects and so on)<br>
> <br>
> Thanks for the feedback everyone! I'm excited to make it happen.<br>
> <br>
> On Fri, Oct 23, 2020 at 4:44 PM Miller Puckette <<a href="mailto:msp@ucsd.edu" target="_blank">msp@ucsd.edu</a>> wrote:<br>
> <br>
> > Pd's a single thread - you'll have a much easier time adding stuff to<br>
> > Pd than to Max :)<br>
> ><br>
> > Miller<br>
> ><br>
> > On Fri, Oct 23, 2020 at 12:35:02PM -0700, Iain Duncan wrote:<br>
> > > Hi Andy, well I've ordered your book to learn PD, so I'm at least that<br>
> > > committed! :-)  My overarching goal is to make tools for composing,<br>
> > > improvising, and sequencing, so at this point, I'm punting on signals.<br>
> > > First I want to support everything in Rick Taubes's Notes From the<br>
> > > Metalevel book, along with a bunch of my own ideas, for algorithmic and<br>
> > > computer assisted composition/improvisation. But I am hoping to get<br>
> > signals<br>
> > > into play eventually. Which makes this a good time for a question...<br>
> > ><br>
> > > In Max, my understanding is that if Overdrive is on and Scheduler in<br>
> > > Interrupt is selected,  we actually get only two threads: low priority<br>
> > > thread running who knows when, and high priority thread alternating<br>
> > between<br>
> > > a pass of eating up the scheduler queue (up to the limit) and then a pass<br>
> > > of the audio vector render. So given that I'm forcing all messages to run<br>
> > > in the high priority thread (unless the user asks for danger-mode Any), I<br>
> > > *think* I should have no problem calling into S7 and sharing data from<br>
> > both<br>
> > > dsp perform routines and regular event scheduled messages. I have not,<br>
> > > however, actually done this yet. Can anyone tell me what the situation in<br>
> > > PD is there? Or point me at good docs/resources on how the threading and<br>
> > > scheduling works in PD?<br>
> > ><br>
> > > Thanks<br>
> > > iain<br>
> > ><br>
> > ><br>
> > > On Fri, Oct 23, 2020 at 12:23 PM Andy Farnell <<br>
> > <a href="mailto:padawan12@obiwannabe.co.uk" target="_blank">padawan12@obiwannabe.co.uk</a>><br>
> > > wrote:<br>
> > ><br>
> > > > My last love affair with parentheses was in Racket.<br>
> > > > Although my only ever somewhat successful musical adventures<br>
> > > > in this style were with Roger Dannenberg's CLM/Nyquist<br>
> > > ><br>
> > > > Lets see what happens if Iain brings S7 over.<br>
> > > ><br>
> > > > Iain, how are you thinking of handling signals<br>
> > > >  (or not)?<br>
> > > ><br>
> > > > andy<br>
> > > ><br>
> > > > On Fri, Oct 23, 2020 at 11:31:48AM +0200, Kjetil Matheussen wrote:<br>
> > > > > On Thu, Oct 22, 2020 at 10:26 AM Andy Farnell<br>
> > > > > <<a href="mailto:padawan12@obiwannabe.co.uk" target="_blank">padawan12@obiwannabe.co.uk</a>> wrote:<br>
> > > > > ><br>
> > > > > > Would love to see Scheme come to Pd.<br>
> > > > > ><br>
> > > > > There's also k_guile from 2004, that still compiles:<br>
> > > > ><br>
> > <a href="https://urldefense.com/v3/__https://github.com/kmatheussen/k_guile__;!!Mih3wA!R6td8jy_IlJ5bOCoY02BZdcXbj7A38N3Ca1EA4vlqYbpelSmHtr_uAjQ6hgi$" rel="noreferrer" target="_blank">https://urldefense.com/v3/__https://github.com/kmatheussen/k_guile__;!!Mih3wA!R6td8jy_IlJ5bOCoY02BZdcXbj7A38N3Ca1EA4vlqYbpelSmHtr_uAjQ6hgi$</a><br>
> > > > > Don't know if it still works though.<br>
> > > > ><br>
> > > > > Guess there are other alternatives as well, but they all probably<br>
> > > > > suffer a bit from gc non-rt performance. To fix this I later extended<br>
> > > > > the code from k_guile to run in a separate thread to avoid cpu<br>
> > spikes,<br>
> > > > > but this code was only added to the snd sound editor (when snd was<br>
> > > > > compiled as a pd external), and that code was probably removed from<br>
> > > > > snd when switching from guile to s7.<br>
> > > > _______________________________________________<br>
> > > > <a href="mailto:Pd-list@lists.iem.at" target="_blank">Pd-list@lists.iem.at</a> mailing list<br>
> > > > UNSUBSCRIBE and account-management -><br>
> > > ><br>
> > <a href="https://urldefense.com/v3/__https://lists.puredata.info/listinfo/pd-list__;!!Mih3wA!R6td8jy_IlJ5bOCoY02BZdcXbj7A38N3Ca1EA4vlqYbpelSmHtr_uP-Uh4ph$" rel="noreferrer" target="_blank">https://urldefense.com/v3/__https://lists.puredata.info/listinfo/pd-list__;!!Mih3wA!R6td8jy_IlJ5bOCoY02BZdcXbj7A38N3Ca1EA4vlqYbpelSmHtr_uP-Uh4ph$</a><br>
> > > ><br>
> ><br>
> > > _______________________________________________<br>
> > > <a href="mailto:Pd-list@lists.iem.at" target="_blank">Pd-list@lists.iem.at</a> mailing list<br>
> > > UNSUBSCRIBE and account-management -><br>
> > <a href="https://urldefense.com/v3/__https://lists.puredata.info/listinfo/pd-list__;!!Mih3wA!R6td8jy_IlJ5bOCoY02BZdcXbj7A38N3Ca1EA4vlqYbpelSmHtr_uP-Uh4ph$" rel="noreferrer" target="_blank">https://urldefense.com/v3/__https://lists.puredata.info/listinfo/pd-list__;!!Mih3wA!R6td8jy_IlJ5bOCoY02BZdcXbj7A38N3Ca1EA4vlqYbpelSmHtr_uP-Uh4ph$</a><br>
> ><br>
> ><br>
</blockquote></div>