-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
executable file
·178 lines (153 loc) · 6.24 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
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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Jokenpo</title>
<link rel="stylesheet" media="all" href="Styles/default.css" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<!-- jquery -->
<script type="text/javascript" src="js/jquery-1.6.2.min.js"></script>
<script type="text/javascript" src="js/dateFormat.js"></script>
<script type="text/javascript" src="js/debugConsole.js"></script>
<link rel="stylesheet" type="text/css" href="css/bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="css/style.css">
<script src="//code.jquery.com/jquery-1.11.2.min.js"></script>
<script src="//code.jquery.com/jquery-migrate-1.2.1.min.js"></script>
<!-- ORTC -->
<script type="text/javascript" src="http://dfdbz2tdq3k01.cloudfront.net/js/2.1.0/ortc.js"></script>
<!--<script src="js/tracking-min.js"></script>
<script src="js/dat-gui/build/dat.gui.min.js"></script>
<script src="js/stats.min.js"></script>
<script src="js/color_camera_gui.js"></script> -->
<script src="js/JSARToolKit.js"></script>
<script src="js/magi.js"></script>
<script src="js/utils.js"></script>
<script>
threshold = 128;
DEBUG = false;
GLOBAL_currId = -1;
var video = document.createElement('video');
video.width = 600;
video.height = 450;
video.loop = true;
video.volume = 0;
video.autoplay = true;
video.style.display = 'none';
video.controls = true;
var getUserMedia = function(t, onsuccess, onerror) {
if (navigator.getUserMedia) {
return navigator.getUserMedia(t, onsuccess, onerror);
} else if (navigator.webkitGetUserMedia) {
return navigator.webkitGetUserMedia(t, onsuccess, onerror);
} else if (navigator.mozGetUserMedia) {
return navigator.mozGetUserMedia(t, onsuccess, onerror);
} else if (navigator.msGetUserMedia) {
return navigator.msGetUserMedia(t, onsuccess, onerror);
} else {
onerror(new Error("No getUserMedia implementation found."));
}
};
var URL = window.URL || window.webkitURL;
var createObjectURL = URL.createObjectURL || webkitURL.createObjectURL;
if (!createObjectURL) {
throw new Error("URL.createObjectURL not found.");
}
getUserMedia({'video': true},
function(stream) {
var url = createObjectURL(stream);
video.src = url;
},
function(error) {
alert("Couldn't access webcam.");
}
);
</script>
<style>
video, canvas {
margin-left: 100px;
margin-top: 35px;
position: absolute;
}
</style>
</head>
<body>
<div class="container tela1 paper">
<div class="row title">
<h1>Escolha sua jogada</h1>
</div>
<div class="row optbox">
<div class="col-xs-4 opt1 pedra"></div>
<div class="col-xs-4 opt2 papel"></div>
<div class="col-xs-4 opt3 tesoura"></div>
</div>
</div>
<div id="Connection1_pnlConnection" class="divPanel">
<div class="divPanelInt">
<table width="100%" cellspacing="8">
<tr>
<td colspan="5">
Message
</td>
</tr>
<tr>
<td colspan="5">
<textarea name="Connection1$txtMessage" rows="3" cols="20" id="Connection1_txtMessage" style="width:99%;"> This is the message.</textarea>
</td>
</tr>
</table>
</div>
<div id="Connection1_UpdatePanel1">
<div style="float:left">
<table>
<tr>
<td style="width:110px">
<input type="Button" Value="Play" class="button" style="width:100px;" onclick="play();" />
</td>
<td style="width:110px">
<input type="Button" Value="Connect" class="button" style="width:100px;" onclick="Connect();" />
</td>
<td style="width:110px">
<input type="Button" Value="Send" class="button" style="width:100px;" onclick="Send(selected);" />
</td>
<td style="width:110px">
<input type="Button" Value="Subscribe" class="button" style="width:100px;" onclick="Subscribe();" />
</td>
</tr>
</table>
</div>
</div>
<div class="demo-frame">
<div id="loading">Carregando...</div>
</div>
</div>
<input type="hidden" name="Logger1$Collapsiblepanelextender1_ClientState" id="Logger1_Collapsiblepanelextender1_ClientState"/>
<div id="Logger1_pHeader" class="collapsiblePanelTitle">
Log
</div>
<div id="Logger1_pnlLogger" class="divPanel">
<div class="divPanelInt">
<table width="100%">
<tr>
<td>
<div id="logger" class="log"></div>
</td>
</tr>
</table>
</div>
<div id="Logger1_UpdatePanel1">
<input type="Button" Value="Clear Log" class="button" style="width:100px;" onclick="ClearLog();" />
</div>
</div>
<script>
</script>
<audio id="notify" src="audio/pop.mp3" preload="auto"></audio>
<audio id="notify2" src="audio/pop2.mp3" preload="auto"></audio>
<audio id="vitoria" src="audio/vitoria.mp3" preload="auto"></audio>
<audio id="derrota" src="audio/fail.mp3" preload="auto"></audio>
<audio id="empate" src="audio/empate.mp3" preload="auto"></audio>
<button onclick="document.getElementById('notify').play()">Reproduzir o áudio</button>
<button onclick="document.getElementById('notify2').play()">Reproduzir o áudio longo</button>
<button onclick="document.getElementById('vitoria').play()">Reproduzir vitória</button>
<button onclick="document.getElementById('derrota').play()">Reproduzir derrota</button>
<button onclick="document.getElementById('empate').play()">Reproduzir empate</button>
</body>
</html>