Crate svg_path_parser

Source
Expand description

Simple SVG path parsing. Parses a SVG path string (the thing that goes in ‘d’) into sets of points representing continuous lines.

§Usage

let paths = svg_path_parser::parse(&path).collect::<Vec<(bool, Vec<(f64, f64)>)>>();

Each (bool, Vec<(f64, f64)>) represents a continuous line, with the bool indicating if the line is closed. A closed line has the ending point connect to the starting point.

Structs§

PathParser
Iterator over continuous lines.

Functions§

parse
Parse a SVG path string.
parse_with_resolution
Parse a SVG path string with custom resolution.