Skip to content

Instantly share code, notes, and snippets.

@shimpe
Last active March 8, 2019 23:24
Show Gist options
  • Save shimpe/04a011f5f4591f044bb5673b021dd6b5 to your computer and use it in GitHub Desktop.
Save shimpe/04a011f5f4591f044bb5673b021dd6b5 to your computer and use it in GitHub Desktop.
8 bit music
(
s.waitForBoot({
Ndef(\bits, {
var t = PulseCount.ar(Impulse.ar(8e3));
var sig = HPF.ar(
(
((t * 15) & (t >> 5)) |
((t * 5) & (t >> [3, 4])) |
((t * 2) & (t >> 9)) |
((t * 8) & (t >> 11)) |
(((t*t) & t) | (t >> 3))
- 3 % 256
) / 127-1 * 3
, 20
) * 0.1;
sig = Greyhole.ar(sig, sig, 0.5, sig);
}).play;
});
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment