TheSwamp

CAD Forums => CAD General => Topic started by: HasanCAD on July 11, 2020, 09:24:40 AM

Title: Fillet goes in a wrong direction
Post by: HasanCAD on July 11, 2020, 09:24:40 AM
As image
attached CAD file
Title: Re: Fillet goes in a wrong direction
Post by: Crank on July 11, 2020, 10:59:03 AM
If there is a polyline involved, you can reverse the direction of the polyline that misbehaves. Right-click on the misbehaving polyline and select Polyline > Reverse (or type Reverse). Then fillet again.
Title: Re: Fillet goes in a wrong direction
Post by: dtkell on July 14, 2020, 10:37:58 AM
If there is a polyline involved, you can reverse the direction of the polyline that misbehaves. Right-click on the misbehaving polyline and select Polyline > Reverse (or type Reverse). Then fillet again.
Good point.

It also can happen when filleting to an arc where you need to set to No Trim and trim manually.
Title: Re: Fillet goes in a wrong direction
Post by: tombu on July 14, 2020, 01:08:14 PM
roy_043 posted a solution: http://www.theswamp.org/index.php?topic=55803.msg598594#msg598594
Fillet radius has to be preset, simply select the line to on whichever side you want the fillet on.
Title: Re: Fillet goes in a wrong direction
Post by: BIGAL on July 21, 2020, 02:27:34 AM
A custom double arc would be appropriate even if the 90 line is longer pick near correct end so it trims at crosspoint.

The longer "T" line needs a break then run fillet twice very easy. Then a line or pline will work.

The link is for more 1 arc but which direction.

The intersectwith method is best as handles plines.

Code: [Select]
(setq oldsnap (getvar 'osmode))
(setvar 'osmode 0)
(setvar 'filletrad (getreal "\nEnter radius"))
(setq ent1 (entsel "\npick square off line near start end"))
(setq pt1 (cadr ent1))
(setq ent2 (entsel "\npick main line"))
(setq obj1 (vlax-ename->vla-object (car ent1)))
(setq obj2 (vlax-ename->vla-object (car ent2)))
(setq pt2 (vlax-invoke obj1 'intersectwith obj2 acExtendBoth))
; need a check here line pline
(setq start (vlax-get Obj2 'StartPoint))
(setq end (vlax-get Obj2 'EndPoint))
(setq pt3 (polar pt2 (angle start end) 0.05))
(setq pt4 (polar pt2 (- (angle start end) pi) 0.05))
(command "break" pt3 pt2)
(setq ent3 (entlast))
(command "fillet" pt1 ent2)
(command "fillet" pt1 ent3)

(setvar 'osmode oldsnap)