Jump to content

Recommended Posts

Posted

I am trying to create a library of 3d pipes and fitting for a job at work. The creation of all pipes and fittings is easy and they have then been grouped into a pipe diameter block. I would like to align the block to the previous pipe (or joint) on insertion using multple insertion points.

My preference is to do this without lisp or vba as I am very limited in this area. But if there is no other way I may have to.

I am also wanting to stretch the straight pipe to fit between joints can this be done dynamically to a 3d block.

I hope someone can help.

Posted

The first part of your question is the hardest. If I was trying to automatically insert and align to an object I would alter my UCS (object UCS would probably be best). This would get the orientation correct. Then just make sure the insertion point of the block matches a reference point on the receiving object. Alternatively there are some lisp routines around that will align and move in one command but you would have to search for one as I don't have any. If you cretae a dynamic blocks you can an align option but this would be a post insertion option rather than automatic.

 

To stretch a block you have to use dynamic blocks. When you create the block tick the box that says 'open in block editor' but (and it's a big but) I don't believe the stretch works on 3d objects. However if your pipe was created by drawing a circle and 'extrude' you can stretch it out to what ever you want without creating a block.

Posted

Creating the pipes as cylinders is your best bet for usability in AutoCAD.

Posted

A bit later you will want the ability to extract the pipe's lengths and possibly their elevations (by this I mean levels i.e. Invert Levels, center levels etc). Below is a quote from Tony Tanzillo about the difficulty of getting such values from AutoCAD:

 

"3D Solid functionality and specifically, API support is

deliberately hobbled or disabled in AutoCAD to avoid the possiblity that it would be use to create produts that compete with Inventor

or other 'model-based' offerings.

 

You should consider 3D support in AutoCAD as essentially

being a 'teaser' or embedded demo of 3D modeling functionality

found in ohter products."

 

 

 

I'm a member of the Autodesk Developer Network and have posed the question of extracting data from cylinders. I was told it is possible using Brep but I haven't yet got it to work. Quote from my query:

 

 

"the height property of a Solid3d is not exposed. You should be able to get this by retrieving a point on each top and bottom face, then projecting the difference vector against a perpendicular vector for example, using the BRep API."

 

 

---------------------------------------

 

 

3D AutoCAD Pipework – http://www.HerculeDesign.com

Posted

Bogbadbob and hugh thanks for your help ucs object almost works but due to the bends in the pipes the block still inserts in relation to the x axis at the start of the block. Extruding and using cylinders for the pipe doesn't work as the pipe has flanged or socket ends as part of the block. Therefore the manipulation of the cylinder does not occur.

Again thanks for the help, any other advice is always appreciated.

Posted

Based on my interpretation of the problem, I think the various APIs have tools that could simplify that type of task.

 

Post some samples of the blocks – that may help generate interest within the numerous coders that frequent this site. I could probably offer some VBA suggestions, but given its indefinite future, it may be best to avoid VB based solutions (Unless VB.NET is an option).

Posted

I have attached 2 of the 80mm blocks we are using. The intent is to insert these and other blocks along a 3d alignment string and aligning on insertion even sizing the straight pipe.

Not sure if I am trying to reinvent the wheel, but trying to make this as easy for the user as possible.

FPIPE080.dwg

FB11080.dwg

Posted

I’m not sure how much capability Dynamic Blocks have with stretch parameters on 3d elements. I do think the process could be automated with one of the previously mentioned APIs, though it would be a fairly complex coding effort; especially if automatic bill of material generation was an ultimate goal.

 

On a more basic level, assembly can be assisted with a bit of Block rework, and some simple scripts. For example, the blocks in the attached have points (nodes) incorporated to allow for orientation with these:

 

C^C^_Ucs;3;nod;\nod;\nod;\.-insert;FB11080;0,0,0;1;;0;

 

C^C^_Ucs;3;nod;\nod;\nod;\.-insert;FPIPE080;0,0,0;1;;0;

PipeTester.dwg

Posted

Seant, thanks for that. How is the order of the points identified. Is it just the order they were inserted that specifies the priority.

Thanks again.

Posted

Seant, does the block have to be orientated along the z axis.

Posted

Seant I have tried doing this with the remainder of this block set and I am coming up empty. What process did you use to set this up.

Posted

The process would benefit from a Block Library setup where each block is in its own file (as opposed to multiple blocks in the same file).

 

The general orientation of each block requires the mating surface flat to the WCS’s XY plane, one hole aligned to 0,0,0, an opposite hole aligned with the X axis. See attached.

 

I added the points because of the spacing between holes.

 

The order of picks during insertion should be as listed in the attached sample.

orientation.dwg

Posted

I don't mean to be greedy, but has any one got further info re this subject.

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...