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

Issue 627420 link

Starred by 2 users

Issue metadata

Status: WontFix
Owner: ----
Closed: Jul 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 2
Type: Bug



Sign in to add a comment

<canvas> ctx.clip() not working properly when canvas is too big

Reported by jesperth...@gmail.com, Jul 12 2016

Issue description

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

Example URL:
http://codepen.io/jespertheend/pen/vKWNmQ

Steps to reproduce the problem:
1. Go to http://codepen.io/jespertheend/pen/vKWNmQ
2. Make the canvas bigger using the slider
3. Once it reaches about 430, clip() starts behaving weird

What is the expected behavior?
The shape would still look the same as what it looked before the canvas was wider than about 430 pixels.

What went wrong?
The text and the black box is not being properly clipped any more, instead of being clipped by the shape of the green triangle it is being clipped by a rectangle that appears to be the bounding box of the green triangle.

See attached images for a reference.
This problem occurs on multiple websites. One example I can give is agar.io. Where all the spheres appear as boxes. A screenshot is also attached.

Does it occur on multiple sites: Yes

Is it a problem with a plugin? No 

Did this work before? N/A 

Does this work in other browsers? Yes 

Chrome version: 52.0.2743.60  Channel: beta
OS Version: OS X 10.11.3
Flash Version: Shockwave Flash 22.0 r0

I have tested this on multiple computers but I'm only able to reproduce the issue on one device. So I feel it's necessary to share some more info about this device.

OS X El Capitan 10.11.3 (15D21)
Intel Core i7-6700K 4.0GHz Quad-Core Processor
MSI GeForce GTX 980 Ti 6GB Video Card
 
Screenshot 2016-07-12 14.02.55.png
8.4 KB View Download
Screenshot 2016-07-12 14.03.00.png
13.5 KB View Download
Screenshot 2016-07-12 14.04.20.png
206 KB View Download
Components: -Blink Blink>Canvas

Comment 2 by junov@chromium.org, Jul 25 2016

Could you attach the contents of your chrome://gpu page to this issue?

Comment 3 by junov@chromium.org, Jul 25 2016

Cc: bsalomon@chromium.org junov@chromium.org
Components: -Blink>Canvas Internals>Skia Internals>GPU>VendorSpecific
At a width of 439, canvas cross the threshold where GPU acceleration get use for rendering 2D canvases.  This is most likely a bug related to a specific GPU or driver.

@bsalomon: Could someone from the skia-gpu team look at this? I wanted to test flipping some of the stencil related bits in GrGLCaps to see if the issue could be fixed that way, but I do not have access to a machine that can reproduce this bug. 
gpu.htm
49.8 KB View Download
I disabled accelerated 2d canvas at chrome://flags/#disable-accelerated-2d-canvas
and that did indeed solve the problem.

Comment 6 by bsalo...@google.com, Jul 25 2016

I don't think we have any similarly configured machines. Is this a hackintosh?
Yes it is, I thought I mentioned that but I guess I forgot.

Comment 8 by bsalo...@google.com, Jul 25 2016

Status: WontFix (was: Unconfirmed)
Ok. Sorry to say that I don't think we'll be able to investigate this. It would require us to construct a similar system which gets into licensing issues. It sounds likely to be a driver issue in which case there is no real way forward if it's not a configuration supported by the hw/sw vendors. If this repros on another OS or a supported Mac configuration we could take it up.
Alright that's ok, if this issue only happens on similar systems, chances are not many people will have the issue anyway.

Sign in to add a comment