void Triangulate(int n, double size) { var random = new Random(n); var w = n * size; var cdt = new Cdt(PointsForCdt(random, n, w), null, SegmentsForCdt(w).ToList()); cdt.Run(); #if TEST_MSAGL && TEST_MSAGL CdtSweeper.ShowFront(cdt.GetTriangles(), null, null, null); #endif }
static void Triangulation(bool reverseX) { #if TEST_MSAGL DisplayGeometryGraph.SetShowFunctions(); #endif int r = reverseX ? -1 : 1; IEnumerable <Point> points = Points().Select(p => new Point(r * p.X, p.Y)); var poly = (Polyline)RussiaPolyline.GetTestPolyline().ScaleFromOrigin(1, 1); var cdt = new Cdt(null, new[] { poly }, null); cdt.Run(); #if TEST_MSAGL CdtSweeper.ShowFront(cdt.GetTriangles(), null, null, null); #endif }