vtkPropAssembly Class Reference

#include <vtkPropAssembly.h>

Inheritance diagram for vtkPropAssembly:

Inheritance graph
[legend]
Collaboration diagram for vtkPropAssembly:

Collaboration graph
[legend]

List of all members.


Detailed Description

create hierarchies of props

vtkPropAssembly is an object that groups props and other prop assemblies into a tree-like hierarchy. The props can then be treated as a group (e.g., turning visibility on and off).

A vtkPropAssembly object can be used in place of an vtkProp since it is a subclass of vtkProp. The difference is that vtkPropAssembly maintains a list of other prop and prop assembly instances (its "parts") that form the assembly. Note that this process is recursive: you can create groups consisting of prop assemblies to arbitrary depth.

vtkPropAssembly's and vtkProp's that compose a prop assembly need not be added to a renderer's list of props, as long as the parent assembly is in the prop list. This is because they are automatically renderered during the hierarchical traversal process.

Warning:
vtkPropAssemblies can consist of hierarchies of assemblies, where one actor or assembly used in one hierarchy is also used in other hierarchies. However, make that there are no cycles (e.g., parent->child->parent), this will cause program failure.
See also:
vtkProp3D vtkActor vtkAssembly vtkActor2D vtkVolume
Examples:
vtkPropAssembly (Examples)
Tests:
vtkPropAssembly (Tests)

Definition at line 54 of file vtkPropAssembly.h.


Public Types

typedef vtkProp Superclass

Public Member Functions

virtual const char * GetClassName ()
virtual int IsA (const char *type)
void PrintSelf (ostream &os, vtkIndent indent)
void AddPart (vtkProp *)
void RemovePart (vtkProp *)
vtkPropCollectionGetParts ()
virtual int HasTranslucentPolygonalGeometry ()
void ReleaseGraphicsResources (vtkWindow *)
double * GetBounds ()
void ShallowCopy (vtkProp *Prop)
unsigned long int GetMTime ()
void BuildPaths (vtkAssemblyPaths *paths, vtkAssemblyPath *path)
int RenderOpaqueGeometry (vtkViewport *ren)
virtual int RenderTranslucentPolygonalGeometry (vtkViewport *ren)
virtual int RenderVolumetricGeometry (vtkViewport *ren)
int RenderOverlay (vtkViewport *ren)
void InitPathTraversal ()
vtkAssemblyPathGetNextPath ()
int GetNumberOfPaths ()

Static Public Member Functions

static int IsTypeOf (const char *type)
static vtkPropAssemblySafeDownCast (vtkObject *o)
static vtkPropAssemblyNew ()

Protected Member Functions

 vtkPropAssembly ()
 ~vtkPropAssembly ()
void UpdatePaths ()

Protected Attributes

vtkPropCollectionParts
double Bounds [6]
vtkTimeStamp PathTime

Member Typedef Documentation

Reimplemented from vtkProp.

Definition at line 57 of file vtkPropAssembly.h.


Constructor & Destructor Documentation

vtkPropAssembly::vtkPropAssembly (  )  [protected]

vtkPropAssembly::~vtkPropAssembly (  )  [protected]


Member Function Documentation

virtual const char* vtkPropAssembly::GetClassName (  )  [virtual]

Reimplemented from vtkProp.

static int vtkPropAssembly::IsTypeOf ( const char *  name  )  [static]

Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h.

Reimplemented from vtkProp.

