2 unstable releases
Uses new Rust 2024
| 0.2.0 | Jan 3, 2026 |
|---|---|
| 0.1.0 | Jan 2, 2026 |
#325 in Images
96 downloads per month
Used in 11 crates
(10 directly)
265KB
6.5K
SLoC
Path geometry and operations for skia-rs.
This crate provides path-related functionality:
- Path construction and manipulation
- Path effects (dash, corner, etc.)
- Path operations (union, intersect, difference)
- Path measurement and traversal
- SVG path parsing
- Stroke-to-fill conversion
skia-rs-path
Path geometry and operations for skia-rs, a pure Rust implementation of the Skia 2D graphics library.
Features
- Path construction:
Path,PathBuilderwith fluent API - Path operations: Boolean union, intersect, difference, xor
- Path effects: Dash, corner, discrete, trim effects
- SVG parsing: Parse SVG path data strings
- Path measurement: Length, position along path
Usage
use skia_rs_path::{PathBuilder, PathOps};
// Build a path with fluent API
let path = PathBuilder::new()
.move_to(0.0, 0.0)
.line_to(100.0, 0.0)
.quad_to(150.0, 50.0, 100.0, 100.0)
.close()
.build();
// Parse SVG path data
let heart = PathBuilder::from_svg("M 10,30 A 20,20 0,0,1 50,30 ...").build();
// Boolean operations
let union = PathOps::union(&path1, &path2);
License
MIT OR Apache-2.0
See the main repository for more information.
Dependencies
~7MB
~205K SLoC