Inventables Community Forum

Depth on returned SVG paths

At the moment, there is no way to stuff a depth value on the path object in the returned SVG code, correct? It’s obviously not in the SVG spec.

A lot could be accomplished with just this tiny feature.

I’m looking forward to API v2 though I haven’t a clue what it contains. But hope springs eternal. I would love it if something to this effect showed up.

Thanks for reading!

You use varying shades of RGB. 0 is cut al the way to maximum depth, 255 is don’t cut. You can also specify stroke for outline cuts and fill for fill cuts. Hopefully the following SVG data will point you in the right direction.

<?xml version="1.0" encoding="UTF-8" standalone="no"?>

< svg xmlns=“http://www.w3.org/2000/svg” version=“1.0” width=“6.25in” height=“3.75in” viewBox=“0 0 6.25 3.75”>
< path d=" M 0 0.251 L 0 3.751 6 3.751 6 2.876 0.751 2.876 0.751 0.251 Z " fill=“none” stroke=“rgb(0,0,0)” stroke-width=“0.1”/>
< rect x=“0” y="-0.250.25" width=“0.251” height=“4” style=“fill:rgb(191,191,191)” />
< rect x=“1.251” y=“3.126” width=“5” height=“0.5” style=“fill:rgb(153,153,153)” />
< rect x=“0.251” y="-0.250.25" width=“0.5” height=“1” style=“fill:rgb(0,0,0)” />
< /svg>

note I had to add a space between the “<” and the tag so that the forum software wouldn’t make the text disappear.

1 Like

That is exactly what I needed. Thank you very much!