JP's Laboratory

Posts / Code / Photos / Videos / Contact

SVG code generator for ring sections

Written: 20130202

Generate SVG code for ring sections for laser cutting. You can try the code here.

When cutting a ring/wheel/circle using a laser cutter or CNC mill there is a lot of potential for wasting material, depending on how much empty space is inside the ring. This code is an effort to make the waste less by sectioning the ring up into smaller parts, which can be arranged afterwards, to take less space on the plate out of which they are cut.

The program is contained in one single HTML file, and you are welcome to modify it and put it on your own webpage. To use the program open the HTML file in a browser that supports SVG.

Fill in the following fields. The inner and outer diameter specify the radii of the round edges of the ring. The stroke width gives the line with to use. For laser cutting it is common to use some predefined thickness. Note that if the stroke width is set to a very small value, the browser might not render the part.

Inner radius: mm
Outer radius: mm
Stroke width: mm

Copy this text field and save it to a file with a .SVG extension. Note: The SVG seems to work with Chrome and Inkscape. The stroke width seems to be interpreted incorrectly by Adobe Illustrator, so be aware.

comments powered by Disqus