3 <script type=
"text/javascript" src=
"webrtc_test_utilities.js"></script>
4 <script type=
"text/javascript">
6 return document
.getElementById(id
);
9 function getUserMediaAndReturnVideoDimensions(constraints
) {
10 navigator
.webkitGetUserMedia(
11 constraints
, gotStreamCallback
, failedCallback
);
14 function failedCallback(error
) {
15 failTest('GetUserMedia call failed with code ' + error
.code
);
18 function gotStreamCallback(stream
) {
19 var localView
= $('local-view');
20 localView
.src
= URL
.createObjectURL(stream
);
21 detectVideoPlaying('local-view', function() {
22 sendValueToTest(localView
.videoWidth
+ 'x' + localView
.videoHeight
);
30 <td><video id=
"local-view" autoplay=
"autoplay">
32 <td><canvas id=
"local-view-canvas" style=
"display:none"></canvas></td>