tesselation: Fix winding order bug

Typo created a couple issues with calculating winding order.
This commit is contained in:
Seth Hillbrand 2018-12-17 17:13:13 -08:00
parent 657bf2b53e
commit 7f5503a783
1 changed files with 2 additions and 2 deletions

View File

@ -310,7 +310,7 @@ private:
auto p1 = aPath.at( i );
auto p2 = aPath.at( ( i + 1 ) < len ? i + 1 : 0 );
sum += ( ( p2.X - p1.X ) * ( p2.Y - p1.Y ) );
sum += ( ( p2.X - p1.X ) * ( p2.Y + p1.Y ) );
}
if( sum <= 0.0 )
@ -352,7 +352,7 @@ private:
VECTOR2D p1 = points.CPoint( i );
VECTOR2D p2 = points.CPoint( i + 1 );
sum += ( ( p2.x - p1.x ) * ( p2.y - p1.y ) );
sum += ( ( p2.x - p1.x ) * ( p2.y + p1.y ) );
}
if( sum > 0.0 )