public class ClusterHullVisualization.Instance extends AbstractScatterplotVisualization
Modifier and Type | Field and Description |
---|---|
static String |
CLUSTERHULL
Generic tags to indicate the type of element.
|
private StyleResult |
style
The result we visualize
|
proj, rel, sample
context, layer, pendingRedraw, svgp, task
Constructor and Description |
---|
ClusterHullVisualization.Instance(VisualizationTask task)
Constructor
|
Modifier and Type | Method and Description |
---|---|
private void |
addCSSClasses(SVGPlot svgp,
int clusterID,
double opac)
Adds the required CSS-Classes
|
private double |
addRecursively(ArrayList<Vector> hull,
Hierarchy<Cluster<Model>> hier,
Cluster<Model> clus)
Recursively add a cluster and its children.
|
private DoubleObjPair<Polygon> |
buildHullsRecursively(Cluster<Model> clu,
Hierarchy<Cluster<Model>> hier,
Map<Object,DoubleObjPair<Polygon>> hulls)
Recursively step through the clusters to build the hulls.
|
protected void |
redraw()
Perform a full redraw.
|
resultChanged, setupCanvas
contentChanged, destroy, getHeight, getLayer, getWidth, incrementalRedraw, resultAdded, resultRemoved, synchronizedRedraw
public static final String CLUSTERHULL
private StyleResult style
public ClusterHullVisualization.Instance(VisualizationTask task)
task
- VisualizationTaskprotected void redraw()
AbstractVisualization
redraw
in class AbstractVisualization
private DoubleObjPair<Polygon> buildHullsRecursively(Cluster<Model> clu, Hierarchy<Cluster<Model>> hier, Map<Object,DoubleObjPair<Polygon>> hulls)
clu
- Current clusterhier
- Clustering hierarchyhulls
- Hull mapprivate double addRecursively(ArrayList<Vector> hull, Hierarchy<Cluster<Model>> hier, Cluster<Model> clus)
hull
- Hull to add tohier
- Cluster hierarchyclus
- Current clusterprivate void addCSSClasses(SVGPlot svgp, int clusterID, double opac)
svgp
- SVG-Plot