TheSwamp

CAD Forums => CAD General => Topic started by: Karol on May 08, 2019, 08:31:17 PM

Title: Can't trim 2 splines
Post by: Karol on May 08, 2019, 08:31:17 PM
On R13, these 2 splines (one is a straight line) can't be trimmed with one another
Title: Re: Can't trim 2 splines
Post by: ribarm on May 09, 2019, 01:19:12 AM
Planarize spline and line and then check for intersection using intersectwith method... If it returns point coordinates, it means there is intersection... Then, I suppose trimming will be possible - not tested though...

Intersectwith method :
Code: [Select]
(vl-load-com)
(vlax-invoke (vlax-ename->vla-object (car (entsel "\nPick LINE..."))) 'intersectwith (vlax-ename->vla-object (car (entsel "\nPick SPLINE..."))) acextendnone)

The main problem here is how to planarize 3D entity - SPLINE with 1D entity - LINE... Well You could try using OSNAPS : command MOVE, pick point on SPLINE with "_nea" OSNAP and as destination point pick point on LINE with "_nea" OSNAP... If SPLINE is 2D they will be planarized, but if it's 3D, I suppose you could be able to trim one side from intersection point and the other side should remain IMHO...

HTH., M.R.
Title: Re: Can't trim 2 splines
Post by: mjfarrell on May 09, 2019, 10:13:36 AM
try to FLATTEN them