abey79 / vpype

The Swiss-Army-knife command-line tool for plotter vector graphics.
https://vpype.readthedocs.io/
MIT License
704 stars 62 forks source link

Add more filter options #615

Closed piebro closed 1 year ago

piebro commented 1 year ago

Hey, first of all, thanks for your awesome project. It helped me a lot using my plotter.

I have a marker that can only draw for about 10m before needing some shaking, but I would also like to plot an image with a longer drawing path. I can do this easily by hand and just split the plot SVG into two or more parts, but as far as I can see, there is no way to do this with a command using the filter options. I think a filter that allows me to set a maximum total draw distance or to only include the lines with index i to j would be handy for this use case.

abey79 commented 1 year ago

Thanks for the nice words 🙏🏻

You're probably looking for the splitdist command. There is a rather elaborate use case documented in the cookbook for paint application. In your case, a direct use of splitdist should get you close to what you need.

Further, if you happen to use the axidraw, you could rename all layers with !, which would have the axidraw pause so you get a chance to restart the pen. I just wrote about his here.

piebro commented 1 year ago

Yes that's exactly the splitdist command is exactly what I had in mind. It works like a charm, thanks! I'm not sure how I missed it.

The paint application cookbook looks pretty interesting too. I thought about using watercolor with my plotter for a while and this would make it a lot easier. Thanks!