Jump to content

Lisp routine for trimming everything outside a closed polyline?


EIA

Recommended Posts

image.thumb.png.595695facb35af86ea74ff0120ef116a.png

 

Let´s say I have a square and some lines passing through it, like in the image above. Is there any lisp routine (or maybe autocad command?) out there that lets you select objects and then a polygon so autocad trims everything out of that polygon and leaves only what's inside?

Link to comment
Share on other sites

Autocad EXTRIM command, select polygon and click outside

Link to comment
Share on other sites

Another that is very reliable like Extrim is Cookiecutter.lsp. Sometimes use as Extrim has not worked properly.

 

If you want to automate say pick rectang then outside all done, inside Extrim is a lisp function that can be called from lisp. Pt a hint use extmax.

 

(if (null etrim) (load "extrim.lsp"))
(etrim ent pt)

 

CookieCutter2_v1.0.lsp

Link to comment
Share on other sites

Posted (edited)

I forgot to say that I am currently working on AutoCAD LT, and as it seems you get Extrim from Express Tools which is an AutoCAD Mechanical thing, is there any way to do this anyway for us LT users?

 

edit - does CookieCutter use extrim for anyhting? I only read the first answer when I sent the reply tbh

Edited by EIA
Link to comment
Share on other sites

You can try it, LT doesn't support all LISP functions so it might not work

Link to comment
Share on other sites

Posted (edited)

You need LT2024 at least, but all hope is not lost, manually Trim select the rectang, Enter, then "F" draw a shape around rectang, Enter should be done.

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