[chuck-users] newbie questions
Philip Davidson
philipd at CS.Princeton.EDU
Thu Jun 22 00:11:15 EDT 2006
Howdy Dan,
Looking at source, i think what's happening is that the Chuck duration (
floating point, in samples) is being implicitly cast to the floating
point argument ( .attackTime is registered as such ) that STK needs, but
ASDR is expecting seconds.
durs can always be converted to the float units your function expects
through division ( t / 1::second ) but we should be performing this
automagically by adding a properly typed function.
func = make_new_mfun( "float", "attackTime", ADSR_ctrl_attackTime
); //! attack time
func->add_arg( "float", "value" );
if( !type_engine_import_mfun( env, func ) ) goto error;
Daniel L Trueman (dtrueman at Princeton.EDU) wrote:
> ok, newbie chucker here, with dumb questions:
>
> 1. is it true that the archives for this list are not searchable? i would be most delighted to avoid asking dumb questions by
> searching the archives first.
>
> 2. confused is me trying to set some STK time parameters. for instance:
>
> //
> noise n => ADSR e => dac;
> 400::ms => dur t => e.attackTime;
> //
>
> doesn't work, which is ok since i know:
>
> //
> .4 => e.attackTime;
> //
>
> does work, but it would make more sense to me to be able to send durs around consistently, especially when i see something
> like this:
>
> //
> noise n => Envelope e => dac;
> std.rand2f(10,500)::ms => dur t => e.duration;
> //
>
> that works. now, things become more mysterious when i find that "duration" is not documented online as part of Envelope,
> which makes me wonder if i'm missing something, and also wonder what other interesting things remain undocumented. is it
> just that some of the STK ugens have been extended to take durs, but not all?
>
> most joyfully attempting to chuck,
> dan
> _______________________________________________
> chuck-users mailing list
> chuck-users at lists.cs.princeton.edu
> https://lists.cs.princeton.edu/mailman/listinfo/chuck-users
More information about the chuck-users
mailing list