forked from gibber-cc/gibberish
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
110 lines (99 loc) · 3.18 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
<html>
<head>
<title>Gibberish</title>
<script src="build/gibberish.js"></script>
<script src="scripts/tests.js"></script>
<style>
pre, h2 {
margin-left: 10px;
}
body {
font-family: "HelveticaNeue-Light", sans-serif;
background:#fff;
}
h1, h2 {
font-weight: normal;
}
a { color:#000;}
</style>
</head>
<body>
<div id="header">
<h1 style="background:#555; color:white">Gibberish Tests</h1>
<a href="docs.html">reference</a> <a href="http://github.com/charlieroberts/Gibberish">github</a>
<p style="width:50%">
Gibberish is an audio engine that creates code optimized for JIT compilation.
Below, after choosing an example, you are shown the input code that the programmer enters and the output code that Gibberish
generates for the JIT compiler. It is the audio backend for the live coding environment <a href="http://gibber.mat.ucsb.edu">Gibber</a>.
Gibberish works with Chrome, Firefox, Safari(desktop) 6+ (use webkit nightly for best results) and Safari(mobile) under iOS 6+.
</p>
<p>All examples assume the following three lines are run first:<br>
<pre>Gibberish.init()
Gibberish.Time.export()
Gibberish.Binops.export()
</pre>
</p>
run: <select onchange="console.log('RUNNING', this.options[this.selectedIndex].text); window[this.options[this.selectedIndex].text]();">
<option>clear</option>
<!-- <option>test</option> -->
<optgroup label="MODULATION">
<option>vibratoTest</option>
<option>twoOscsOneMod</option>
<option>lineTest</option>
<option>ADSRTest</option>
<option>ADSRTest2</option>
</optgroup>
<optgroup label="EFFECTS">
<option>distortion</option>
<option>ladderFilter</option>
<option>stateVariableFilter</option>
<option>biquadFilter</option>
<option>ringModulation</option>
<option>decimator</option>
<option>delay</option>
<option>flanger</option>
<option>vibrato</option>
<option>reverb</option>
<option>bufferShuffler</option>
<option>granulator</option>
</optgroup>
<optgroup label="GENERATORS">
<option>input</option>
<option>wavetable</option>
<option>bandLimitedPWM</option>
<option>synth</option>
<option>polySynth</option>
<option>FMTest</option>
<option>polyFM</option>
<option>karplusStrong</option>
<option>polyKarplusStrong</option>
<option>sampler</option>
<option>soundfont</option>
<option>synth2</option>
<option>monoSynth</option>
<option>tr808_emulation</option>
</optgroup>
<option>time_modulation(Reich)</option>
<option>routingTest</option>
<option>sequencerTest</option>
</select>
</div>
<div style="width:45%; float:left; left:0px; ">
<h2>Input</h2>
<pre style="width:45%; left:0px;" id="input"></pre>
</div>
<div style="width:45%; float:right; ">
<h2>Output</h2>
<pre id="output" style="width:45%;"></pre>
</div>
<script>
///* uncomment this line (restore block comment) to use with LAB.js
Gibberish.init();
codeTimeout = setTimeout(function() {
var codegen = document.getElementById("output");
codegen.innerHTML = Gibberish.callback.toString();
}, 2000);
//*/
</script>
</body>
</html>