I don’t know how useful this routine is – but it is still pretty cool.
Someone requested it for a landscaping project and Lee-Mac came to the rescue.
What it does – Lets you draw a spline that intersects itself and then after placing the spline, offset the spline on both sides and trim out the intersections and erase the middle (original spline).
Here’s how:
- SPLIT <enter> to start
- Draw spline that intersects itself
- Specify the offset distance
;LEE-MAC (defun c:Split ( / d e ) (vl-load-com) (setq e (entlast)) (command "_.spline") (while (= 1 (boole 1 1 (getvar 'CMDACTIVE))) (command pause)) (if (and (not (equal e (setq e (entlast)))) (setq d (getdist "\nSpecify Offset: ")) ) (progn (setq e (vlax-ename->vla-object e)) (vlax-invoke e 'offset d) (vlax-invoke e 'offset (- d)) (vla-delete e) ) ) (princ) )
Amazing, great routine, but I make a modificacion in the line _.spline, and modified it to _.pline and then we can make a polyline and when intersect with itself we can have the same result but with straight lines.
Of course all this could not be possible without the genious of Lee Mac
Great suggestion Julio.
And Yes, Lee is awesome!!!