Corrected SHAPE_POLY_SET::pointInPolygon() return value.

This commit is contained in:
Tomasz Wlostowski 2015-08-03 10:45:30 +02:00 committed by Maciej Suminski
parent 7b39b1bfc4
commit 037772fe3c
1 changed files with 1 additions and 1 deletions

View File

@ -701,7 +701,7 @@ bool SHAPE_POLY_SET::pointInPolygon( const VECTOR2I& aP, const SHAPE_LINE_CHAIN&
(int64_t)( ipNext.x - aP.x ) * (int64_t)( ip.y - aP.y );
if( !d )
return -1;
return true;
if( ( d > 0 ) == ( ipNext.y > ip.y ) )
result = 1 - result;