private void Create() { if (_subdiv != null) { return; } Envelope siteEnv = DelaunayTriangulationBuilder.Envelope(_siteCoords); _diagramEnv = siteEnv; // add a buffer around the final envelope double expandBy = Math.Max(_diagramEnv.Width, _diagramEnv.Height); _diagramEnv.ExpandBy(expandBy); if (_clipEnv != null) { _diagramEnv.ExpandToInclude(_clipEnv); } var vertices = DelaunayTriangulationBuilder.ToVertices(_siteCoords); _subdiv = new QuadEdgeSubdivision(siteEnv, _tolerance); IncrementalDelaunayTriangulator triangulator = new IncrementalDelaunayTriangulator(_subdiv); triangulator.InsertSites(vertices); }
private void Create() { if (_subdiv != null) { return; } var siteEnv = Envelope(_siteCoords); var vertices = ToVertices(_siteCoords); _subdiv = new QuadEdgeSubdivision(siteEnv, _tolerance); IncrementalDelaunayTriangulator triangulator = new IncrementalDelaunayTriangulator(_subdiv); triangulator.InsertSites(vertices); }
private void Create() { if (_subdiv != null) return; Envelope siteEnv = DelaunayTriangulationBuilder.Envelope(_siteCoords); _diagramEnv = siteEnv; // add a buffer around the final envelope double expandBy = Math.Max(_diagramEnv.Width, _diagramEnv.Height); _diagramEnv.ExpandBy(expandBy); if (_clipEnv != null) _diagramEnv.ExpandToInclude(_clipEnv); var vertices = DelaunayTriangulationBuilder.ToVertices(_siteCoords); _subdiv = new QuadEdgeSubdivision(siteEnv, _tolerance); IncrementalDelaunayTriangulator triangulator = new IncrementalDelaunayTriangulator(_subdiv); triangulator.InsertSites(vertices); }
private void Create() { if (_subdiv != null) return; var siteEnv = Envelope(_siteCoords); var vertices = ToVertices(_siteCoords); _subdiv = new QuadEdgeSubdivision(siteEnv, _tolerance); IncrementalDelaunayTriangulator triangulator = new IncrementalDelaunayTriangulator(_subdiv); triangulator.InsertSites(vertices); }