2008/4/28 Atte André Jensen <div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Ok, so to put in a language that I understand, are you saying I should replace my 1::samp =&gt; now with me.yield()?<div>
<div></div><div class="Wj3C7c"><br>
</div></div></blockquote><div><br>Yes, I think so.<br><br>Advancing time, which is what you are doing, gives other shreds a chance to run but it also means this shred will only get the cpu back in a while.<br><br>The difference is likely academic but if OSC messages would be flooding in faster then you are advancing time the cue would pile up and latency (or worse) would follow.<br>
</div></div><br>The core concept here is that &quot;samp =&gt; now&quot; does two things;<br>a) hand the cpu to other shreds<br>b) make the next bit of code execute in a while (likely a 44K&#39;th of a second here)<br><br>
me.yield() only does the first of the two and not the second.<br><br>The issue is that while it may look like ChucK is aimed towards parallel-processing it&#39;s in fact very much focussed on making multiple processes take turns sequentially. What we are dealing with here is (amongst other issues) this exact sequence.<br>
<br>Hope that helps,<br>Kas.<br>