Jump to content

Group Multiple Overlapping objects at once


CoalCad

Recommended Posts

Hello Smart friends,

 

Looking for a lisp where I can select multiple objects and any objects that are overlapping and the same color get grouped together.  

 

I have hundreds of these "arrows" in a dwg that I need individually grouped or block referenced. So they're easier to move and rotate in the future.

 

image.thumb.png.8a1173dc0e2c637c448425baecea2e32.png

 

image.thumb.png.df2f2d961923710ab10b28f254bb1650.png

 

Thanks so much for any advise!!

 

 

 

arrows.dwg

Link to comment
Share on other sites

Various comments.

 

Not sure but Bricscad has Blockify that makes objects into blocks.

 

You could get the outer boundary of the "arrows" which will be a pline and make a block then hatch.

 

Another I think I have is draw an arrow which is 1 object. Just enter like start and end point. 

 

It may be a dynamic block. So just enter a couple of lengths and arrow is drawn.

 

image.png.4817c12f1d0d29408b6cd17f1e52733c.png

 

  • Like 2
Link to comment
Share on other sites

wblock command in AutoCad, as I recall, would be the equivalent.  :beard:

Stands for Write Block I believe.

Lots of available options.

 

image.thumb.png.7f9f9d6ea23d88c9e3a9d25c45d1bd75.png

 

Edited by Dadgad
Link to comment
Share on other sites

If I understand the OP's question correctly, they want an algorithm that detects a recurring set of objects and converts each one to an instance of a block with the proper location, size, and rotation. I don't have the time or the expertise to write that algorithm, but maybe someone else here does.

 

 

Link to comment
Share on other sites

Cyber Angel,

 

You are correct, I have a large drawing that has multiple arrows that have been ungrouped, or exploded.

 

I am looking for an algorithm where I can isolate the layer (with the arrows) and it will individually group (or create a block) of any entity touching or overlapping.

 

Im trying to explain it the best I can.

 

Thanks

 

Link to comment
Share on other sites

Thats what I was hinting you can get the outline of the arrows as a pline and make it a block with a solid hatch, next step would be to find similar arrows can be done as a select 1 by one pretty easy. Doing an auto all say by layer, would be difficult. O yeah a critical step is to rotate the 1st select objects to the X direction.

 

Ok a question how where they made, a way better way is to make correct arrow blocks to start with. If they are made with other lisp code post it and can probably be fix it.

 

Making a block that does not exist, code does exist.

 

Edited by BIGAL
Link to comment
Share on other sites

Not sure how the arrows were made, I'm working in a map thats 15 years old. So when we make a new arrow we just copy and paste.

 

If there's a lisp that can make a arrow in the correct way, quickly I'm all ears.

 

Thanks!

Link to comment
Share on other sites

Ok if happy with make a arrow why would you not just make a block and save that for future use, Arrow1, Arrow2 and so on. You can save each arrow to separate dwg or save in a DWT or use say Lee-mac Steal.lsp to pull from another dwg.

 

Here is how I made an arrow block explained in more detail. 

1st step was I rotated the block to a X axis 

 

image.png.3a5ef15157c994058b6d12b8b0fed723.png

2nd drew a random pline around the arrow 

3rd did BPOLY picking point inside

image.png.af447836a6358ac34090391d592126f8.png

4th moved Last object to right side 

image.png.d3e66a21c189e37bcba5e4850eff9f06.png

5th turned into a block with solid hatch and set objects to byblock. Change size etc if required. I set the insertion point to the mid pt of the start end.

image.thumb.png.5dbd398e1c238228ce3bf959e389a191.png

Edited by BIGAL
Link to comment
Share on other sites

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...