Giter Club home page Giter Club logo

Comments (7)

caleb531 avatar caleb531 commented on September 24, 2024

Really? Because I just ran QUnit on your latest tests now and all tests passed with no errors:

Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11
Tests completed in 80 milliseconds.
20 assertions of 20 passed, 0 failed.

from jcanvas.

dksmiffs avatar dksmiffs commented on September 24, 2024

Here's mine (I've added another test since committing last, but it's still the same one failing). Looks like I've got a slightly older Chromium baseline. I'll see if I can dig up a 23.0 Chromium for Linux, and I'll report back later.

Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.4 (KHTML, like Gecko)
Ubuntu/12.10 Chromium/22.0.1229.94 Chrome/22.0.1229.94 Safari/537.4
Tests completed in 136 milliseconds.
20 assertions of 21 passed, 1 failed.

from jcanvas.

caleb531 avatar caleb531 commented on September 24, 2024

Oh, I forgot that you're on Linux. I believe I know what the issue is now. ;)

Apparently, there is a Chromium-only Linux-only (yes, really) bug which will render an arc invisible if one of its start/end angles is -pi/2 radians. Because jCanvas measures 0 degrees from the top (rather than from the east), you technically end up with a start angle of -90 degrees (or -pi/2 radians). However, because jCanvas does this internally, you interpret the start angle as 0, when it's really -pi/2.

It's an unfortunate (and bizarre) bug which certainly needs to be filed somewhere.

from jcanvas.

dksmiffs avatar dksmiffs commented on September 24, 2024

Couldn't find a 23.0 Chromium, but found a 23.0 Chrome (produces same error), looks like it's a Chrome/Chromium Linux-only bug.

Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.11 (KHTML, like Gecko)
Chrome/23.0.1271.64 Safari/537.11
Tests completed in 141 milliseconds.
20 assertions of 21 passed, 1 failed.

from jcanvas.

dksmiffs avatar dksmiffs commented on September 24, 2024

I did more testing with drawArc, explicitly specifying start and end values. The only combination I could find of values 2_PI apart that rendered an "invisible" arc was start: 0 radians and end: 2_PI radians. For example, start: -2*PI radians, end: 0 radians works just fine (non-invisible arc).

Related question: is the following the "official" spec we should use to properly understand arc()?
http://dev.w3.org/html5/2dcontext/#dom-context-2d-arc

from jcanvas.

caleb531 avatar caleb531 commented on September 24, 2024

Perhaps, but I don't think an understanding the spec will help to solve the issue here. All browsers except Chromium on Linux seem to implement arc() correctly (because the bug does not occur on these browsers). Therefore, it seems to me as more of a bug rather than a correct implementation that everybody else got wrong.

Therefore, I believe one of us should file an issue on the Chromium bug tracker. If I may suggest, I would suggest that you do so because you experience the issue directly as a Linux user (whereas I use a Mac, and so I can't provide further details regarding the issue).

What do you think?
-Caleb

from jcanvas.

dksmiffs avatar dksmiffs commented on September 24, 2024

Caleb, I submitted Chromium issue 162635 as you suggested. Also, I am now completely confident this is not a jCanvas issue, so I am closing this issue.

from jcanvas.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.