2 ms·
Using Python to vectorize artwork for PCBs
- thebeardisred 4y agoFor anyone interested in more details about the underlying CAM (computer aided/assisted machining) works I did a write up a couple of years ago - https://brianredbeard.com/blog/the-trouble-with-gerbers/ https://brianredbeard.com/blog/the-trouble-with-gerbers/
- magicalhippo 4y agoOne might want something better than a fixed subdivision of the Bezier curves. Anti-Grain Geometry has a good writeup[1] on how to do that. A quick search revealed a JavaScript library[2] implementing the Anti-Grain solution, for reference. [1]: http://agg.sourceforge.net/antigrain.com/research/adaptive_bezier/index.html http://agg.sourceforge.net/antigrain.com/research/adaptive_b... [2]: https://github.com/mattdesl/adaptive-bezier-curve https://github.com/mattdesl/adaptive-bezier-curve
- phkahler 4y ago>> One might want something better than a fixed subdivision of the Bezier curves. In Solvespace we convert them to piecewise linear (PWL) approximations using a chord tolerance setting. If a straight segment deviates from the actual curve by more than the tolerance it is recursively subdivided. C++ code under GPLv3+ for that is available in my favorite file: https://github.com/solvespace/solvespace/blob/f7415048a5769c78fc4bb02afa426d101059374d/src/srf/ratpoly.cpp#L209 https://github.com/solvespace/solvespace/blob/f7415048a5769c...
- stuntkite 4y agoSomeone once asked on twitter how to generate a PCB trace of the Big Wave Mt. Fuji print. I thought it was an interesting problem and wanted to solve it with Voronoi stippling, halftones, and some other things. I might have been drunk when I did it because some of what's in the readme doesn't make sense. I think possibly I was thinking that it would be cool to do something similar with point clouds created from photogrammatry or real or generated environments using Meshroom. I could also be just making excuses for why I don't understand why I put Meshroom in the README. Regardless, that would be pretty cool and I might try that idea later. I think it's a neat technique though. I made a repo here for anyone that's interested. https://github.com/millerhooks/jacktrace https://github.com/millerhooks/jacktrace It made a few really neat examples. I guess I didn't add my favorites to the repo. This one is pretty fun though. https://github.com/millerhooks/jacktrace/blob/main/Assets/Images/Test0001/bigwave-RedBG-MaskedExample.pdf https://github.com/millerhooks/jacktrace/blob/main/Assets/Im... I only spent a few hours on it but have recently been wanting to readress it. Especially grouping and connecting the vias (stipples) to traces and apply halftones for colors.