Potrace
$ potrace Community Low Riskpotrace transforms bilevel raster bitmaps (PBM, PGM, PPM, BMP) into smooth, scalable vector curves across backends (-b svg, -b pdf, -b eps, -b dxf, -b geojson). Paired with bundled mkbitmap, it converts monochrome scans, logos, and silhouettes cleanly.
brew install potrace Deterministic bitmap-to-SVG vector tracing runs locally in milliseconds without MCP.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
Fast non-interactive C CLI with -o - stdout support and -b geojson backend, though lacks JSON inspection and --dry-run.
- Supports
-o -stdout and multiple-bvector backends - Rejects PNG/JPEG directly (requires BMP/PNM)
Never mutates input bitmaps; writes either to -o or <stem>.<ext>.
- Non-destructive to input bitmaps;
-o -avoids disk writes
Zero-dependency C binary packaged on Homebrew, Linux distros, and Windows.
- Available via
brew install potraceand SourceForge
Produces clean single-color SVG/PDF/GeoJSON paths, though multi-color tracing or PNG input requires preprocessing (mkbitmap, magick).
- Only traces bilevel/grayscale PNM and BMP inputs natively
Stable veteran utility by Peter Selinger (potrace.sourceforge.net) with infrequent maintenance updates.
- Mature codebase maintained by Peter Selinger
Thorough man page and -h help covering corner thresholds (-a), despeckling (-t), and backends (-b).
- Man page hosted at potrace.sourceforge.net/potrace.1.html
Security, Auth & Guardrails
None required; operates on local bitmap files or stdin/stdout.
Free GPL-2.0-or-later open-source C binary.
# Potrace Agent Rules - `potrace` only reads PBM/PGM/PPM/BMP—convert PNG or JPEG inputs to BMP/PGM first via `magick` or `vips`. - Pass `-s` (for SVG) and `-o <out.svg>` explicitly, because default output is EPS (`<input>.eps`).
Agent-Ready Command Recipes
Safe Read-Only Queries
potrace -s -o - logo.bmp
Outputs traced SVG XML directly to stdout (-o -) while keeping logo.bmp untouched.
Controlled Writes & Previews
potrace -s bitmap.bmp -o vector.svg
Traces bitmap.bmp into smooth Bézier paths saved to vector.svg.
Strengths for Agents
- + Produces mathematically smooth, compact Bézier SVG/PDF/GeoJSON paths from bitmaps.
- +
-o -allows clean stdout piping for SVG inspection without temporary files.
Caveats & Pitfalls
- ! Does not read PNG or JPEG files directly; requires conversion to BMP/PBM/PGM first.
- ! Defaults to EPS output unless
-s(-b svg) or another-bbackend is specified.