Canvas SVG parser: Difference between revisions

Jump to navigation Jump to search
m
→‎Known Limitations: Comment about the shapes found in the Vector Graphics Utility Library
m (Johan G moved page Canvas SVG Parser to Canvas SVG parser: Sentence case title)
m (→‎Known Limitations: Comment about the shapes found in the Vector Graphics Utility Library)
Line 175: Line 175:
* http://www.w3.org/TR/SVG/struct.html#ImageElement
* http://www.w3.org/TR/SVG/struct.html#ImageElement


Shapes are also currently not supported, you'll typically want to use Inkscape's "simplify" option:
Shapes are also currently not exposed to Nasal, you'll typically want to use Inkscape's "simplify" option. Basic shapes like Line, Polygon, Rect, RoundedRect, Ellipse and Arc are available through the VGU Utility Library and could be implemented in Nasal directly.
{{FGCquote
{{FGCquote
   |Learnt the hard way that SVG parsing (for ''svg_path'' in ''AA.symbol'') in FG doesn't recognize ''<circle>'', ''<ellipse>'', etc., so I opened my hand-coded SVG in Inkscape and used ''Path->Simplify'' (which ostensibly converts shapes to paths) to convert it to a code compatible with FG.
   |Learnt the hard way that SVG parsing (for ''svg_path'' in ''AA.symbol'') in FG doesn't recognize ''<circle>'', ''<ellipse>'', etc., so I opened my hand-coded SVG in Inkscape and used ''Path->Simplify'' (which ostensibly converts shapes to paths) to convert it to a code compatible with FG.
160

edits

Navigation menu