Genetic algorithms turn your photos into geometric art
A Go tool that evolves triangles and polygons to match an image, trading speed for a true triangulation with no overlaps.

What it does Triangula takes a source image and runs a modified genetic algorithm to find a set of points whose triangulation (or polygonation) best approximates the original. You get a clean SVG or PNG made of flat geometric shapes, not a filtered photo. It ships as both a Wails-based GUI and a CLI tool, with a browser demo if you want to test before installing.
The interesting bit The algorithm insists on a proper triangulation — triangles never overlap, unlike similar tools such as fogleman/primitive. That constraint makes the math tidier and the output feel more deliberate, but it also means Triangula needs 1–2 minutes where esimov/triangle finishes instantly. The README is admirably honest about this trade-off.
Key highlights
- Modified genetic algorithm with configurable population size (default 400), mutation rate, and variation
- Renders to SVG or PNG; CLI outputs intermediate JSON so you can stop and resume
- Parallel evaluation with tunable thread count and block-based caching for performance
- GUI built with Wails, desktop app runs 20–50× faster than the browser version
- Go API exposed for embedding in your own pipelines
Caveats
- Best under 3000px and 3000 points; larger images likely struggle
- Linux users may need to manually tick “allow executing file as program”
- Effects and some formats (TIFF, WebP, HEIC) not yet supported in exports
Verdict Worth a look if you want reproducible, geometric art with clean topology — or if you’re curious how genetic algorithms behave on a visual fitness function. Skip it if you need instant results; esimov/triangle wins on speed.