Skip to content

Voxel8/Voronoi.jl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status

Build status

Voronoi

A wrapper for the Boost Voronoi library, allowing creation of Voronoi diagrams for points and straight line segments.

The only function in the library is get_edges which takes a vector of Points and a vector of Segments with integer coordinates.

It returns Vector{Vertex}, Vector{Edge}. The vertices have Float64 coordinates.

Edge.start_index and Edge.end_index are indices into the vertex vector. They can be 0 if the edge is unbounded at that end.

Edge.site1 and Edge.site2 are indices into the array of points, followed by the array of segments. I.e. if there are 3 points and 5 segments, site1 = 6 means that the first Voronoi region of this edge belongs to the third segment.

Edge.is_primary specifies whether the edge is a boundary between two primary regions (points or segments). An edge that is not primary is a boundary between a segment and one of its own endpoints (See Voronoi basic tutorial).

License

Available under the Boost Software License - Version 1.0. See: LICENSE.md.

About

Julia wrapper for Boost voronoi library.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •