VTK
|
tree layout strategy reminiscent of astronomical systems More...
#include <vtkCosmicTreeLayoutStrategy.h>
Public Types | |
typedef vtkGraphLayoutStrategy | Superclass |
![]() | |
typedef vtkObject | Superclass |
![]() | |
typedef vtkObjectBase | Superclass |
Public Member Functions | |
virtual void | PrintSelf (ostream &os, vtkIndent indent) |
virtual int | IsA (const char *type) |
vtkCosmicTreeLayoutStrategy * | NewInstance () const |
virtual void | Layout () |
virtual void | SetSizeLeafNodesOnly (int) |
virtual int | GetSizeLeafNodesOnly () |
virtual void | SizeLeafNodesOnlyOn () |
virtual void | SizeLeafNodesOnlyOff () |
virtual void | SetLayoutDepth (int) |
virtual int | GetLayoutDepth () |
virtual void | SetLayoutRoot (vtkIdType) |
virtual vtkIdType | GetLayoutRoot () |
virtual void | SetNodeSizeArrayName (const char *) |
virtual char * | GetNodeSizeArrayName () |
![]() | |
vtkGraphLayoutStrategy * | NewInstance () const |
void | PrintSelf (ostream &os, vtkIndent indent) |
virtual void | SetGraph (vtkGraph *graph) |
virtual void | Initialize () |
virtual int | IsLayoutComplete () |
virtual void | SetWeightEdges (bool state) |
virtual bool | GetWeightEdges () |
virtual void | SetEdgeWeightField (const char *field) |
virtual char * | GetEdgeWeightField () |
![]() | |
vtkObject * | NewInstance () const |
virtual void | DebugOn () |
virtual void | DebugOff () |
bool | GetDebug () |
void | SetDebug (bool debugFlag) |
virtual void | Modified () |
virtual unsigned long | GetMTime () |
unsigned long | AddObserver (unsigned long event, vtkCommand *, float priority=0.0f) |
unsigned long | AddObserver (const char *event, vtkCommand *, float priority=0.0f) |
vtkCommand * | GetCommand (unsigned long tag) |
void | RemoveObserver (vtkCommand *) |
void | RemoveObservers (unsigned long event, vtkCommand *) |
void | RemoveObservers (const char *event, vtkCommand *) |
int | HasObserver (unsigned long event, vtkCommand *) |
int | HasObserver (const char *event, vtkCommand *) |
void | RemoveObserver (unsigned long tag) |
void | RemoveObservers (unsigned long event) |
void | RemoveObservers (const char *event) |
void | RemoveAllObservers () |
int | HasObserver (unsigned long event) |
int | HasObserver (const char *event) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, bool(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f) |
int | InvokeEvent (unsigned long event, void *callData) |
int | InvokeEvent (const char *event, void *callData) |
int | InvokeEvent (unsigned long event) |
int | InvokeEvent (const char *event) |
![]() | |
const char * | GetClassName () const |
virtual void | Delete () |
virtual void | FastDelete () |
void | Print (ostream &os) |
virtual void | Register (vtkObjectBase *o) |
virtual void | UnRegister (vtkObjectBase *o) |
void | SetReferenceCount (int) |
void | PrintRevisions (ostream &) |
virtual void | PrintHeader (ostream &os, vtkIndent indent) |
virtual void | PrintTrailer (ostream &os, vtkIndent indent) |
int | GetReferenceCount () |
Static Public Member Functions | |
static vtkCosmicTreeLayoutStrategy * | New () |
static int | IsTypeOf (const char *type) |
static vtkCosmicTreeLayoutStrategy * | SafeDownCast (vtkObjectBase *o) |
![]() | |
static int | IsTypeOf (const char *type) |
static vtkGraphLayoutStrategy * | SafeDownCast (vtkObjectBase *o) |
![]() | |
static int | IsTypeOf (const char *type) |
static vtkObject * | SafeDownCast (vtkObjectBase *o) |
static vtkObject * | New () |
static void | BreakOnError () |
static void | SetGlobalWarningDisplay (int val) |
static void | GlobalWarningDisplayOn () |
static void | GlobalWarningDisplayOff () |
static int | GetGlobalWarningDisplay () |
![]() | |
static int | IsTypeOf (const char *name) |
static vtkObjectBase * | New () |
Protected Types | |
enum | RadiusMode { NONE, LEAVES, ALL } |
How are node sizes specified? More... | |
Protected Attributes | |
int | SizeLeafNodesOnly |
int | LayoutDepth |
vtkIdType | LayoutRoot |
char * | NodeSizeArrayName |
![]() | |
vtkGraph * | Graph |
char * | EdgeWeightField |
bool | WeightEdges |
![]() | |
bool | Debug |
vtkTimeStamp | MTime |
vtkSubjectHelper * | SubjectHelper |
![]() | |
vtkAtomicInt32 | ReferenceCount |
vtkWeakPointerBase ** | WeakPointers |
tree layout strategy reminiscent of astronomical systems
This layout strategy takes an input tree and places all the children of a node into a containing circle. The placement is such that each child placed can be represented with a circle tangent to the containing circle and (usually) 2 other children. The interior of the circle is left empty so that graph edges drawn on top of the tree will not obfuscate the tree. However, when one child is much larger than all the others, it may encroach on the center of the containing circle; that's OK, because it's large enough not to be obscured by edges drawn atop it.
Definition at line 43 of file vtkCosmicTreeLayoutStrategy.h.
Definition at line 48 of file vtkCosmicTreeLayoutStrategy.h.
|
protected |
How are node sizes specified?
Definition at line 97 of file vtkCosmicTreeLayoutStrategy.h.
|
protected |
|
protectedvirtual |
|
static |
|
virtual |
|
static |
|
virtual |
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
Reimplemented from vtkGraphLayoutStrategy.
|
static |
|
protectedvirtual |
Reimplemented from vtkGraphLayoutStrategy.
vtkCosmicTreeLayoutStrategy* vtkCosmicTreeLayoutStrategy::NewInstance | ( | ) | const |
|
virtual |
Perform the layout.
Implements vtkGraphLayoutStrategy.
|
virtual |
Should node size specifications be obeyed at leaf nodes only or (with scaling as required to meet constraints) at every node in the tree? This defaults to true, so that leaf nodes are scaled according to the size specification provided, and the parent node sizes are calculated by the algorithm.
|
virtual |
Should node size specifications be obeyed at leaf nodes only or (with scaling as required to meet constraints) at every node in the tree? This defaults to true, so that leaf nodes are scaled according to the size specification provided, and the parent node sizes are calculated by the algorithm.
|
virtual |
Should node size specifications be obeyed at leaf nodes only or (with scaling as required to meet constraints) at every node in the tree? This defaults to true, so that leaf nodes are scaled according to the size specification provided, and the parent node sizes are calculated by the algorithm.
|
virtual |
Should node size specifications be obeyed at leaf nodes only or (with scaling as required to meet constraints) at every node in the tree? This defaults to true, so that leaf nodes are scaled according to the size specification provided, and the parent node sizes are calculated by the algorithm.
|
virtual |
How many levels of the tree should be laid out? For large trees, you may wish to set the root and maximum depth in order to retrieve the layout for the visible portion of the tree. When this value is zero or negative, all nodes below and including the LayoutRoot will be presented. This defaults to 0.
|
virtual |
How many levels of the tree should be laid out? For large trees, you may wish to set the root and maximum depth in order to retrieve the layout for the visible portion of the tree. When this value is zero or negative, all nodes below and including the LayoutRoot will be presented. This defaults to 0.
|
virtual |
What is the top-most tree node to lay out? This node will become the largest containing circle in the layout. Use this in combination with SetLayoutDepth to retrieve the layout of a subtree of interest for rendering. Setting LayoutRoot to a negative number signals that the root node of the tree should be used as the root node of the layout. This defaults to -1.
|
virtual |
What is the top-most tree node to lay out? This node will become the largest containing circle in the layout. Use this in combination with SetLayoutDepth to retrieve the layout of a subtree of interest for rendering. Setting LayoutRoot to a negative number signals that the root node of the tree should be used as the root node of the layout. This defaults to -1.
|
virtual |
Set the array to be used for sizing nodes. If this is set to an empty string or NULL (the default), then all leaf nodes (or all nodes, when SizeLeafNodesOnly is false) will be assigned a unit size.
|
virtual |
Set the array to be used for sizing nodes. If this is set to an empty string or NULL (the default), then all leaf nodes (or all nodes, when SizeLeafNodesOnly is false) will be assigned a unit size.
|
protected |
Recursive routine used to lay out tree nodes. Called from Layout().
|
protected |
Recursive routine that adds each parent node's (x,y) position to its children. This must be done only after all the children have been laid out at the origin since we will not know the parent's position until after the child radii have been determined.
|
protected |
Create an array to hold radii, named appropriately (depends on NodeSizeArrayName) and initialized to either (a) -1.0 for each node or (b) a deep copy of an existing array.
numVertices | The number of vertices on the tree. |
initialValue | The starting value of each node's radius. Only used when inputRadii is NULL. |
inputRadii | Either NULL or the address of another array to be copied into the output array |
The | array of node radii to be set on the output |
|
protected |
Create an array to hold scale factors, named appropriately (depends on NodeSizeArrayName) and initialized to -1.0.
numVertices | The number of vertices on the tree. |
The | array of node scale factors to be set on the output |
|
protected |
Definition at line 143 of file vtkCosmicTreeLayoutStrategy.h.
|
protected |
Definition at line 144 of file vtkCosmicTreeLayoutStrategy.h.
|
protected |
Definition at line 145 of file vtkCosmicTreeLayoutStrategy.h.
|
protected |
Definition at line 146 of file vtkCosmicTreeLayoutStrategy.h.