Expand description
SVG path string parser — converts SVG d attribute strings to PathCommands.
Supports the standard SVG path commands: M, L, Q, C, Z (and lowercase relative variants). This enables loading paths from SVG files or design tools without any DOM dependency.
GSAP equivalent: path: "#svgPath" (but operates on the d string
directly instead of querying the DOM).
§Example
use spanda::svg_path::SvgPathParser;
use spanda::motion_path::{CompoundPath, PathCommand};
let commands = SvgPathParser::parse("M 0 0 C 50 100 100 100 150 0 L 200 0");
let path = CompoundPath::new(commands);
let pos = path.position(0.5);Structs§
- SvgPath
Parser - A zero-allocation SVG path string parser.