[chuck-users] Timing with ChucK

Stefan Blixt stefan.blixt at gmail.com
Tue Feb 17 16:24:14 EST 2009


Tom's solution is probably the easiest and most effective.

For other reasons, I've been thinking that it would be cool to have some
kind of gate UGen (though it doesn't necessarily output anything) that
triggers events depending on what has been chucked into it. Something like
this:

--------------------------
adc => GateTrigger gate;

0.01 => gate.threshold;
1::ms => gate.release;

gate.event => now;
-----------------------------

Here the gate.event would receive a signal when whatever is coming from adc
goes over 0.01 or below 0.01. You'd need some kind of filter or release so
the thing doesn't go off every time the signal crosses zero.

Maybe a digression...

On Tue, Feb 17, 2009 at 9:43 PM, rkramer <rkramer at gmail.com> wrote:

> Being a relative non-programmer, I'm not quite sure if this is even
> possible...  My goal is a quick and dirty program that will measure the time
> between two large audio events (in the input sound buffer, live recording.)
> Essentially what I want to do is use ChucK for practical demonstrations of
> simple physics...  IE demonstrating average velocity of a falling object
> (that generates a sufficiently loud event when it is released and when it
> hits the floor.)
>
> Any tips where to start on this project?
>
>
> Ryan
>
>
>
>
> _______________________________________________
> chuck-users mailing list
> chuck-users at lists.cs.princeton.edu
> https://lists.cs.princeton.edu/mailman/listinfo/chuck-users
>
>


-- 
Release me, insect, or I will destroy the Cosmos!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cs.princeton.edu/pipermail/chuck-users/attachments/20090217/afefd1ca/attachment.htm>


More information about the chuck-users mailing list