Fillet multi lines

Fillet multi lines

muhamed_ragab92
Enthusiast Enthusiast
18,892 Views
25 Replies
Message 1 of 26

Fillet multi lines

muhamed_ragab92
Enthusiast
Enthusiast
Please i want lisp or code source to fillet some line with fixed radius ? Anyone can tell me about that
0 Likes
Accepted solutions (1)
18,893 Views
25 Replies
Replies (25)
Message 2 of 26

Kent1Cooper
Consultant
Consultant

The Fillet command itself will do that -- no need for any code.  Explain more about what you need to do [always a good idea for every thread].  An image or sample drawing, preferably with before and after conditions, would be helpful.

Kent Cooper, AIA
Message 3 of 26

john.uhden
Mentor
Mentor

I think that fileting a singular line is impossible.  You can filet adjacent polyline segments, or two lines, or even two polylines (but not always). or even two arcs, or a line and an arc, but not just one line.  As Kent recommended, perhaps before and after images would help explain your intention.

John F. Uhden

0 Likes
Message 4 of 26

Kent1Cooper
Consultant
Consultant

@john.uhden wrote:

I think that fileting a singular line is impossible.  ....


I was assuming the word "line" in the body of the first Post was meant to be plural, as in the Subject line.  But now the Subject line has me wondering whether they really mean Multilines [MLINE command] -- those can't be FILLETed, though for zero radius you can get the same effect with MLEDIT, but they mention a "fixed radius," which I assumed to be other than zero, so I doubt it's about Mlines.

Kent Cooper, AIA
0 Likes
Message 5 of 26

john.uhden
Mentor
Mentor

My apologies for spelling "fillet" incorrectly as "filet."  I'll bet you can guess what we had for Christmas dinner (with brandy shallot sauce).

My steak au poivre is actually better (recipe available upon request with no syntax checking required).

John F. Uhden

0 Likes
Message 6 of 26

muhamed_ragab92
Enthusiast
Enthusiast

this is what i talking about , as this picture in attachments i want do fillet for all this polylines at once with fixed radius

0 Likes
Message 7 of 26

ВeekeeCZ
Consultant
Consultant

@muhamed_ragab92 wrote:

this is what i talking about , as this picture in attachments i want do fillet for all this polylines at once with fixed radius


HERE you have a very nice routine by irneb which does exactly what you want.

0 Likes
Message 8 of 26

muhamed_ragab92
Enthusiast
Enthusiast

i can't use it please can you help me or upload the lisp directly with some tutorial i need this lisp so much for electrical shop drawing 

0 Likes
Message 9 of 26

ВeekeeCZ
Consultant
Consultant

Sure. Hope that helps. 

 

See the SCREENCAST 

Message 10 of 26

muhamed_ragab92
Enthusiast
Enthusiast

thank you so much BeekeeCZ you saved me , i appreciate that 

Message 11 of 26

muhamed_ragab92
Enthusiast
Enthusiast

it worked perfectly with line order , how can i use it with polylines because not working ?

0 Likes
Message 12 of 26

john.uhden
Mentor
Mentor

You have just shown me something I never knew... that picking a selection by fence creates a selection set in the order in which the fence line crosses the objects.

Of course that creates a risk... that if the user selects the first group from the bottom up and the second group from the top down, then the bottom object gets filleted with the top object, etc.  I guess I am suggesting that the selection sets be ordered before processing.  While I'm being so picky, each entity in one set should be checked for parallelity (word?) with its counterpart in the other set.  Also check to see if the user has selected the same objects twice.

 

Unless the user has a $#!+ load of lines to fillet, it seems like you have spent more time writing the code than the user will have saved compared to repeating the fillet command.  In all reality, the user will fill in 8 hours on his time sheet even if he only spent 7.5.  In most places I have worked, the user typically fills in 8 hours even if he didn't come back from lunch.  It really doesn't matter since the project director will modify time sheets to fit the project budget anyway.  My boss, Jose, managed to transfer $38,000 in labor from his failing project to mine.  I ultimately had to fill out a loss report, but he got fired.  Then I inherited his project and had to fill out a loss report for that too.  No problem... they just terminated me too.

John F. Uhden

0 Likes
Message 13 of 26

ВeekeeCZ
Consultant
Consultant

John, yep, I've noticed that too... nice and easy, unfortunately not mine, see post #7.

0 Likes
Message 14 of 26

muhamed_ragab92
Enthusiast
Enthusiast

can i find any update for this lisp with the same feature but with poly lines

0 Likes
Message 15 of 26

Kent1Cooper
Consultant
Consultant

@muhamed_ragab92 wrote:

can i find any update for this lisp with the same feature but with poly lines


It doesn't work with Polylines because it gets its pt1 and pt2 variables in a way that's dependent on the particular way information is stored about Line entities in a selection set using Fence selection specifically.  If the sets of things never overlap, nor one object in a pair cross the line of the other ["virtual" overlap], when you start the command, then it doesn't matter where you pick on them to Fillet them, and this works [for me in Acad2016] for either Lines or Polylines or any combination thereof -- change this line:

 

          pt1 (cadr (cadddr (car (ssnamex ss1 n))))

 

to this:


          pt1 (cdr (assoc 10 (entget en1)))

 

and this line:


          pt2 (cadr (cadddr (car (ssnamex ss2 m))))

 

to this:


          pt2 (cdr (assoc 10 (entget en2)))

 

But if an endpoint of one is in line with the other, as it appears may be the case in the inmost pair in the image in Post 6, it may chop the one down to zero length.  And if there's actual overlap or virtual overlap, it could sometimes keep the wrong end of some objects.

Kent Cooper, AIA
Message 16 of 26

muhamed_ragab92
Enthusiast
Enthusiast
Not working kent either , i dont know what the point the lisp make mulit fillet only with lines to lines not polylines to polyline
0 Likes
Message 17 of 26

Kent1Cooper
Consultant
Consultant

@muhamed_ragab92 wrote:
Not working kent either , i dont know what the point the lisp make mulit fillet only with lines to lines not polylines to polyline

"Not working" is not enough information.  It worked for me.  Post a small sample drawing file in which it doesn't work for you.

Kent Cooper, AIA
0 Likes
Message 18 of 26

muhamed_ragab92
Enthusiast
Enthusiast

that's i talked about kent see , if you have updated for this lisp send it for me please - thanks

Message 19 of 26

Kent1Cooper
Consultant
Consultant
Accepted solution

I'm pretty sure I had tried that modification before and it had worked, but it may have been at a different location in an older version of AutoCAD, if that could be what makes the difference.

 

I just got it to work in Acad2017 by changing this line:

 

    (command "_.FILLET" (list en1 pt1) (list en2 pt2))

 

to this:


    (command "_.FILLET" pt1 pt2)

 

They may have written it to give the Fillet command lists of entity names and points to prevent it from "seeing" some other object that might be at the pick point [a possible problem with the replacement].  I don't know why that works with Lines but not with Polylines.  But in out-in-the-clear situations, it seems to work in minimal testing.

Kent Cooper, AIA
Message 20 of 26

muhamed_ragab92
Enthusiast
Enthusiast

thanks kent - it's worked finally when i replaced that line 

0 Likes