/
index.html
53 lines (48 loc) · 1.63 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
<!DOCTYPE html>
<html>
<head>
<title>FAUST NOISE</title>
<!-- I am so Meta -->
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="FAUST NOISE">
<meta name="author" content="Myles Borins">
<!-- OpenGraph Meta -->
<meta property="og:title" content="FAUST NOISE"/>
<!-- <meta property="og:url" content=""/> -->
<meta property="og:site_name" content="FAUST NOISE"/>
<!-- <meta property="og:image" content="Some Image"/> -->
<link href="css/custom.css" rel="stylesheet">
</head>
<body>
<div class="center">
<h1>Is it noisy?<h1>
</div>
<script src="bower_components/lodash/dist/lodash.min.js" type="text/javascript" charset="utf-8"></script>
<script src="bower_components/dat-gui/build/dat.gui.min.js" type="text/javascript" charset="utf-8"></script>
<script src="js/faust-noise.js"></script>
<script>
var noise = faust.noise();
noise.update("Volume", 0.1);
noise.play();
window.onload = function () {
var folder, param;
var gui = new dat.GUI();
_(noise.model).forEach(function (obj, key) {
if (key !== 'playing') {
folder = gui.addFolder(key);
if (key === 'Volume') {
param = folder.add(obj, 'value', 0, 1);
}
else {
param = folder.add(obj, 'value');
}
param.onChange(function (value) {
noise.update(key, value);
});
}
});
}
</script>
</body>
</html>