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

Side by Side Diff: third_party/WebKit/ManualTests/canvas-ClearRect-hidpi.html

Issue 1983863002: Inflate dirty rect by 1 pixel on a high DPI display (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: move layout test to ManualTests Created 4 years, 7 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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <html>
3 <body>
4 <p>
5 Test for crbug.com/609820. When running this test on Mac with retina display,
6 the result should be a clear canvas with no artifact.
Justin Novosad 2016/05/16 17:08:54 ... after a few seconds.
7 </p>
8 <canvas id='output' width='300' height='250'></canvas>
9 <script>
10 var repeat = 350;
11 var x = y = 0;
12 var canvas = document.getElementById("output");
13 var ctx = canvas.getContext('2d');
14 ctx.fillStyle = "#FF0000";
15
16 requestAnimationFrame(animate);
17
18 function animate()
19 {
20 ctx.clearRect(x, y, 50, 50);
21 x++;
22 y++;
23 ctx.fillRect(x, y, 50, 50);
24 repeat--;
25 if (repeat > 0)
26 requestAnimationFrame(animate);
27 }
28 </script>
29 </body>
30 </html>
31
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698