Rusel Posted September 23, 2008 Posted September 23, 2008 Hello, How can we find a user drawn box direction in 3d, then i will continue to draw other boxes following the selected one, just like lego. Thanks, Quote
rocheey Posted September 23, 2008 Posted September 23, 2008 Boxes in acad are just closed polylines, and, as such have a clockwise or counterclockwise direction that the closed loop follows, but as far as "right" or "left" goes, you'd have to have more rules for code to follow. Quote
Rusel Posted September 24, 2008 Author Posted September 24, 2008 I mean 3dsolid boxes with widht, height and depth. Think of 30cmx30cm rectangular section with 300cm length. Length is the direction. How can we find this direction from anyting (lisp, vba, dxf) Regards, Quote
SEANT Posted September 24, 2008 Posted September 24, 2008 If you are dealing with solids that are strictly boxes then the ActiveX (VBA, Visual Lisp, and others) PrincipalDirections property will generate 3 perpendicular axes aligned to the Length, Width and Height. The reason I say “strictly boxes” is that the information is derived by the objects mass distribution. Consequently, if the box has any irregularities, the returned axes may not be aligned squarely with the sides. Also, for what it’s worth, AutoCAD 2009 and .NET offer more access to 3DSolids via the Autodesk.AutoCAD.BoundaryRepresentation Namespace. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.