-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
53 lines (51 loc) · 2.37 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>twit.tone</title>
<link href="main.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="twit-tone.js"></script>
<script type="text/javascript" src="atom/atom.js"></script>
<script type="text/javascript">
function listen() {
twitTone(document.getElementById('feed').value, 'countChars', function(){beep(this);}, 'time_limit:-'+document.getElementById('time').value)
}
function beep(val) {
var beeps=val.toString().split(",");
for (var i=0;i<beeps.length;i++)
{
beepStack.push(beeps[i])
}
}
function auto(mode) {
if (document.getElementById("auto").checked==true) {
listen();
var auto=setInterval(function(){listen()}, 5000);
}
else {
history.go(0)
}}
</script>
</head>
<body onload="load();begin()">
<div id="header">
<div id="header-inner">
<h1>twit.tone</h1>
<p>The twit.tone project was started on Monday the 6th of August 2012 by Simon Barnes and Sam Wray as part of YRS.</p>
<p>Currently only working in WebKit browsers, the premise of twit.tone is to enable the user to search for a one or more hashtags on Twitter, return results to create representational data, then generate a piece of audio from the result. To achieve a more 'flowing' piece, the user can enable a 'real-time' mode for constant changing audio on trending hashtags.<br>Limitations: can only get the last 100 tweets</p>
</div>
</div>
<div id="container">
<div class="inner-container">
<label>Tone Duration</label><input type="text" id="duration" value="200" size="4"><br>
<label>In the past:</label><input type="text" id="time" value="5 minutes"><br><br>
<label>Hashtag(s)</label><input type="text" id="feed">
<input type="button" value="Listen!" onclick="listen();">
<br><label>auto mode:<input type="radio" name="auto" onclick="auto('on');" id="auto">ON <input type="radio" name="auto" checked="true" onclick="auto('off')">OFF
<img src="http://logd.tw.rpi.edu/files/loading.gif" style="display:none; height:32px; width:32px; margin-left: auto; margin-right: auto;" id="loading" />
<br><br>
<label id="hz" for="freq">Hz</label>
</div>
</div>
<div id="faubody"></div>
</body>
</html>