Skip to content

Instantly share code, notes, and snippets.

View chriskiefer's full-sized avatar

Chris Kiefer chriskiefer

View GitHub Profile
@chriskiefer
chriskiefer / example.html
Created January 27, 2021 18:44
maximilian FFT example
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>
Javascript Audio Processing
</title>
<script src="https://cdn.jsdelivr.net/gh/google/code-prettify@master/loader/run_prettify.js?autoload=true&amp;skin=sunburst&amp;lang=css" defer="defer"></script>
<!-- show all line numbers-->
<style type="text/css">
@chriskiefer
chriskiefer / godti.lang
Last active March 29, 2022 16:34
removing sources of ambiguity
# GRAMMAR FOR GODTI LANGUAGE
# (Godti? it's from Transmetropolitan)
# Lexer [or tokenizer] definition with language lexemes [or tokens]
# number: /([0-9]+\.?[0-9]*)|(\.[0-9]+)/, (//doen't work)
@{%
[[t >> 9] & 50] * t >> [c>>2] << 24-> seq1;
[[t >> 8] & 39] * t >> [c>>8] << 22 -> seq2;
seq1 + seq2
; divide a bar into 13 beats and play seven of them, evenly(ish) spaced
(d1 (euclid bar 13 7))
; an even 4-4 beat
(d2 (euclid bar 16 4))