Skip to content

Commit

Permalink
Set the label of Voronoi vertices to the label of their dual triangle.
Browse files Browse the repository at this point in the history
  • Loading branch information
wo80 committed Jan 8, 2024
1 parent 00a35a2 commit d652720
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Triangle/Voronoi/IVoronoiFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ namespace TriangleNet.Voronoi
using TriangleNet.Topology.DCEL;

/// <summary>
/// Factory for Voronoi DCEL datastructure.
/// Factory for Voronoi DCEL data structure.
/// </summary>
public interface IVoronoiFactory
{
Expand Down
2 changes: 0 additions & 2 deletions src/Triangle/Voronoi/StandardVoronoi.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,8 @@

namespace TriangleNet.Voronoi
{
using System.Collections.Generic;
using TriangleNet.Geometry;
using TriangleNet.Tools;
using TriangleNet.Topology.DCEL;

/// <summary>
/// Computing the standard Voronoi diagram of a Delaunay triangulation.
Expand Down
1 change: 1 addition & 0 deletions src/Triangle/Voronoi/VoronoiBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@ protected List<HalfEdge>[] ComputeVertices(Mesh mesh, Vertex[] vertices)

vertex = factory.CreateVertex(pt.x, pt.y);
vertex.id = id;
vertex.label = t.label;

vertices[id] = vertex;
map[id] = new List<HalfEdge>();
Expand Down

0 comments on commit d652720

Please sign in to comment.