This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- LCG based on https://github.com/monome/dsp-kit/blob/main/noise/lcg.c by @catfact | |
-- due to differences in data types, the behavior is not the same. | |
-- int32_t values were truncated to avoid Lua converting them to inf or -inf. | |
output[1].action = loop { | |
to( | |
dyn{x=1} | |
:mul(dyn{a=-559}) | |
:step(dyn{c=21032}) | |
:wrap(-32768, 32767) | |
/ 32768 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- an imaginary verbose REPL | |
-- ------------------ | |
-- inspired by the ii help in crow/druid | |
-- most examples based on https://gist.github.com/trentgill/84ec5b68816eb03508566addb5a41dd4 | |
s = sequins | |
-- comments below are hypothetical log output (via e.g. print() or a REPL) | |
cs = s"abcd" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// each channel has its own trigger stream | |
// which is a slow Impulse and a faster CombN | |
// delay threshold is a regular trigger for an envelope | |
// the source is controlled by a Select (many:1) | |
// binary math takes triggers on several control channels | |
// and outputs the index of which channel was last triggered | |
(Ndef(\spaghettiArp, {|root=45, triggerThreshold=0.08, brightness=1.5, atk=0, dec=2.5| |
OlderNewer