Extracted from the resources page at dirtywave.com.
- [DIRECTION] Move the cursor on the screen.
- [SHIFT]+[DIRECTION] Navigate between Views
- [EDIT] Start editing a value; also functions as a “YES” or “ENTER”
Extracted from the resources page at dirtywave.com.
| // stereo to mid-side | |
| M = (L + R) / 2 | |
| S = (L - R) / 2 | |
| // mid-side to stereo | |
| L = (M + S) | |
| R = (M - S) |
| // phase in range 0 <= phase < 1 | |
| // pwm in range -1 <= pwm <= 1 | |
| dt = frequency / samplerate | |
| saw(phase, dt) { | |
| return phase * 2 - 1 - polyBlep(phase, dt) | |
| } | |
| pulse(phase, dt, pwm = 0) { |
| Feedback Delay Network for Reverb | |
| A = (a + b) + (c + d) + L | |
| B = (a - b) + (c - d) + R | |
| C = (a + b) - (c + d) | |
| D = (a - b) - (c - d) | |
| Max feedback should be 0.5 at the very most to avoid nastiness. | |
| Each delay line should have a delay time that is not correlated to any other delay line's time. |
| sqrt(2) / 2 = 0.7071067811865476 | |
| p in range of -PI/2 to PI/2, or -0.125 to 0.125 when normalized | |
| A = (sqrt(2) / 2) * (cos(p) - sin(p)) | |
| B = (sqrt(2) / 2) * (cos(p) + sin(p)) |
| phasor -> variable angle unipolar triangle function -> * 0.5 -> cosine lookup | |
| adjust the angle on the triangle to morph between sine and pseudo-saw | |
| can offset saw phase and subtract to get a psuedo-square (as per ususal) | |
| triangle function: | |
| angle range 0 to 1 with 0.5 being symetrical | |
| if (phase <= angle) phase / angle | |
| if (phase > angle) phase - 1 / angle -1 | |
| by scaling by 0.5 we get the first half of the cosine, and then that same first half but in reverse (which is == to the 2nd half) |
| (((stepNumber + offset) * numberOfHits) % cycleLength) < numberOfHits | |
| true for hits, false for rests |
| 24TET CENTS RATIO DEC | |
| ------------------------------- | |
| 0.0 0 1/1 1.0 | |
| 0.5 0.5327 33/32 1.03125 | |
| 1.0 1.0496 17/16 1.0625 | |
| 1.5 1.5514 35/32 1.09375 |