SHAPE_ARC::Collide(): fix incorrect returned position of colliding point.
The previously returned position had nothing to do with the colliding point.
This commit is contained in:
parent
9a8a25a596
commit
ca2dde23d0
|
@ -404,7 +404,7 @@ bool SHAPE_ARC::Collide( const VECTOR2I& aP, int aClearance, int* aActual,
|
||||||
if( dist <= minDist )
|
if( dist <= minDist )
|
||||||
{
|
{
|
||||||
if( aLocation )
|
if( aLocation )
|
||||||
*aLocation = ( aP + GetCenter() ) / 2;
|
*aLocation = nearestPt;
|
||||||
|
|
||||||
if( aActual )
|
if( aActual )
|
||||||
*aActual = std::max( 0, dist - m_width / 2 );
|
*aActual = std::max( 0, dist - m_width / 2 );
|
||||||
|
|
Loading…
Reference in New Issue