Categories
Uncategorized

2D to 3D to 2D

Parts

There comes a time when every designer who designs things in two dimensions that get assembled into something that has three dimensions wants to have a diagram with some… dimensions.

Above is a dimensional illustration of the parts of the mount for the shaft for the machine I am building.

If I were to provide assembly instructions I’d probably want such a drawing. Here are some notes on the process, so I can do it again next time.

Parts in Inkscape

In Inkscape, each piece must be an object. The ‘holes’ cannot be separate objects, but must be cut out (differenced) from the main object. (This is the same method needed when bringing a 2D drawing into OpenSCAD, so nothing new there.)

Sadly, Rhino cannot import SVG files. (Mini-rant: I’m always surprised at the number of applications that do not support SVG. The SVG specification has been an open standard from the WC3 since 1999!) Rhino can import PDF files, so export your Inkscape file as a PDF. Your PDF should be a vector PDF, by default. Inkscape should do the right thing unless you’ve done something silly to your file. (Which is possible, I’ve done it.)

Parts in Rhino

Our vector file is now in Rhino! Double-check to make sure each line/object did not get doubled-up. I’ve had it happen a few times but could not conclusively determine what causes it. It may be the width of the stoke of the objects in Inkscape.

You can now extrude your object(s) in Rhino. I make them the height of the material I am using. Oh, I’ll be laser cutting these pieces with 4.45mm acrylic. YMMV.

Solids in Rhino

Change the view in Rhino from wireframe to solid and you’ll see your new 3D object(s)…

Extruded in Rhino

Make sure the holes are really holes! If not, re-read the part above about objects and holes and such. You need to difference any cut out things!

Make2D in Rhino

Now you can move your new object(s) because the original vector lines we imported in are probably sitting right underneath them. Swing your object(s) into the view you want… get that angle just right, and then choose “Make 2-D Drawing” from the “Dimension” menu.

2D from 3D

You should now have a 2D version of your 3D object. Rhino should also select it by default, so you can use the “Export Selection” menu to save it out as… A DXF file. :( Sadly, Rhino cannot export as an SVG or vector PDF, or even an EPS file. Rhino can export as an Illustrator file (.ai) but Inkscape cannot open those. The AI file it exports starts with “%!PS-Adobe-3.0” which is probably a format from that was popular in the 1990s.

3D/2D in Inkscape

Anyway, we can certainly import that DXF file back into Inkscape and work with it, and make it look like a nice vector drawing. Mostly. Sort of. I mean, if you want to just fill it with a color or change the stroke, it’s not quite that easy. If you just want a line drawing that isn’t too fancy, mission accomplished!

Oh, and not that I want to turn Inkscape in a 3D application, but I could see great value in being able to extrude and change the view angle of a vector drawing… maybe through an extension?

Note: Lots of comments about this post are on Facebook.