-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
47 lines (46 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
<!DOCTYPE html>
<head lang="en-IE">
<meta charset="utf-8">
<title>Sharon stuff</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="css/style.css" rel="stylesheet" media="all">
<script src="https://cdn.jsdelivr.net/npm/@tensorflow/tfjs"></script>
<script src="https://cdn.jsdelivr.net/npm/@tensorflow-models/speech-commands"></script>
</head>
<body>
<main role="main">
<!-- <h1><abbr title="HyperText Markup Language 5">HTML5</abbr> Video Voice Control with the Web Speech <abbr title="Application Programming Interface">API</abbr></h1> -->
<div class="msg" data-state="hidden">This browser doesn't support the WebKit Web Speech <abbr title="Application Programming Interface">API</abbr>. You need the latest version of Chrome. Sorry!</div>
<video id="v" controls preload="metadata">
<source src="video/big-buck-bunny.mp4" type="video/mp4">
</video><br />
<video id="sec-video" style="display: none;" controls preload="metadata">
<source src="video/big-buck-bunny2.mp4" type="video/mp4">
</video>
<div class="rec-status">Recogniser status:<span id="recStatus">not recognising</span></div>
<button id="startRecBtn">Start Recognition</button>
<button id="stopRecBtn">Stop Recognition</button>
<p>Click "Start Recognition", give microphone access permission and start controlling the video's playback, mute and volume control via speech.<br>Available commands are:</p>
<ul>
<li id="vidPlay">" play"</li>
<li id="vidPlayNext">" play Next"</li>
<li id="vidStop">" stop"</li>
<li id="vidStopNext">" stop Next"</li>
<li id="vidNext">" Next"</li>
<li id="vidReplay">" replay"</li>
<li id="vidVolOn">" volume on"</li>
<li id="vidVolOnNext">"vvolume on Next"</li>
<li id="vidVolOff">" volume off"</li>
<li id="vidVolOffNext">" volume off Next"</li>
<li id="vidVolInc">" volume increase"</li>
<li id="vidVolIncNext">" volume increase Next"</li>
<li id="vidVolDec">" volume decrease "</li>
<li id="vidVolDecNext">" volume decrease Next"</li>
</ul>
</main>
<script src="js/video-speech.js" defer></script>
<script>
var _gaq=[['_setAccount','UA-2046650-1'],['_trackPageview']];(function(a,b){var c=a.createElement(b),d=a.getElementsByTagName(b)[0];c.src=("https:"==location.protocol?"//ssl":"//www")+".google-analytics.com/ga.js";d.parentNode.insertBefore(c,d)})(document,"script");
</script>
</body>
</html>