I think that would be doable. Would you then apply different wood appearances to surfaces?
I propose something like this:
- Traverse feature tree (for parts or assemblies?)
- Traverse (flat) surfaces for each part. I don't know how to do this actually, I couldn't find an API call for this.
- Change view orientation to normal to that surface
- Save view as DXF
You can create a predefined view in those model with view normal to the face you want to extract. And then can extract that view/face via API.
I use a blank drawing format and place the 2D views I need and then export it as a DXF. This gives me the 2D patterns I need for our CNC routers.
I currently select each face and export to dxf but if you have 30+ face's to export it take way to long so was hoping to automate this to speed things up. Pathfinder 3d looks like it will do what Im after but was kinda hoping for a cheaper option.
Yes. It's possible, here's how you do it:
Get the IPartDoc object.
Next get all the bodies of the part get IPartDoc::GetBodies().
Next you want to traverse all bodies doing the following:
With each body you traverse, get all faces using Body2::GetFaces()
Now you want to traverse all faces you got from the body
With each face you traverse, you want to check if the face is planar. (Get the ISurface object using GetSurface() and use the method IsPlane() to see if the surface is planar).
If the surface is planar, you select the face2 with a false append and then run the command normal to.
Now you can use save that face2 as dxf with the method IPartDoc::SaveAsDXF2.
Ah, right. You have to get the bodies first, that makes sense