New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 735429 link

Starred by 1 user

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 2
Type: Bug

Blocked on:
issue skia:6806



Sign in to add a comment

svg stroke-dasharray rendering deformity on small dash size when on a rotated circle

Reported by jonbur...@gmail.com, Jun 21 2017

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.36

Steps to reproduce the problem:
1. Set small stroke-dasharray size on a circle
2. Wrap circle in <g>
3. Set <g> transform to rotate(-90, X, X);

What is the expected behavior?
The stroke dash should not become deformed

What went wrong?
The stroke dash became deformed

Did this work before? N/A 

Does this work in other browsers? Yes

Chrome version: 58.0.3029.110  Channel: stable
OS Version: OS X 10.12.5
Flash Version: 

https://codepen.io/jon/pen/eRWXgo?editors=1100

The rendering problem is tricky in that it manifests itself at different sizes, and screen sizes - however I cannot reproduce the glitch unless there is the rotate(-90, X, X) or rotate(270, X, X) or anything close to those rotations - so I'm assuming it a problem between transforms and rendering size/position and may occur in other situations also that I have not come across.

I have been unable to reproduce this deformity in Firefox or Safari - however it is still present in Chrome Canary at this time.
 
Screen Shot 2017-06-21 at 13.10.15.png
494 KB View Download
chrome-dasharray-bug.html
873 bytes View Download

Comment 1 by jonbur...@gmail.com, Jun 21 2017

Video demo attached to show how it's conditional on size and placement.
chrome.mp4
39.5 KB View Download

Comment 2 by jonbur...@gmail.com, Jun 21 2017

Also, adding stroke-linecap:round to the circle make the glitch more obvious
chrome.mp4
36.6 KB View Download

Comment 3 by f...@opera.com, Jun 21 2017

Components: Internals>Skia
My guess would be that this is a GPU rasterization bug - could you provide/attach a copy of the chrome://gpu page? (May contain useful information in case this bug does not reproduce generally.)

Comment 4 Deleted

Comment 5 by jonbur...@gmail.com, Jun 21 2017

chrome://gpu attached as PDF
gpu.pdf
126 KB Download

Comment 6 by hcm@chromium.org, Jun 22 2017

Components: Internals>GPU>Rasterization
So far I've been unable to repro on my Mac.

Reporter, does this go away if you disable GPU rasterization in about://flags?

Comment 7 by jonbur...@gmail.com, Jun 22 2017

The bug is still present after disabling GPU rasterization and relaunching :(

Also, if it helps at all, I'm including exact details of my Mac.

Finally, this bug is also present in Opera, but not Safari - so it's something which I guess is a glitch in Blink rather than something old from Webkit
Screen Shot 2017-06-22 at 18.47.03.png
45.8 KB View Download

Comment 8 by ericrk@chromium.org, Jun 23 2017

Components: -Internals>Skia -Internals>GPU>Rasterization
Labels: OS-Linux OS-Windows
Owner: pdr@chromium.org
Status: Assigned (was: Unconfirmed)
I can repro this on Windows/Linux/Mac with or without GPU raster. Note that it helps to get a tall/narrow window and then play around with the window height. As you adjust the height, you should see the issue. Putting code-pen into "full page" view makes this easier to repro (but requires a free account).

If you show tile boundaries (see attached image) you can see that we are failing to draw the content into the top tile. It's likely that an interaction between the rotation and our boudning box calculations is being done incorrectly, and we're deciding that the content doesn't overlap the top tile (even when it does).

Over to pdr@ for blink investigation. 

Comment 9 by ericrk@chromium.org, Jun 23 2017

actually attach image
tile_boundary_clipping.png
27.3 KB View Download

Comment 10 by pdr@chromium.org, Jun 23 2017

Labels: -Type-Bug Needs-Bisect Type-Bug-Regression
Testers, can you please follow these instructions:
1) Load https://codepen.io/jon/pen/eRWXgo?editors=1100
2) Resize the middle slider, notice that the purple area can get clipped.

Comment 11 by pdr@chromium.org, Jun 27 2017

Cc: pdr@chromium.org
Components: Internals>Skia
Labels: -Needs-Bisect -Type-Bug-Regression OS-All Type-Bug
Owner: fmalita@chromium.org
I bisected this and it has existed for a long time so not a regression after all.

Here's a minimized repro: http://output.jsbin.com/jimihah/quiet

I think we're getting the wrong bounds from Skia, possibly due to numeric precision of the stroke.

Florin, would you be able to triage this further?
pie.skp
512 bytes Download
Blockedon: skia:6806
Cc: caryclark@google.com reed@google.com
Components: -Blink>SVG
Labels: -OS-Linux -OS-Windows -OS-Mac
Filed https://bugs.chromium.org/p/skia/issues/detail?id=6806.
Labels: PaintTeamTriaged-20170621 BugSource-User

Sign in to add a comment