-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhost.html
More file actions
66 lines (62 loc) · 2.63 KB
/
host.html
File metadata and controls
66 lines (62 loc) · 2.63 KB
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
<!DOCTYPE HTML>
<html lang="en"
xml:lang="en" xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Simple SoundFont Synth Host</title>
<link href="styleSheet.css" media="all" rel="stylesheet" type="text/css" />
<!-- Javascript files are included at the end of the body element -->
</head>
<body>
<div id="cursorControlDiv" style="cursor:wait">
<div id="appDiv" class="app">
<table style="width:400px">
<tr>
<td><span class="boldTitle">Simple SoundFont Synth Host</span></td>
<td style="text-align:right"><input class="smallButton" type="button" value="GitHub" onclick="WebMIDI.host.gitHubButtonClick()" /></td>
</tr>
</table>
<hr />
<div id="waitingForFontDiv" style="display:block">
<span>
Please wait while the grand piano font loads...<br />
(Subsequent loads will be faster, because the browser caches the file.)
</span>
</div>
<div id="fontLoadedDiv" style="display:none">
<span>
This is a simple demo, showing how the sf2synth1 synthesizer from my
<a href="https://github.com/notator/WebMIDISynthHost" target="_blank">WebMIDISynthHost</a>
project can be used in a Web application.
</span>
<hr />
<span>
To use this demo, hover your mouse over the coloured areas below.<br />
Moving the mouse over an area sends the synth a noteOn message.<br />
Moving it out again sends the corresponding noteOff.<br />
</span>
<table style="width:400px">
<tr onmouseover="WebMIDI.host.doMouseOver(event)" onmouseout="WebMIDI.host.doMouseOut(event)">
<td class="panel" id="64" style="background-color:red;" />
<td class="panel" id="66" style="background-color:orange;" />
<td class="panel" id="68" style="background-color:yellow;" />
<td class="panel" id="70" style="background-color:green" />
<td class="panel" id="72" style="background-color:blue;" />
<td class="panel" id="74" style="background-color:blueviolet;" />
<td class="panel" id="76" style="background-color:violet;" />
<td class="panel" id="78" style="background-color:tomato;" />
</tr>
</table>
</div>
</div>
</div>
<script src="WebMIDI/namespace.js" type="text/javascript"></script>
<script src="WebMIDI/constants.js" type="text/javascript"></script>
<script src="WebMIDI/utilities.js" type="text/javascript"></script>
<script src="sf2Synth1/riffParser.js"></script>
<script src="sf2Synth1/soundFontParser.js"></script>
<script src="sf2Synth1/soundFont.js"></script>
<script src="sf2Synth1/soundFontSynthNote.js"></script>
<script src="sf2Synth1/sf2Synth1.js"></script>
<script src="host.js" type="text/javascript"></script>
</body>
</html>