Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(179)

Unified Diff: content/test/data/gpu/pixel_canvas2d_webgl.html

Issue 1804243002: Re-enable IOSurface Canvas2D. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Compile errors from rebase, still... Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/blink/web_external_texture_layer_impl.cc ('k') | content/test/data/gpu/pixel_webgl.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/test/data/gpu/pixel_canvas2d_webgl.html
diff --git a/content/test/data/gpu/pixel_canvas2d_accelerated.html b/content/test/data/gpu/pixel_canvas2d_webgl.html
similarity index 69%
copy from content/test/data/gpu/pixel_canvas2d_accelerated.html
copy to content/test/data/gpu/pixel_canvas2d_webgl.html
index 700179c70653036bc4bfec8d72ef11228c09497d..2eea10aa5d69b1278229355a499f285fe7b0b9e6 100644
--- a/content/test/data/gpu/pixel_canvas2d_accelerated.html
+++ b/content/test/data/gpu/pixel_canvas2d_webgl.html
@@ -8,14 +8,18 @@ that the baseline images are regenerated on the next run.
<html>
<head>
-<title>Accelerated Canvas 2D Test: Red Box over Black Background</title>
+<title>Accelerated Retina Canvas 2D and WebGL Test: Red Box and Green Triangle over Black Background</title>
<style type="text/css">
.nomargin {
margin: 0px auto;
}
</style>
+
+<script src="pixel_webgl_util.js"></script>
+
<script>
var g_swapsBeforeAck = 15;
+var gl;
function main()
{
@@ -26,10 +30,18 @@ function main()
function draw()
{
var canvas = document.getElementById("c");
+ canvas.style.width = canvas.style.height = "150px";
var c2d = canvas.getContext("2d");
c2d.clearRect(0, 0, canvas.width, canvas.height);
c2d.fillStyle = "rgba(255, 0, 0, 0.5)";
c2d.fillRect(50, 50, 100, 100);
+
+ var webglCanvas = document.getElementById("c2");
+ gl = initGL(webglCanvas);
+ if (!setup(gl)) {
+ domAutomationController.setAutomationId(1);
+ domAutomationController.send("FAILURE");
+ }
}
function waitForFinish()
@@ -40,19 +52,21 @@ function waitForFinish()
} else {
g_swapsBeforeAck--;
document.getElementById('container').style.zIndex = g_swapsBeforeAck + 1;
+ drawTriangle(gl);
window.webkitRequestAnimationFrame(waitForFinish);
}
}
</script>
</head>
<body onload="main()">
-<div style="position:relative; width:300px; height:300px; background-color:black">
+<div style="position:relative; width:400px; height:400px; background-color:black">
</div>
<div id="container" style="position:absolute; top:0px; left:0px">
<!--
Canvas acceleration requires that the canvas be at least 256x257.
-->
<canvas id="c" width="300" height="300" class="nomargin"></canvas>
+<canvas id="c2" width="300" height="300" class="nomargin"></canvas>
</div>
</body>
</html>
« no previous file with comments | « cc/blink/web_external_texture_layer_impl.cc ('k') | content/test/data/gpu/pixel_webgl.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698