blob: 80e4b646c6c61357ec623f86b5673afd63039ec5 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<!--
Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
Use of this source code is governed by a BSD-style license
that can be found in the LICENSE file in the root of the source
tree. An additional intellectual property rights grant can be found
in the file PATENTS. All contributing project authors may
be found in the AUTHORS file in the root of the source tree.
-->
<html>
<head>
<title>Multiple Local Preview (Audio Only)</title>
<meta http-equiv="X-UA-Compatible" content="chrome=1"/>
<!-- Load the polyfill to switch-hit between Chrome and Firefox -->
<script src="adapter.js"> </script>
<script type="text/javascript">
function requestAudio() {
// Call into getUserMedia via the polyfill (adapter.js).
getUserMedia({video: false, audio: true},
getUserMediaOkCallback,
getUserMediaFailedCallback);
}
function getUserMediaFailedCallback(error) {
alert("User media request denied with error code " + error.code);
}
function getUserMediaOkCallback(stream) {
// Call the polyfill wrapper to attach the media stream to this element.
for (var i = 1; i <= 10; i++) {
attachMediaStream(document.getElementById("audio" + i), stream);
}
}
</script>
</head>
<body onload="requestAudio();">
<table border="0">
<tr>
<td>Sound test</td>
</tr>
<tr>
<td><audio id="audio1" autoplay="autoplay"></audio></td>
<td><audio id="audio2" autoplay="autoplay"></audio></td>
<td><audio id="audio3" autoplay="autoplay"></audio></td>
<td><audio id="audio4" autoplay="autoplay"></audio></td>
<td><audio id="audio5" autoplay="autoplay"></audio></td>
<td><audio id="audio6" autoplay="autoplay"></audio></td>
<td><audio id="audio7" autoplay="autoplay"></audio></td>
<td><audio id="audio8" autoplay="autoplay"></audio></td>
<td><audio id="audio9" autoplay="autoplay"></audio></td>
<td><audio id="audio10" autoplay="autoplay"></audio></td>
</tr>
</table>
</body>
</html>