Removing manual test pages because they have been moved to github.
BUG=https://github.com/GoogleChrome/webrtc/issues/203 R=kjellander@webrtc.org Review URL: https://webrtc-codereview.appspot.com/35499004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@7881 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
40b276ea7b
commit
f68faa542a
@ -1,8 +0,0 @@
|
||||
================================================================
|
||||
WEBRTC MANUAL TESTS
|
||||
================================================================
|
||||
|
||||
You will need to serve these files off some kind of web server. Currently,
|
||||
GetUserMedia does not work when run off a file:// URL.
|
||||
|
||||
Contact person: phoglund@webrtc.org
|
||||
@ -1,51 +0,0 @@
|
||||
var RTCPeerConnection = null;
|
||||
var getUserMedia = null;
|
||||
var attachMediaStream = null;
|
||||
|
||||
if (navigator.mozGetUserMedia) {
|
||||
console.log("This appears to be Firefox");
|
||||
|
||||
// The RTCPeerConnection object.
|
||||
RTCPeerConnection = mozRTCPeerConnection;
|
||||
|
||||
// Get UserMedia (only difference is the prefix).
|
||||
// Code from Adam Barth.
|
||||
getUserMedia = navigator.mozGetUserMedia.bind(navigator);
|
||||
|
||||
// Attach a media stream to an element.
|
||||
attachMediaStream = function(element, stream) {
|
||||
console.log("Attaching media stream");
|
||||
element.mozSrcObject = stream;
|
||||
element.play();
|
||||
};
|
||||
} else if (navigator.webkitGetUserMedia) {
|
||||
console.log("This appears to be Chrome");
|
||||
|
||||
// The RTCPeerConnection object.
|
||||
RTCPeerConnection = webkitRTCPeerConnection;
|
||||
|
||||
// Get UserMedia (only difference is the prefix).
|
||||
// Code from Adam Barth.
|
||||
getUserMedia = navigator.webkitGetUserMedia.bind(navigator);
|
||||
|
||||
// Attach a media stream to an element.
|
||||
attachMediaStream = function(element, stream) {
|
||||
element.src = webkitURL.createObjectURL(stream);
|
||||
};
|
||||
|
||||
// The representation of tracks in a stream is changed in M26.
|
||||
// Unify them for earlier Chrome versions in the coexisting period.
|
||||
if (!webkitMediaStream.prototype.getVideoTracks) {
|
||||
webkitMediaStream.prototype.getVideoTracks = function() {
|
||||
return this.videoTracks;
|
||||
}
|
||||
}
|
||||
|
||||
if (!webkitMediaStream.prototype.getAudioTracks) {
|
||||
webkitMediaStream.prototype.getAudioTracks = function() {
|
||||
return this.audioTracks;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
console.log("Browser does not appear to be WebRTC-capable");
|
||||
}
|
||||
@ -1,47 +0,0 @@
|
||||
<!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>Single Local Preview (Video and Audio)</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 requestVideoAndAudio() {
|
||||
// Call into getUserMedia via the polyfill (adapter.js).
|
||||
getUserMedia({video: true, audio: true},
|
||||
getUserMediaOkCallback,
|
||||
getUserMediaFailedCallback);
|
||||
}
|
||||
|
||||
function getUserMediaFailedCallback(error) {
|
||||
alert("User media request denied with error code " + error.code);
|
||||
}
|
||||
|
||||
function getUserMediaOkCallback(stream) {
|
||||
attachMediaStream(document.getElementById("view1"), stream);
|
||||
attachMediaStream(document.getElementById("audio1"), stream);
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="requestVideoAndAudio();">
|
||||
<table border="0">
|
||||
<tr>
|
||||
<td>Local Preview</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><video width="320" height="240" id="view1"
|
||||
autoplay="autoplay"></video></td>
|
||||
<td><audio id="audio1" autoplay="autoplay"></audio></td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
@ -1,20 +0,0 @@
|
||||
<!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>AppRTC web app in an IFRAME</title>
|
||||
<meta http-equiv="X-UA-Compatible" content="chrome=1"/>
|
||||
</head>
|
||||
<body>
|
||||
AppRTC in an <iframe> element:<br>
|
||||
<iframe width="90%" height="90%" src="http://apprtc.appspot.com"></iframe>
|
||||
</body>
|
||||
</html>
|
||||
@ -1,19 +0,0 @@
|
||||
<!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>IFRAME Single Local Preview (Video Only)</title>
|
||||
<meta http-equiv="X-UA-Compatible" content="chrome=1"/>
|
||||
</head>
|
||||
<body>
|
||||
<iframe width="100%" height="100%" src="single-video.html"></iframe>
|
||||
</body>
|
||||
</html>
|
||||
@ -1,56 +0,0 @@
|
||||
<!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>
|
||||
@ -1,72 +0,0 @@
|
||||
<!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 (Video 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 requestVideo() {
|
||||
// Call into getUserMedia via the polyfill (adapter.js).
|
||||
getUserMedia({video: true, audio: false},
|
||||
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("view" + i), stream);
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="requestVideo();">
|
||||
<table border="0">
|
||||
<tr>
|
||||
<td>Local Preview</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><video width="320" height="240" id="view1"
|
||||
autoplay="autoplay"></video></td>
|
||||
<td><video width="320" height="240" id="view2"
|
||||
autoplay="autoplay"></video></td>
|
||||
<td><video width="320" height="240" id="view3"
|
||||
autoplay="autoplay"></video></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><video width="320" height="240" id="view4"
|
||||
autoplay="autoplay"></video></td>
|
||||
<td><video width="320" height="240" id="view5"
|
||||
autoplay="autoplay"></video></td>
|
||||
<td><video width="320" height="240" id="view6"
|
||||
autoplay="autoplay"></video></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><video width="320" height="240" id="view7"
|
||||
autoplay="autoplay"></video></td>
|
||||
<td><video width="320" height="240" id="view8"
|
||||
autoplay="autoplay"></video></td>
|
||||
<td><video width="320" height="240" id="view9"
|
||||
autoplay="autoplay"></video></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><video width="320" height="240" id="view10"
|
||||
autoplay="autoplay"></video></td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
@ -1,44 +0,0 @@
|
||||
<!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>Single 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() {
|
||||
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.
|
||||
attachMediaStream(document.getElementById("audio1"), stream);
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="requestAudio();">
|
||||
<table border="0">
|
||||
<tr>
|
||||
<td>Sound test</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><audio id="audio1" autoplay="autoplay"></audio></td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
@ -1,45 +0,0 @@
|
||||
<!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>Single Local Preview (Video 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 requestVideo() {
|
||||
getUserMedia({video: true, audio: false},
|
||||
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.
|
||||
attachMediaStream(document.getElementById("view1"), stream);
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="requestVideo();">
|
||||
<table border="0">
|
||||
<tr>
|
||||
<td>Local Preview</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><video width="320" height="240" id="view1"
|
||||
autoplay="autoplay"></video></td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
@ -1,51 +0,0 @@
|
||||
<!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>Single Local Preview (Video 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 requestVideo(target) {
|
||||
// Call into getUserMedia via the polyfill (adapter.js).
|
||||
getUserMedia({video: true, audio: false},
|
||||
function(stream) {
|
||||
getUserMediaOkCallback(stream, target);
|
||||
},
|
||||
getUserMediaFailedCallback);
|
||||
}
|
||||
|
||||
function getUserMediaFailedCallback(error) {
|
||||
alert("User media request denied with error code " + error.code);
|
||||
}
|
||||
|
||||
function getUserMediaOkCallback(stream, target) {
|
||||
// Call the polyfill wrapper to attach the media stream to this element.
|
||||
attachMediaStream(document.getElementById("view1"), stream);
|
||||
attachMediaStream(document.getElementById("view2"), stream);
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="requestVideo('view1'); requestVideo('view2');">
|
||||
<table border="0">
|
||||
<tr>
|
||||
<td>Local Preview</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><video width="320" height="240" id="view1"
|
||||
autoplay="autoplay"></video></td>
|
||||
<td><video width="320" height="240" id="view2"
|
||||
autoplay="autoplay"></video></td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
Loading…
x
Reference in New Issue
Block a user