Visualize.Backend.Canvas.Arc (Visualize v0.2.25)

Copy Markdown View Source

Converts an SVG arc command to a Canvas ellipse call.

Canvas draws arcs from a centre, radii and two angles; SVG describes them by their end points, radii, rotation and two flags. This is the endpoint-to-centre conversion of the SVG specification (implementation notes §B.2.4), the same maths the browser hooks used to carry, done once on the server so every Canvas output format is executable (spec/09 §3.3.2, D-37).