-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
26 lines (23 loc) · 975 Bytes
/
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
<?DOCTYPE html>
<html lang="en">
<head>
<title>Chromecast Test</title>
<link href="//netdna.bootstrapcdn.com/bootstrap/3.0.0-rc1/css/bootstrap.min.css" rel="stylesheet">
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.0-rc1/js/bootstrap.min.js"></script>
<script src="https://www.gstatic.com/cast/js/receiver/1.0/cast_receiver.js"></script>
<script type="text/javascript">
var receiver = new cast.receiver.Receiver('ae241d56-0944-42ed-b6eb-06c314f5b5a0', [ 'ca.spacek.chromecase.test.aardvark' ], '', 5);
var remoteMedia = new cast.receiver.RemoteMedia();
remoteMedia.addChannelFactory(receiver.createChannelFactory(cast.receiver.RemoteMedia.NAMESPACE));
receiver.start();
window.addEventListener('load', function() {
var elem = document.getElementById('vid');
remoteMedia.setMediaElement(elem);
});
</script>
</head>
<body>
<h1>Test!</h1>
</body>
</html>