예제 #1
0
 private static void OrientatePolygon(EarPolygon poly)
 {
     poly.CalculateArea();
     if (!poly.IsCCW())
     {
         poly.Reverse(-1);
     }
     for (int i = 0; i < poly.NumChildren(); i++)
     {
         poly[i].CalculateArea();
         if (poly[i].IsCCW())
         {
             poly[i].Reverse(-1);
         }
     }
 }