C# Class VoronoiDemo, Unity-Voronoi

Inheritance: Editor
显示文件 Open project: jesta88/Unity-Voronoi Class Usage Examples

Public Properties

Property Type Description
bounds Bounds
chunkObj GameObject
graph VoronoiGraph
numSites int

Public Methods

Method Description
Compute ( List sites ) : void
CreateChunks ( ) : void
CreateSites ( bool clear = true, bool relax = false, int relaxCount = 2 ) : void
OnDrawGizmos ( ) : void
RelaxSites ( int iterations ) : void
Start ( ) : void
Update ( ) : void

Private Methods

Method Description
CellArea ( Voronoi, cell ) : float
CellCentroid ( Voronoi, cell ) : Point
Distance ( Point a, Point b ) : float

Method Details

Compute() public method

public Compute ( List sites ) : void
sites List
return void

CreateChunks() public method

public CreateChunks ( ) : void
return void

CreateSites() public method

public CreateSites ( bool clear = true, bool relax = false, int relaxCount = 2 ) : void
clear bool
relax bool
relaxCount int
return void

OnDrawGizmos() public method

public OnDrawGizmos ( ) : void
return void

RelaxSites() public method

public RelaxSites ( int iterations ) : void
iterations int
return void

Start() public method

public Start ( ) : void
return void

Update() public method

public Update ( ) : void
return void

Property Details

bounds public_oe property

public Bounds bounds
return Bounds

chunkObj public_oe property

public GameObject chunkObj
return GameObject

graph public_oe property

public VoronoiGraph graph
return VoronoiGraph

numSites public_oe property

public int numSites
return int