All Activity
- Past hour
-
Need a tool for creating 2d outlines for complex 2d drawings
Dahzee replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
@SLW210 Here you go. https://forum.bricsys.com/discussion/40003/extract-outer-boundary-of-2d-drawing#latest -
Matej88 joined the community
-
Need a tool for creating 2d outlines for complex 2d drawings
SLW210 replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
You have to purchase Civil 3D, Architecture is free with AutoCAD. OP still hasn't stated what CAD they are using. -
Need a tool for creating 2d outlines for complex 2d drawings
SLW210 replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
$119 USD, you get 15 day free trial. Most examples didn't show gaps, but looks like the user guide claims Auto Tolerance and Auto island detection. Could you link the discussion on Bricscad for the OP? - Today
-
AutoCAD suitable laptop for a Mechanical Engineering freshman
SLW210 replied to BenG54's topic in Hardware & Operating Systems
AutoCAD for Windows has more features than AutoCAD for Mac. Compare Features: AutoCAD for Windows against AutoCAD for Mac -
Dahzee started following Need a tool for creating 2d outlines for complex 2d drawings
-
Need a tool for creating 2d outlines for complex 2d drawings
Dahzee replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
I think this is the product BIGAL was referring to.https://engenext.com/pages/egboundary.html I have no affiliation to this product, I just remember seeing it discussed on the Bricscad forum. -
Need a tool for creating 2d outlines for complex 2d drawings
Ankit Pandit replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
Thanks for all the suggestions, really appreciate you taking the time to look into this. I tried a few of the approaches mentioned — they seem to work quite well on cleaner geometry, but in cases like mine with small gaps and more complex connections, I’m still seeing partial or inconsistent boundaries being generated. I’ve attached a simplified sample from one of my project drawings. This represents the kind of geometry I’m dealing with, where standard methods haven’t been giving consistent results. Curious to see how your approaches handle this case. Engine Part Assembly.dwg -
AutoCAD suitable laptop for a Mechanical Engineering freshman
BenG54 posted a topic in Hardware & Operating Systems
Hi everyone, I’m starting my Mechanical Engineering degree this fall. I want to practice AutoCAD a bit before starting and get a basic understanding of it. I want to buy a laptop with a budget of 2,000-3,000 USD. I am currently looking at the MacBook Pro with the M5 chip and 32GB of RAM. I've seen that it recently beaten RTX5090 GPU in blender and I've heard a lot of praise fot Unified Memory, but I’m concerned about how that translates to a professional engineering workflow, specifically for: AutoCAD: I plan to do both 2D drafting and 3D modeling. I know a native macOS version exists, but are there critical missing features compared to the Windows version? I'm thinking about choosing between Mac Pro M5 or a Windows Workstation/Gaming Laptop with a discrete RTX 50-series GPU. I’d love to hear from anyone who has used Macs for AutoCAD or from Windows users who used a discrete GPU setup. Is the M5’s power enough for AutoCAD and if 32GB RAM is good for basic 3D, or should I just stick to a native Windows machine? Thanks in advance! -
BenG54 joined the community
- Yesterday
-
Need a tool for creating 2d outlines for complex 2d drawings
BIGAL replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
@SLW210 CIV3D has Shrinkwrap also. Pity they did not include for plain Acad. If you can work out which dll or ARX may be able to copy correct files to plain Acad. As "TotalBoundary " is no longer available there was a post for a similar product may have been here or at Forums/Autodesk. I remember asking how much but did not get an answer. Try googling. -
Need a tool for creating 2d outlines for complex 2d drawings
mhupp replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
I think I have a solution but would need a test drawing. -
BoryIv joined the community
-
Need a tool for creating 2d outlines for complex 2d drawings
SLW210 replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
I did find this... Lisp to create a boundary around blocks that are not touching. - AutoLISP, Visual LISP & DCL - AutoCAD Forums I should have also mentioned that AutoCAD Architecture FREE toolset has the AECLINEWORKSHRINKWRAP command. -
I moved your thread to the AutoLISP, Visual LISP & DCL Forum. Please post in the correct forum.
-
Need a tool for creating 2d outlines for complex 2d drawings
SLW210 replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
I had to stop on the newer version yesterday due to my "paid" for work, still debugging it. Can you post an actual .dwg of that example for testing? Also, what version of AutoCAD are you using? -
Laki joined the community
-
shishir234 joined the community
-
Aniruddha joined the community
-
Need a tool for creating 2d outlines for complex 2d drawings
Ankit Pandit replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
Here’s a sample of the kind of drawing I’m working with. It has dense geometry with small gaps and overlapping elements, and in cases like this, standard boundary methods don’t always produce consistent results. This is the type of scenario I’ve been trying to handle more reliably. I tried this on one of my actual project drawings. The image shows the input geometry and the output generated using the suggested approach (blue lines indicate the generated boundaries). It works quite well in simpler cases, but for this type of geometry I’m still seeing partial or inconsistent boundaries being created — it’s not forming a single clean outer boundary for the full shape. This is the kind of scenario I’ve been struggling with, especially where there are small gaps or more complex connections. -
Need a tool for creating 2d outlines for complex 2d drawings
Ankit Pandit replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
Thanks for pointing that out, that’s really helpful. I’ve noticed similar behavior as well. I took a look at the Lee Mac outline routine, and it seems to work fine for cleaner cases, but like you mentioned, it still struggles when there are small gaps or slightly messy geometry. That’s been the main challenge on my end — most approaches seem to rely on boundary detection underneath, so they tend to break in those situations. I’ll put together a sample to better show the kind of cases I’m dealing with and what I’ve been testing. -
Not sure using Bricscad if you pick the top of a table the grips will appear, then pick bottom right grip and drag bigger or smaller.
-
Yeah why not, look at date 1992, hopefully works removed some layer setting etc. 34 years ago. Dont think VL existed. Uses Lines etc. ;;;---------------------------------------------------------------------------; ;;; ;;; autodim3.LSP Version 1.0 ;; ;;; by Alan ;;; 1 April 1992 ;;; ;;; DESCRIPTION ;;; AUTOMATICALLY DIMENSIONS ; ;;;---------------------------------------------------------------------------; ; dimmensioning doesnt work if elev wrong ;(command "elev" hts "0") (SETVAR "ELEVATION" 0) (SETVAR "THICKNESS" 0) (defun mmserr (s) (if (/= s "Function cancelled") (princ (strcat "\nError: " s)) ) (setq S nil) (setvar "CMDECHO" cm) (setq *error* olderr) (princ) ) ;;;---------------------------------------------------------------------------; ;;; Main Program. ;;;---------------------------------------------------------------------------; (setq cm (getvar "cmdecho")) (setvar "cmdecho" 1) (setvar "dimdli" 0) (setq exlay (getvar "clayer")) (setq thick (getvar "thickness")) (setq elev (getvar "elevation")) (setq or_pt (list 0.0 0.0 0.0)) (command "osnap" "near") (setvar "thickness" 0) ;(command "elev" hts "0") ; set up dimension locations (setq ppt1 (ENTSEL "\npick first point to dimension :")) (setq tpp1 (entget (car ppt1) ) ) (setq pt1 (cdr (assoc 10 tpp1) ) ) (setq pt2 (cdr (assoc 11 tpp1) ) ) (setq hts (caddr pt1 )) (setvar "elevation" hts) (setq ang1 (angle pt1 pt2)) (setq npt1 (cadr ppt1)) (setq rad (distance pt1 npt1)) (setq ang2 (angle pt1 npt1)) (setq diffang (- ang1 ang2)) (setq dist (* (cos diffang) rad)) (setq apt1 (polar pt1 ang1 dist)) (setq pt5 (getpoint apt1 "\npick second point to dimension :")) ;(setq ss (ssget "c" apt1 pt5)) (setq ss (ssget "F" (list apt1 pt5))) (setvar "osmode" 0) (setq ang3 (angle pt5 apt1)) (setq dist (distance pt5 apt1)) (setq pt3 (getpoint pt5 "\npoint for dimension lines :")) (setq pt4 (getpoint pt5 "\nend point for dimension lines :")) (setq xyang (angle pt5 apt1)) (setq xy (distance apt1 pt5)) (setq pt6 (polar pt4 xyang xy)) (setq pt8 (inters pt1 pt2 pt4 pt6 nil)) (setq yoff (- (cadr pt8)(cadr apt1))) (setq xoff (- (car pt8)(car apt1))) (setq sss nil) (setq tempss nil) (setq dimpt1 nil) (setq dimpt2 nil) (while (setq en (ssname ss 0)) (setq dimpt1 (cdr (assoc 10 (entget en)))) (setq dimpt2 (cdr (assoc 11 (entget en)))) (setq newpt2 (inters pt5 apt1 dimpt1 dimpt2 nil)) (if (/= newpt2 nil) (progn (IF (/= NEWPT2 OLDPT) (progn (setq sss (cons newpt2 sss)) (SETQ OLDPT NEWPT2) ) ) ; CHECK TO SEE IF SAME AS PREV ) ) ; Delete each measured entity from set (ssdel en ss) ) (setq dimno (length sss)) ; loop starts at 0 (setq I 0) (setq maxx (- dimno 1)) ; start loop at dimno -2 (while (/= I maxx) ;(princ I) (setq J 1) (setq K (- dimno I) ) ; loop from 1 to dimno - I (while (/= J K) (setq j3 (LIST 1 1 1)) (setq j4 (LIST 2 2 2)) (setq j2 (nth J sss)) (setq L (- j 1)) (setq j1 (nth L sss)) ; (if (<= (CAR j2) (CAR j1)) (if (<= (distance or_pt j2) (distance or_pt j1)) (progn ; (princ "sorting ") (setq temp j2) (setq temp2 j1) (setq sss (subst j3 j2 sss)) (setq sss (subst j4 j1 sss)) (setq sss (subst J2 j4 sss)) (setq sss (subst J1 j3 sss)) ) ) (setq j (1+ j)) ) (setq i (+ I 1)) ) (PRINC "\nNow Dimensioning ") ;now plot dimmesions ; now dimension draw first to then loop for rest (setq d1 (nth 0 sss)) (setq d4 (list (+ (car d1) xoff)(+ (cadr d1) yoff))) (setq d2 (nth 1 sss)) (setq d5 (list (+ (car d2) xoff)(+ (cadr d2) yoff))) (PRINC "1") (command "DIM" "aligned" d4 d5 pt3 "") (setq x 2) (while (/= x dimno) (setq d3 (nth x sss)) (setq d6 (list (+ (car d3) xoff)(+ (cadr d3) yoff))) (PRINC "2") ; (command "diM" "continue" d6 "") (command "continue" d6 "") (setq x (+ x 1)) ) (PRINC "3") (command "exit") (setvar "CMDECHO" cm) (setvar "clayer" exlay) (setvar "elevation" elev) (setvar "thickness" thick) (setq ss nil) (princ)
-
GDOR32 joined the community
-
vicsrc joined the community
-
tombu started following Add to the code the ability to create layouts for non-standard formats
-
Add to the code the ability to create layouts for non-standard formats
tombu replied to Nikon's topic in AutoLISP, Visual LISP & DCL
Template drawing are the key to making AutoCAD simple. I always used Lee Mac's Steal from Drawing lisp to add Blocks, Layers, Linetypes, Dimension Styles, Text Styles, Table Styles, MLeader Styles, MLine Styles, Layouts, Page Setups, User Coordinate Systems, Named Groups, Views, Layer States, Scales, Materials, Named Viewports, Drawing Properties and Custom Properties All you need is to manage a template file with everything you need and you can add any and all you want to the current drawing with a single macro. Thanks Lee! - Last week
-
Might be on a locked layer? (if (setq ss (ssget "_:L"))) ;ignore locked layers if this is in paper space is it in a view port you would have to select the whole viewport not just around the table.
-
Hi mhupp, I select them all from top right to botom left , and shows me that tablew are selected but dont move with the stretch like all the other lines or blocks, and I don't want to explode them . Thanks
-
mhupp started following Need a tool for creating 2d outlines for complex 2d drawings and How to update stretch command ?
-
@SLW210 might move this to Lisp area. Never used ZWCAD but sometimes stretch selection has to fully enclose some items like blocks or tables for it to move with the command. you can't just pick up the bottom corner or left side.
-
It's taken you 6 years to realise I cheat!! Good point, add (vl-load-com) in just before or after the (defun c ... line (edited above)
-
Need a tool for creating 2d outlines for complex 2d drawings
mhupp replied to Ankit Pandit's topic in AutoLISP, Visual LISP & DCL
I updated something that makes multiple boundaries but cant find the post right now. doesn't work with gaps so idk if its something you could use. lee mac has an outline but also don't think it works with gaps. https://lee-mac.com/outlineobjects.html -
If @Steven P is going to cheat an use Lee Mac Functions! might want to add (vl-load-com) to avoid errors if they don't have it loaded since it using vlax fuctions.
-
Hi, I am using ZWCAD. I have a problem with stretch command, I don't remember if Autocad have the same problem. I have some Templates for my drawings. The problem is when the Template include Tables , not explode tables but ACAD_TABLES when I do stretch to the template the Tables stay back don't follow the movement. I don't want to strech them just follow all the other lines. I try this but is not working. Any other ideas? (defun c:S (/ oldortho) (setq oldortho (getvar "ORTHOMODE")) (setvar "ORTHOMODE" 1) (while t (if (setq ss (ssget '((0 . "*")))) (progn (command "_.STRETCH" ss "" ) ) (progn (princ "\nΤέλος.") (setvar "ORTHOMODE" oldortho) (exit) ) ) ) ) Thanks
-
Steven P started following Auto dimension lisp
-
A slight variation on MHUPPS (vl-load-com) (defun c:ADIM (/ pt1 pt2 MyLine MySS acount MyIntersect MyDistance MyDistances pta ptb) (defun LM:intersections ( ob1 ob2 mod / lst rtn ) ;; See Lee Mac website. Get intersection list (if (and (vlax-method-applicable-p ob1 'intersectwith) (vlax-method-applicable-p ob2 'intersectwith) (setq lst (vlax-invoke ob1 'intersectwith ob2 mod)) ) (repeat (/ (length lst) 3) (setq rtn (cons (list (car lst) (cadr lst) (caddr lst)) rtn) lst (cdddr lst) ) ) ) (reverse rtn) ) (command "line" (setq pt1 (getpoint)) pause "") ; Draw reference line. Mod to polyline possible (setq MyLine (entlast)) ; Reference line entity name (setq pt2 (getvar 'lastpoint)) ; pt2 of reference line (setq MySS (ssget "_f" (list pt1 pt2) '( (-4 . "<NOT")(0 . "*DIM*") (-4 . "NOT>") ;Not Dims (-4 . "<NOT")(0 . "*TEXT*")(-4 . "NOT>") ;Not Text ))) ; Selection set crossing reference line (fence). Add filters (setq acount 0) ; a counter (while (< acount (sslength MySS)) ; Loop through selection set (if (setq MyIntersect (LM:intersections (vlax-ename->vla-object MyLine)(vlax-ename->vla-object (ssname MySS acount)) acextendnone )) ; get the intersection points, reference line, selection set items (progn (foreach n MyIntersect (setq MyDistance (distance pt1 n)) ; get the distance SS item, start reference line (setq MyDistances (cons (cons MyDistance (list n)) MyDistances)) ;; add the intersection & point to a list ) ; end foreach ) ; end progn ) ; end if intersections (setq acount (+ acount 1)) ; increase counter ) ; end while ; end loop (command "erase" MyLine "") ; erase reference line (setq MyDistances (vl-sort MyDistances (function (lambda (pta ptb) (< (car pta)(car ptB) ))) )) ; sort by distance (setq acount 0) (while (< (+ acount 1) (length MyDistances)) (setq p1 (car (cdr (nth acount MyDistances)))) (setq p2 (car (cdr (nth (+ acount 1) MyDistances)))) (setq mid (mapcar '/ (mapcar '+ p1 p2) '(2 2 2))) ; ripped of MHUPP (setq p3 (mapcar '+ mid '(0.0 2.0 0.0))) ;adj 2.0 for offset. ; ripped of MUPP (command "_.DIMLINEAR" p1 p2 p3) ; Ripped of MHUPP (setq acount (+ acount 1)) ) ; end while (princ) ) Edit: Corrected for polylines crossing reference line more than once