virtual int vtkPropAssembly::IsA ( const char *  name  )  [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 vtkTypeRevisionMacro found in vtkSetGet.h.

Reimplemented from vtkProp.

static vtkPropAssembly* vtkPropAssembly::SafeDownCast ( vtkObject o  )  [static]

Reimplemented from vtkProp.

void vtkPropAssembly::PrintSelf ( ostream &  os,
vtkIndent  indent 
) [virtual]

Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from vtkProp.

static vtkPropAssembly* vtkPropAssembly::New (  )  [static]

Create with an empty parts list.

Reimplemented from vtkObject.

void vtkPropAssembly::AddPart ( vtkProp  ) 

Add a part to the list of parts.

void vtkPropAssembly::RemovePart ( vtkProp  ) 

Remove a part from the list of parts,

vtkPropCollection* vtkPropAssembly::GetParts (  ) 

Return the list of parts.

int vtkPropAssembly::RenderOpaqueGeometry ( vtkViewport ren  )  [virtual]

Render this assembly and all its parts. The rendering process is recursive. The parts of each assembly are rendered only if the visibility for the prop is turned on.

Reimplemented from vtkProp.

virtual int vtkPropAssembly::RenderTranslucentPolygonalGeometry ( vtkViewport ren  )  [virtual]

Render this assembly and all its parts. The rendering process is recursive. The parts of each assembly are rendered only if the visibility for the prop is turned on.

Reimplemented from vtkProp.

virtual int vtkPropAssembly::RenderVolumetricGeometry ( vtkViewport ren  )  [virtual]

Render this assembly and all its parts. The rendering process is recursive. The parts of each assembly are rendered only if the visibility for the prop is turned on.

Reimplemented from vtkProp.

int vtkPropAssembly::RenderOverlay ( vtkViewport ren  )  [virtual]

Render this assembly and all its parts. The rendering process is recursive. The parts of each assembly are rendered only if the visibility for the prop is turned on.

Reimplemented from vtkProp.

virtual int vtkPropAssembly::HasTranslucentPolygonalGeometry (  )  [virtual]

Does this prop have some translucent polygonal geometry?

Reimplemented from vtkProp.

void vtkPropAssembly::ReleaseGraphicsResources ( vtkWindow  )  [virtual]

Release any graphics resources that are being consumed by this actor. The parameter window could be used to determine which graphic resources to release.

Reimplemented from vtkProp.

double* vtkPropAssembly::GetBounds (  )  [virtual]

Get the bounds for this prop assembly as (Xmin,Xmax,Ymin,Ymax,Zmin,Zmax). May return NULL in some cases (meaning the bounds is undefined).

Reimplemented from vtkProp.

void vtkPropAssembly::ShallowCopy ( vtkProp Prop  )  [virtual]

Shallow copy of this vtkPropAssembly.

Reimplemented from vtkProp.

unsigned long int vtkPropAssembly::GetMTime (  )  [virtual]

Override default GetMTime method to also consider all of the prop assembly's parts.

Reimplemented from vtkObject.

void vtkPropAssembly::InitPathTraversal (  )  [virtual]

Methods to traverse the paths (i.e., leaf nodes) of a prop assembly. These methods should be contrasted to those that traverse the list of parts using GetParts(). GetParts() returns a list of children of this assembly, not necessarily the leaf nodes of the assembly. To use the methods below - first invoke InitPathTraversal() followed by repeated calls to GetNextPath(). GetNextPath() returns a NULL pointer when the list is exhausted. (See the superclass vtkProp for more information about paths.)

Reimplemented from vtkProp.

vtkAssemblyPath* vtkPropAssembly::GetNextPath (  )  [virtual]

Methods to traverse the paths (i.e., leaf nodes) of a prop assembly. These methods should be contrasted to those that traverse the list of parts using GetParts(). GetParts() returns a list of children of this assembly, not necessarily the leaf nodes of the assembly. To use the methods below - first invoke InitPathTraversal() followed by repeated calls to GetNextPath(). GetNextPath() returns a NULL pointer when the list is exhausted. (See the superclass vtkProp for more information about paths.)

Reimplemented from vtkProp.

int vtkPropAssembly::GetNumberOfPaths (  )  [virtual]

Methods to traverse the paths (i.e., leaf nodes) of a prop assembly. These methods should be contrasted to those that traverse the list of parts using GetParts(). GetParts() returns a list of children of this assembly, not necessarily the leaf nodes of the assembly. To use the methods below - first invoke InitPathTraversal() followed by repeated calls to GetNextPath(). GetNextPath() returns a NULL pointer when the list is exhausted. (See the superclass vtkProp for more information about paths.)

Reimplemented from vtkProp.

void vtkPropAssembly::BuildPaths ( vtkAssemblyPaths paths,
vtkAssemblyPath path 
) [virtual]

WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE DO NOT USE THIS METHOD OUTSIDE OF THE RENDERING PROCESS Overload the superclass' vtkProp BuildPaths() method.

Reimplemented from vtkProp.

void vtkPropAssembly::UpdatePaths (  )  [protected]


Member Data Documentation

Definition at line 127 of file vtkPropAssembly.h.

double vtkPropAssembly::Bounds[6] [protected]

Definition at line 128 of file vtkPropAssembly.h.

Definition at line 131 of file vtkPropAssembly.h.


The documentation for this class was generated from the following file:

Generated on Sat Dec 27 13:45:17 2008 for VTK by  doxygen 1.5.6