Follow

If you're into generative vector graphics I might have something cool for you: I finally found a workflow for script-based generation of vector primitives and text, including - and here it gets interesting - the ability to perform arbitrary scripted boolean operations between all objects (!), and the subsequent possibility to export all results as svg.

This might not look or sound like much, but to my surprise it was incredibly hard to find a library/approach for this. paperjs.org/ is what saved the day, they took on the complex and somewhat unthankful job of implementing fast and accurate boolean operations within an API and framework that is accessible and productive to work with. I've also used github.com/opentypejs/opentype here to get the text as a vector path, but it seems this might be do-able in Paper.js too, possibly.

While researching this I looked into scripting inkscape with python, directly using inkscape's libgeom library, using OpenSCAD, etc. ... so as you see I was already quite desperate. :D I'd be delighted to learn if you know of any alternative approaches to get the above-mentioned workflow done. This is powerful stuff and the more ways to do it, the better. :)

· · Web · 0 · 1 · 0
Sign in to participate in the conversation
post.lurk.org

Welcome to post.lurk.org, an instance for discussions around cultural freedom, experimental, new media art, net and computational culture, and things like that.