绘图仪艺术实验
Experiments with Plotter Art

原始链接: https://sometimes.digital/posts/experiments-with-plotter-art/

作者记录了他们使用改装后的 Ender 3 3D 打印机进行生成式绘图艺术的探索过程。通过用磁铁将针管笔固定在打印头上,他们搭建了一套实用且经济的绘图装置。 为了生成艺术作品,作者使用 Inkscape 将矢量路径转换为 G 代码,并指出 Hershey 字体对于制作清晰的线条文字至关重要。其工作流程的核心是“Simple Inkscape Scripting”插件,它支持基于 Python 的程序化生成。由于该工具支持 NumPy 和 Pillow 等库,作者可以轻松尝试各种算法设计,例如从手绘输入中提取流动的抽象形状。该项目凸显了通过结合廉价硬件与灵活的脚本软件,生成式艺术变得触手可及。作者计划在继续探索新技术的同时更新他们的进展。

Hacker News 最新 | 过往 | 评论 | 提问 | 展示 | 招聘 | 提交 登录 绘图仪艺术实验 (sometimes.digital) 4 分,由 surprisetalk 发布于 1 小时前 | 隐藏 | 过往 | 收藏 | 讨论 | 帮助 指南 | 常见问题 | 列表 | API | 安全 | 法律 | 申请 YC | 联系 搜索:
相关文章

原文

Experiments With Plotter Art

For the past couple of weeks I have been trying to learn more about generative (procedural) art. I plan to update this post continually when I have more things to write down and share. Scanned plotter drawing of an abstract flowy shape.

Around five years ago I bought an Ender 3 3D printer. It is capable, but frustrating to configure and picky about the filament. They go second-hand for around €60. For the past couple of years it has been collecting dust stored safely in its original cardboard box.

I have glued two small neodymium magnets to a 0.2mm fineliner pen. The printer head casing is made of metal and the magnets attach to it securely enough. The position of the pen has to be offset in relation to the nozzle – either in the configuration or when preparing the gcode.

I have been using Inkscape to generate gcode from vector paths (in Extensions → Gccodetools → Path to Gcode). It runs on the printer without any modifications. Inkscape also comes with some stroke-based (engraving) fonts, including Hershey fonts (in Extensions → Text → Hershey Text) – with normal fonts, the plotter would draw the outlines of the characters, which doesn’t work very well.

Inkscape doesn’t support scripting natively, but there is an extension called Simple Inkscape Scripting by Scott Pakin and it is just so fun to use. It is very well documented – the API feels similar to p5.js, but it is based on SVG paradigms. It’s Python, so it can be used with Pillow or NumPy, which opens up a lot of possibilites.

Scanned plotter drawing of an abstract flowy shape.

Because the set-up is so frictionless, I can spend more time experimenting and learning new techniques.

For example, I have been enjoying creating these sort of flowy abstract shapes that I learned about from this article. The author uses different tooling, but the algorithm is pretty much the same as in my Python implementation:

import math

for shape in selected_shapes():
for i in range(150):
copy = duplicate(shape)
copy.rotate(i * math.sin(math.radians(i)), "center")
copy.scale((i + 1) / 100)
copy.translate((0, i * 0.2))
shape.remove()

In Inkscape, I draw a shape, select it, and run the script (in Extensions → Render → Simple Inkscape Scripting). I think it’s really interesting that the input for the script can be drawn by hand – it feels very natural and intuitive.

联系我们 contact @ memedata.com