4 <script src=
"media-file.js"></script>
7 if (window
.testRunner
) {
8 testRunner
.waitUntilDone();
13 function onVideoLoaded(e
) {
14 videosLoaded
= videosLoaded
+ 1;
15 if (window
.testRunner
&& videosLoaded
== 3) {
16 testRunner
.notifyDone();
21 var video1
= document
.getElementById('video1');
22 var video2
= document
.getElementById('video2');
23 var video3
= document
.getElementById('video3');
24 video1
.src
= findMediaFile("video", "content/test");
25 video2
.src
= video1
.src
;
26 video3
.src
= video1
.src
;
31 video1
.addEventListener("canplay", onVideoLoaded
);
32 video2
.addEventListener("canplay", onVideoLoaded
);
33 video3
.addEventListener("canplay", onVideoLoaded
);
38 <body onload=
"onLoad();">
39 Test to verify that drawing a video to a
2D canvas with drawImage and with a CanvasPattern works as expected.
40 <video id=
"video1"></video>
41 <video id=
"video2"></video>
42 <video id=
"video3"></video>