1 //sin = ffunction(float sin(float), <math.h>, "");
2 //floor = ffunction(float floor(float), <math.h>, "");
9 sinwavform = time * (2 * PI)/tablesize : sin;
11 decimal = _ <: -(floor);
12 phase(freq) = freq / samplingfreq : mem : ( + : decimal) ~ _ : * (tablesize) : int;
13 osc(freq) = phase(freq) : rdtable(tablesize, sinwavform);
18 process = osc(freq) * vol;
19 //process = freq / samplingfreq : @(1): ( + : decimal) ~ _ : * (tablesize) : int ;