9 image-rendering: pixelated;
13 <img src=
"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAAFElEQVQIHWP4z8DwHwyBNJDN8B8AQNEG+t5Ik2kAAAAASUVORK5CYII=">
14 <!-- Test that drawing a pixelated canvas with another pixelated canvas as source works. -->
15 <!-- Both canvases should be upscaled without blurring. -->
16 <canvas class=
"canvas0" width=
"4" height=
"4"></canvas>
17 <canvas class=
"canvas1" width=
"4" height=
"4"></canvas>
20 // Ignore the render tree.
21 if (window
.testRunner
)
22 window
.testRunner
.dumpAsTextWithPixelResults();
24 function drawToCanvas(canvas
) {
25 var ctx
= canvas
.getContext("2d")
26 ctx
.drawImage(document
.getElementsByTagName("img")[0], 1, 1);
30 var canvas0
= document
.getElementsByTagName("canvas")[0];
31 var canvas1
= document
.getElementsByTagName("canvas")[1];
32 drawToCanvas(canvas0
);
33 canvas1
.getContext("2d").drawImage(canvas0
, 0, 0);