From a1cd73e73041a7463da175038eccb4619d2edd1d Mon Sep 17 00:00:00 2001 From: Jon Evans Date: Thu, 23 May 2024 11:21:18 -0400 Subject: [PATCH] Fix bad clearance logic in cecc1a2f --- libs/kimath/src/geometry/shape_collisions.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/libs/kimath/src/geometry/shape_collisions.cpp b/libs/kimath/src/geometry/shape_collisions.cpp index a911601741..96c94e1362 100644 --- a/libs/kimath/src/geometry/shape_collisions.cpp +++ b/libs/kimath/src/geometry/shape_collisions.cpp @@ -651,11 +651,10 @@ static inline bool Collide( const SHAPE_ARC& aA, const SHAPE_SEGMENT& aB, int aC aA.TypeName(), aB.TypeName() ) ); - bool rv = aA.Collide( aB.GetSeg(), aClearance + aA.GetWidth() / 2 + aB.GetWidth() / 2, - aActual, aLocation ); + bool rv = aA.Collide( aB.GetSeg(), aClearance + aB.GetWidth() / 2, aActual, aLocation ); if( rv && aActual ) - *aActual = std::max( 0, *aActual - aA.GetWidth() / 2 ); + *aActual = std::max( 0, *aActual - aB.GetWidth() / 2 ); return rv; }