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

Issue 1983863002: Inflate dirty rect by 1 pixel on a high DPI display (Closed)

Created:
4 years, 7 months ago by xidachen
Modified:
4 years, 7 months ago
CC:
chromium-reviews, dshwang, ajuma+watch-canvas_chromium.org, blink-reviews-html_chromium.org, haraken, dglazkov+blink, Rik, blink-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Inflate dirty rect by 1 pixel on a high DPI display On a high dpi display, putImageData leaves visible artifacts around the affected area's border. This CL fixes it in the way that when there is antialias involved, the dirty rect is inflated by 1 pixel. Locally we can see this bug goes away with this fix on a retina display. Note that this bug doesn't repro with our layout test. So a manual test is added to prevent regression. BUG=609820 Committed: https://crrev.com/0baf3521c90b2efda95e33c5ed26cc2c51423381 Cr-Commit-Position: refs/heads/master@{#394286}

Patch Set 1 #

Patch Set 2 : adding layout test for debugging #

Total comments: 2

Patch Set 3 : move layout test to ManualTests #

Total comments: 1

Patch Set 4 : address comment #

Patch Set 5 : make inflation happen only when it is a hidpi display #

Patch Set 6 : nullcheck on page() #

Unified diffs Side-by-side diffs Delta from patch set Stats (+40 lines, -0 lines) Patch
A third_party/WebKit/ManualTests/canvas-ClearRect-hidpi.html View 1 2 3 1 chunk +31 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp View 1 2 3 4 5 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/html/canvas/CanvasRenderingContext.h View 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/modules/canvas2d/CanvasRenderingContext2D.h View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/modules/canvas2d/CanvasRenderingContext2D.cpp View 1 2 3 4 1 chunk +5 lines, -0 lines 0 comments Download

Messages

Total messages: 24 (11 generated)
xidachen
PTAL. I tried to add a layout test, but the bug doesn't repro with a ...
4 years, 7 months ago (2016-05-16 14:43:56 UTC) #2
Justin Novosad
On 2016/05/16 14:43:56, xidachen wrote: > PTAL. > > I tried to add a layout ...
4 years, 7 months ago (2016-05-16 15:27:31 UTC) #3
xidachen
On 2016/05/16 15:27:31, Justin Novosad wrote: > On 2016/05/16 14:43:56, xidachen wrote: > > PTAL. ...
4 years, 7 months ago (2016-05-16 15:40:59 UTC) #4
Justin Novosad
Could be due to mesa no behaving exactly the same as a real GPU, or ...
4 years, 7 months ago (2016-05-16 15:56:49 UTC) #5
xidachen
https://codereview.chromium.org/1983863002/diff/20001/third_party/WebKit/LayoutTests/fast/canvas/canvas-ClearRect-hidpi.html File third_party/WebKit/LayoutTests/fast/canvas/canvas-ClearRect-hidpi.html (right): https://codereview.chromium.org/1983863002/diff/20001/third_party/WebKit/LayoutTests/fast/canvas/canvas-ClearRect-hidpi.html#newcode8 third_party/WebKit/LayoutTests/fast/canvas/canvas-ClearRect-hidpi.html:8: testRunner.setBackingScaleFactor(2, function() { init(); }); On 2016/05/16 15:56:49, Justin ...
4 years, 7 months ago (2016-05-16 16:53:16 UTC) #6
Justin Novosad
https://codereview.chromium.org/1983863002/diff/40001/third_party/WebKit/ManualTests/canvas-ClearRect-hidpi.html File third_party/WebKit/ManualTests/canvas-ClearRect-hidpi.html (right): https://codereview.chromium.org/1983863002/diff/40001/third_party/WebKit/ManualTests/canvas-ClearRect-hidpi.html#newcode6 third_party/WebKit/ManualTests/canvas-ClearRect-hidpi.html:6: the result should be a clear canvas with no ...
4 years, 7 months ago (2016-05-16 17:08:54 UTC) #7
Justin Novosad
On 2016/05/16 17:08:54, Justin Novosad wrote: > https://codereview.chromium.org/1983863002/diff/40001/third_party/WebKit/ManualTests/canvas-ClearRect-hidpi.html > File third_party/WebKit/ManualTests/canvas-ClearRect-hidpi.html (right): > > https://codereview.chromium.org/1983863002/diff/40001/third_party/WebKit/ManualTests/canvas-ClearRect-hidpi.html#newcode6 ...
4 years, 7 months ago (2016-05-16 17:09:51 UTC) #8
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1983863002/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1983863002/60001
4 years, 7 months ago (2016-05-16 17:14:07 UTC) #11
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1983863002/80001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1983863002/80001
4 years, 7 months ago (2016-05-17 18:11:46 UTC) #14
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1983863002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1983863002/100001
4 years, 7 months ago (2016-05-17 18:58:54 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1983863002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1983863002/100001
4 years, 7 months ago (2016-05-18 00:28:28 UTC) #20
commit-bot: I haz the power
Committed patchset #6 (id:100001)
4 years, 7 months ago (2016-05-18 00:33:49 UTC) #22
commit-bot: I haz the power
4 years, 7 months ago (2016-05-18 00:36:33 UTC) #24
Message was sent while issue was closed.
Patchset 6 (id:??) landed as
https://crrev.com/0baf3521c90b2efda95e33c5ed26cc2c51423381
Cr-Commit-Position: refs/heads/master@{#394286}

Powered by Google App Engine
This is Rietveld 408576698