[Bug 14579] New: filing a separate feature request as requested in http://www.w3.org/Bugs/Public/show_bug.cgi?id=14562 --- Please add an elliptical arc command in addition to the circular arc command. For nice graphics, you need the elliptical arc, and a separate circular

http://www.w3.org/Bugs/Public/show_bug.cgi?id=14579

           Summary: filing a separate feature request as requested in
                    http://www.w3.org/Bugs/Public/show_bug.cgi?id=14562
                    --- Please add an elliptical arc command in addition
                    to the circular arc command. For nice graphics, you
                    need the elliptical arc, and a separate circular
           Product: HTML WG
           Version: unspecified
          Platform: Other
               URL: http://www.whatwg.org/specs/web-apps/current-work/#top
        OS/Version: other
            Status: NEW
          Severity: normal
          Priority: P3
         Component: HTML Canvas 2D Context (editor: Ian Hickson)
        AssignedTo: ian@hixie.ch
        ReportedBy: contributor@whatwg.org
         QAContact: public-html-bugzilla@w3.org
                CC: mike@w3.org, public-html-wg-issue-tracking@w3.org,
                    public-html@w3.org


Specification: http://www.w3.org/TR/2dcontext/
Multipage: http://www.whatwg.org/C#top
Complete: http://www.whatwg.org/c#top

Comment:
filing a separate feature request as requested in
http://www.w3.org/Bugs/Public/show_bug.cgi?id=14562
---

Please add an elliptical arc command in addition to the circular arc command.
For nice graphics, you need the elliptical arc, and a separate circular arc is
a bonus because you can perfectly reproduce a circle with an ellipse. As such,
please add an elliptical arc command to the API. It won't break work already
done by people so far, it's not a lot of work to implement for browser makers,
and for the end user it will offer a fast and correct arcing command, unlike
artificial solutions involving rolling your own approximation using bezier
curves or implementing the midpoint algorithm every time you need an
elliptical arc.

Use cases: anything from general drawing libraries to people directly using
the canvas to draw simple things. My personal use case is the Processing.js
project, but anyone who wants to draw ellipses or parts of ellipses is covered
by this request. Since the ellipse is a common primitive in every major
graphical application, and everyone expect it to exist in graphical languages,
the fact that Canvas2D doesn't have one is simply an oversight that can be
remedied without too much work for everyone.

In response to Robert O'Callahan: using a scaled circular arc will lead to the
stroking in either x or y dimension being either too thin (if scaled down) or
too thick (if scaled up). In addition, it's just as artificial as
approximating an elliptical arc with bezier curves in the sense that you'd be
writing a lot of code to do something that should be available as a single
command; a bit like not offering people a rect() command, but instead telling
them to use a combination of line() and rotate(). Your suggestion is a
possible stopgap measure (although not as good as bezier approximation,
because of the scaling interpolation), but cannot be considered a good
solution.

Posted from: 205.250.164.138
User agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.1 (KHTML, like
Gecko) Chrome/14.0.835.187 Safari/535.1

-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

Received on Thursday, 27 October 2011 22:02:29 UTC