forked from unk1911/speech
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathspeech.html
More file actions
112 lines (91 loc) · 3.34 KB
/
Copy pathspeech.html
File metadata and controls
112 lines (91 loc) · 3.34 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
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
111
<html>
<head>
<title>Text-To-Speech Service</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta charset="UTF-8">
<meta name="description" content="Text-To-Speech Synthesis">
<meta name="keywords" content="TTS, text-to-speech, voice, API, speech, synthesis, html5">
<meta name="author" content="Mike Melamed">
<meta name="copyright" content="eDeliverables Inc">
<link rel="stylesheet" href="jquery/jquery.mobile-1.4.5.min.css"/>
<script src="jquery/jquery-1.11.1.min.js"></script>
<script src="jquery/jquery.mobile-1.4.5.min.js"></script>
<script src="js/speech.js?ver=0.1" type="text/javascript"></script>
<script>
var pauseResume = 'R';
$(document).ready(function(){
$("#doClear").click(function() {
$("#taInput").val("");
return false;
});
$("#doPauseResume").click(function() {
doPauseResume();
return false;
});
$("#doStop").click(function() {
doStop();
return false;
});
$("#doTTS").click(function() {
var taInput = $("#taInput").val();
// Chunk it up...
var chunkList = getChunks(taInput);
chunkList.forEach(function(chunk) {
console.log("chunk=[" + chunk + "]");
doSpeak(chunk);
});
return false;
});
});
// Initialize speech engine...
initSpeech();
</script>
</head>
<body>
<div data-role="page">
<div data-role="header">
<h1>Text-To-Speech</h1>
<center>
<input type='button' id='doTTS' value='Speak!'/>
<input type='button' id='doPauseResume' value='Pause/Resume'/>
<input type='button' id='doStop' value='Stop'/>
<input type='button' id='doClear' value='Clear'/>
</center>
</div><!-- /header -->
<div role="main" class="ui-content">
<fieldset>
<legend>Cut & Paste Text To Synthesize</legend>
<textarea class='textareaClass' id='taInput' rows="12" cols="50"></textarea><br/>
</fieldset>
<div id='statusMsg'></div>
<div class="option">
<label for="rate">Voice</label>
<select id='voice' name='voice'>
<!-- <option value='Google US English'>Google US English</option> -->
</select>
</div>
<div class="option">
<label for="rate">Rate</label>
<input type="range" min="0.1" max="10" step="0.1" name="rate" id="rate" value="1">
</div>
<div class="option">
<label for="pitch">Pitch</label>
<input type="range" min="0" max="2" step="0.1" name="pitch" id="pitch" value="1">
</div>
</div><!-- /content -->
<div data-role="footer">
<center>
<a href='http://bitcoin.org' target='_new'>Bitcoin</a>: <b><a href=bitcoin:1KeBs4HBQzkdHC2ou3gpyGHqcL7aKzwTve>1KeBs4HBQzkdHC2ou3gpyGHqcL7aKzwTve</a></b>
<!-- <a class="coinbase-button" data-code="0e29fbd5ca0a4d668d06bf0db74f32cf" data-button-style="custom_small" href="https://www.coinbase.com/checkouts/0e29fbd5ca0a4d668d06bf0db74f32cf">Donate Bitcoins</a><script src="https://www.coinbase.com/assets/button.js" type="text/javascript"></script> -->
<a href='https://github.com/unk1911/speech'><img src='img/GitHub-Mark-64px.png' alt='GitHub Logo'></a>
</center>
</div><!-- /footer -->
</div><!-- /page -->
<script>
setTimeout(function() {
// Initialize the voices...
doInitVoices();
}, 1);
</script>
</body>
</html>