Class VoroNode
java.lang.Object
com.treemap.swing.originalfastvoronoi.VoroNode
- All Implemented Interfaces:
VoroCellObject
Represents a node in the Voronoi Treemap hierarchy. This node is put into the computation queue.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
void
void
int[]
int
int
getSite()
double
double
void
boolean
void
iterate()
void
Scales the relative vectors of the child nodes to the size of our current polygon.void
setChildren
(ArrayList<VoroNode> children) void
setHeight
(int height) void
setNodeID
(int nodeID) void
void
setPolygon
(PolygonSimple polygon) void
setRelativeVector
(Point2D relativeVector) void
void
setToConsider
(boolean toConsider) void
setTreemap
(VoronoiTreemap treemap) void
setVoroPolygon
(PolygonSimple polygon) void
setWantedPercentage
(double percentage) void
setWeight
(double weight)
-
Constructor Details
-
VoroNode
public VoroNode(int nodeID) -
VoroNode
public VoroNode(int nodeID, int numberChildren)
-
-
Method Details
-
calculateWeights
public void calculateWeights() -
setNodeID
public void setNodeID(int nodeID) -
getNodeID
public int getNodeID() -
setParent
-
getParent
-
setChildren
-
getChildren
-
setPolygon
-
getPolygon
-
setToConsider
public void setToConsider(boolean toConsider) -
isToConsider
public boolean isToConsider() -
setWantedPercentage
public void setWantedPercentage(double percentage) -
getWantedPercentage
public double getWantedPercentage() -
addChild
-
iterate
public void iterate() -
scaleRelativeVectors
public void scaleRelativeVectors()Scales the relative vectors of the child nodes to the size of our current polygon. Doing this helps to preserve the mental map. -
increasePercentageDirectly
public void increasePercentageDirectly() -
decreasePercentage
public void decreasePercentage() -
setHeight
public void setHeight(int height) -
getHeight
public int getHeight() -
setWeight
public void setWeight(double weight) -
getWeight
public double getWeight() -
setSite
-
getSite
-
setTreemap
-
getTreemap
-
setRelativeVector
-
getRelativeVector
-
doFinalWork
public void doFinalWork()- Specified by:
doFinalWork
in interfaceVoroCellObject
-
setVoroPolygon
- Specified by:
setVoroPolygon
in interfaceVoroCellObject
-
getChildrenIDs
public int[] getChildrenIDs() -
getChildrenPolygons
-