The macro imports the SVG at compile time and turns into a function you can call at runtime by passing a paint_ctx. The x and y are the origin you want to paint at (
use svg_to_piet::*; #[derive(SvgToPiet)] #[file = "test.svg"] struct TrashCan; TrashCan::draw(paint_ctx, x, y);
Command line usage
Outputs a list of draw instructions to the command line so you can copy and paste them wherever you'd like.
cargo run test.svg