VTK
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
vtkLODActor Class Reference

an actor that supports multiple levels of detail More...

#include <vtkLODActor.h>

Inheritance diagram for vtkLODActor:
[legend]
Collaboration diagram for vtkLODActor:
[legend]

Public Types

typedef vtkActor Superclass
- Public Types inherited from vtkActor
typedef vtkProp3D Superclass
- Public Types inherited from vtkProp3D
typedef vtkProp Superclass
- Public Types inherited from vtkProp
typedef vtkObject Superclass
- Public Types inherited from vtkObject
typedef vtkObjectBase Superclass

Public Member Functions

virtual const char * GetClassName ()
virtual int IsA (const char *type)
void PrintSelf (ostream &os, vtkIndent indent)
virtual void Render (vtkRenderer *, vtkMapper *)
int RenderOpaqueGeometry (vtkViewport *viewport)
void ReleaseGraphicsResources (vtkWindow *)
void AddLODMapper (vtkMapper *mapper)
void Modified ()
void ShallowCopy (vtkProp *prop)
virtual void SetLowResFilter (vtkPolyDataAlgorithm *)
virtual void SetMediumResFilter (vtkPolyDataAlgorithm *)
virtual vtkPolyDataAlgorithmGetLowResFilter ()
virtual vtkPolyDataAlgorithmGetMediumResFilter ()
virtual int GetNumberOfCloudPoints ()
virtual void SetNumberOfCloudPoints (int)
virtual vtkMapperCollectionGetLODMappers ()
- Public Member Functions inherited from vtkActor
virtual void GetActors (vtkPropCollection *)
virtual int HasTranslucentPolygonalGeometry ()
virtual vtkPropertyMakeProperty ()
virtual void SetMapper (vtkMapper *)
virtual void ApplyProperties ()
unsigned long int GetMTime ()
virtual unsigned long GetRedrawMTime ()
virtual bool GetSupportsSelection ()
virtual int RenderTranslucentPolygonalGeometry (vtkViewport *viewport)
void SetProperty (vtkProperty *lut)
vtkPropertyGetProperty ()
void SetBackfaceProperty (vtkProperty *lut)
virtual vtkPropertyGetBackfaceProperty ()
virtual void SetTexture (vtkTexture *)
virtual vtkTextureGetTexture ()
virtual vtkMapperGetMapper ()
void GetBounds (double bounds[6])
double * GetBounds ()
virtual void InitPartTraversal ()
virtual vtkActorGetNextPart ()
virtual int GetNumberOfParts ()
- Public Member Functions inherited from vtkProp3D
void SetScale (double s)
double * GetCenter ()
double * GetXRange ()
double * GetYRange ()
double * GetZRange ()
double GetLength ()
void RotateX (double)
void RotateY (double)
void RotateZ (double)
void RotateWXYZ (double, double, double, double)
void SetOrientation (double, double, double)
void SetOrientation (double a[3])
double * GetOrientationWXYZ ()
void AddOrientation (double, double, double)
void AddOrientation (double a[3])
void PokeMatrix (vtkMatrix4x4 *matrix)
void InitPathTraversal ()
unsigned long int GetUserTransformMatrixMTime ()
virtual void ComputeMatrix ()
virtual void SetPosition (double _arg1, double _arg2, double _arg3)
virtual void SetPosition (double _arg[3])
virtual double * GetPosition ()
virtual void GetPosition (double data[3])
void AddPosition (double deltaPosition[3])
void AddPosition (double deltaX, double deltaY, double deltaZ)
virtual void SetOrigin (double _arg1, double _arg2, double _arg3)
virtual void SetOrigin (double _arg[3])
virtual double * GetOrigin ()
virtual void GetOrigin (double data[3])
virtual void SetScale (double _arg1, double _arg2, double _arg3)
virtual void SetScale (double _arg[3])
virtual double * GetScale ()
virtual void GetScale (double data[3])
void SetUserTransform (vtkLinearTransform *transform)
virtual vtkLinearTransformGetUserTransform ()
void SetUserMatrix (vtkMatrix4x4 *matrix)
vtkMatrix4x4GetUserMatrix ()
virtual void GetMatrix (vtkMatrix4x4 *m)
virtual void GetMatrix (double m[16])
double * GetOrientation ()
void GetOrientation (double o[3])
vtkMatrix4x4GetMatrix ()
virtual int GetIsIdentity ()
- Public Member Functions inherited from vtkProp
virtual void Pick ()
virtual bool HasKeys (vtkInformation *requiredKeys)
virtual void BuildPaths (vtkAssemblyPaths *paths, vtkAssemblyPath *path)
virtual void GetActors2D (vtkPropCollection *)
virtual void GetVolumes (vtkPropCollection *)
virtual void SetVisibility (int)
virtual int GetVisibility ()
virtual void VisibilityOn ()
virtual void VisibilityOff ()
virtual void SetPickable (int)
virtual int GetPickable ()
virtual void PickableOn ()
virtual void PickableOff ()
virtual void SetDragable (int)
virtual int GetDragable ()
virtual void DragableOn ()
virtual void DragableOff ()
virtual void SetUseBounds (bool)
virtual bool GetUseBounds ()
virtual void UseBoundsOn ()
virtual void UseBoundsOff ()
virtual vtkAssemblyPathGetNextPath ()
virtual int GetNumberOfPaths ()
virtual void PokeMatrix (vtkMatrix4x4 *vtkNotUsed(matrix))
virtual vtkInformationGetPropertyKeys ()
virtual void SetPropertyKeys (vtkInformation *keys)
virtual int RenderVolumetricGeometry (vtkViewport *)
virtual int RenderOverlay (vtkViewport *)
virtual bool RenderFilteredOpaqueGeometry (vtkViewport *v, vtkInformation *requiredKeys)
virtual bool RenderFilteredTranslucentPolygonalGeometry (vtkViewport *v, vtkInformation *requiredKeys)
virtual bool RenderFilteredVolumetricGeometry (vtkViewport *v, vtkInformation *requiredKeys)
virtual bool RenderFilteredOverlay (vtkViewport *v, vtkInformation *requiredKeys)
virtual double GetEstimatedRenderTime (vtkViewport *)
virtual double GetEstimatedRenderTime ()
virtual void SetEstimatedRenderTime (double t)
virtual void RestoreEstimatedRenderTime ()
virtual void AddEstimatedRenderTime (double t, vtkViewport *vtkNotUsed(vp))
virtual void SetAllocatedRenderTime (double t, vtkViewport *vtkNotUsed(v))
virtual double GetAllocatedRenderTime ()
void SetRenderTimeMultiplier (double t)
virtual double GetRenderTimeMultiplier ()
virtual int GetNumberOfConsumers ()
void AddConsumer (vtkObject *c)
void RemoveConsumer (vtkObject *c)
vtkObjectGetConsumer (int i)
int IsConsumer (vtkObject *c)
- Public Member Functions inherited from vtkObject
virtual void DebugOn ()
virtual void DebugOff ()
unsigned char GetDebug ()
void SetDebug (unsigned char debugFlag)
unsigned long AddObserver (unsigned long event, vtkCommand *, float priority=0.0f)
unsigned long AddObserver (const char *event, vtkCommand *, float priority=0.0f)
vtkCommandGetCommand (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)
int InvokeEvent (unsigned long event, void *callData)
int InvokeEvent (const char *event, void *callData)
int InvokeEvent (unsigned long event)
int InvokeEvent (const char *event)
- Public Member Functions inherited from vtkObjectBase
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 &os)
virtual void PrintHeader (ostream &os, vtkIndent indent)
virtual void PrintTrailer (ostream &os, vtkIndent indent)
int GetReferenceCount ()

Static Public Member Functions

static int IsTypeOf (const char *type)
static vtkLODActorSafeDownCast (vtkObject *o)
static vtkLODActorNew ()

Protected Member Functions

 vtkLODActor ()
 ~vtkLODActor ()
virtual void CreateOwnLODs ()
virtual void UpdateOwnLODs ()
virtual void DeleteOwnLODs ()
- Protected Member Functions inherited from vtkActor
 vtkActor ()
 ~vtkActor ()
int GetIsOpaque ()
- Protected Member Functions inherited from vtkProp3D
 vtkProp3D ()
 ~vtkProp3D ()
- Protected Member Functions inherited from vtkProp
 vtkProp ()
 ~vtkProp ()
- Protected Member Functions inherited from vtkObject
 vtkObject ()
virtual ~vtkObject ()
virtual void RegisterInternal (vtkObjectBase *, int check)
virtual void UnRegisterInternal (vtkObjectBase *, int check)
void InternalGrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=NULL)
void InternalReleaseFocus ()
- Protected Member Functions inherited from vtkObjectBase
 vtkObjectBase ()
virtual ~vtkObjectBase ()
virtual void CollectRevisions (ostream &os)
virtual void ReportReferences (vtkGarbageCollector *)
 vtkObjectBase (const vtkObjectBase &)
void operator= (const vtkObjectBase &)

Protected Attributes

vtkActorDevice
vtkMapperCollectionLODMappers
vtkPolyDataAlgorithmLowResFilter
vtkPolyDataAlgorithmMediumResFilter
vtkPolyDataMapperLowMapper
vtkPolyDataMapperMediumMapper
vtkTimeStamp BuildTime
int NumberOfCloudPoints
- Protected Attributes inherited from vtkActor
vtkPropertyProperty
vtkPropertyBackfaceProperty
vtkTextureTexture
vtkMapperMapper
double MapperBounds [6]
vtkTimeStamp BoundsMTime
- Protected Attributes inherited from vtkProp3D
vtkLinearTransformUserTransform
vtkMatrix4x4UserMatrix
vtkMatrix4x4Matrix
vtkTimeStamp MatrixMTime
double Origin [3]
double Position [3]
double Orientation [3]
double Scale [3]
double Center [3]
vtkTransformTransform
double Bounds [6]
vtkProp3DCachedProp3D
int IsIdentity
- Protected Attributes inherited from vtkProp
int Visibility
int Pickable
int Dragable
bool UseBounds
double AllocatedRenderTime
double EstimatedRenderTime
double SavedEstimatedRenderTime
double RenderTimeMultiplier
int NumberOfConsumers
vtkObject ** Consumers
vtkAssemblyPathsPaths
vtkInformationPropertyKeys
- Protected Attributes inherited from vtkObject
unsigned char Debug
vtkTimeStamp MTime
vtkSubjectHelper * SubjectHelper
- Protected Attributes inherited from vtkObjectBase
int ReferenceCount
vtkWeakPointerBase ** WeakPointers

Detailed Description

an actor that supports multiple levels of detail

vtkLODActor is an actor that stores multiple levels of detail (LOD) and can automatically switch between them. It selects which level of detail to use based on how much time it has been allocated to render. Currently a very simple method of TotalTime/NumberOfActors is used. (In the future this should be modified to dynamically allocate the rendering time between different actors based on their needs.)

There are three levels of detail by default. The top level is just the normal data. The lowest level of detail is a simple bounding box outline of the actor. The middle level of detail is a point cloud of a fixed number of points that have been randomly sampled from the mapper's input data. Point attributes are copied over to the point cloud. These two lower levels of detail are accomplished by creating instances of a vtkOutlineFilter (low-res) and vtkMaskPoints (medium-res). Additional levels of detail can be add using the AddLODMapper() method.

To control the frame rate, you typically set the vtkRenderWindowInteractor DesiredUpdateRate and StillUpdateRate. This then will cause vtkLODActor to adjust its LOD to fulfill the requested update rate.

For greater control on levels of detail, see also vtkLODProp3D. That class allows arbitrary definition of each LOD.

Warning
If you provide your own mappers, you are responsible for setting its ivars correctly, such as ScalarRange, LookupTable, and so on.
On some systems the point cloud rendering (the default, medium level of detail) can result in points so small that they can hardly be seen. In this case, use the GetProperty()->SetPointSize() method to increase the rendered size of the points.
See Also
vtkActor vtkRenderer vtkLODProp3D
Examples:
vtkLODActor (Examples)
Tests:
vtkLODActor (Tests)

Definition at line 74 of file vtkLODActor.h.

Member Typedef Documentation

Definition at line 77 of file vtkLODActor.h.

Constructor & Destructor Documentation

vtkLODActor::vtkLODActor ( )
protected
vtkLODActor::~vtkLODActor ( )
protected

Member Function Documentation

virtual const char* vtkLODActor::GetClassName ( )
virtual

Reimplemented from vtkActor.

static int vtkLODActor::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 vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkActor.

virtual int vtkLODActor::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 vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkActor.

static vtkLODActor* vtkLODActor::SafeDownCast ( vtkObject o)
static

Reimplemented from vtkActor.

void vtkLODActor::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 vtkActor.

static vtkLODActor* vtkLODActor::New ( )
static

Creates a vtkLODActor with the following defaults: origin(0,0,0) position=(0,0,0) scale=(1,1,1) visibility=1 pickable=1 dragable=1 orientation=(0,0,0). NumberOfCloudPoints is set to 150.

Reimplemented from vtkActor.

virtual void vtkLODActor::Render ( vtkRenderer ,
vtkMapper  
)
virtual

This causes the actor to be rendered. It, in turn, will render the actor's property and then mapper.

Reimplemented from vtkActor.

int vtkLODActor::RenderOpaqueGeometry ( vtkViewport viewport)
virtual

This method is used internally by the rendering process. We overide the superclass method to properly set the estimated render time.

Reimplemented from vtkActor.

void vtkLODActor::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 vtkActor.

void vtkLODActor::AddLODMapper ( vtkMapper mapper)

Add another level of detail. They do not have to be in any order of complexity.

virtual void vtkLODActor::SetLowResFilter ( vtkPolyDataAlgorithm )
virtual

You may plug in your own filters to decimate/subsample the input. The default is to use a vtkOutlineFilter (low-res) and vtkMaskPoints (medium-res).

virtual void vtkLODActor::SetMediumResFilter ( vtkPolyDataAlgorithm )
virtual

You may plug in your own filters to decimate/subsample the input. The default is to use a vtkOutlineFilter (low-res) and vtkMaskPoints (medium-res).

virtual vtkPolyDataAlgorithm* vtkLODActor::GetLowResFilter ( )
virtual

You may plug in your own filters to decimate/subsample the input. The default is to use a vtkOutlineFilter (low-res) and vtkMaskPoints (medium-res).

virtual vtkPolyDataAlgorithm* vtkLODActor::GetMediumResFilter ( )
virtual

You may plug in your own filters to decimate/subsample the input. The default is to use a vtkOutlineFilter (low-res) and vtkMaskPoints (medium-res).

virtual int vtkLODActor::GetNumberOfCloudPoints ( )
virtual

Set/Get the number of random points for the point cloud.

virtual void vtkLODActor::SetNumberOfCloudPoints ( int  )
virtual

Set/Get the number of random points for the point cloud.

virtual vtkMapperCollection* vtkLODActor::GetLODMappers ( )
virtual

All the mappers for different LODs are stored here. The order is not important.

void vtkLODActor::Modified ( )
virtual

When this objects gets modified, this method also modifies the object.

Reimplemented from vtkObject.

void vtkLODActor::ShallowCopy ( vtkProp prop)
virtual

Shallow copy of an LOD actor. Overloads the virtual vtkProp method.

Reimplemented from vtkActor.

virtual void vtkLODActor::CreateOwnLODs ( )
protectedvirtual
virtual void vtkLODActor::UpdateOwnLODs ( )
protectedvirtual
virtual void vtkLODActor::DeleteOwnLODs ( )
protectedvirtual

Member Data Documentation

vtkActor* vtkLODActor::Device
protected

Definition at line 135 of file vtkLODActor.h.

vtkMapperCollection* vtkLODActor::LODMappers
protected

Definition at line 136 of file vtkLODActor.h.

vtkPolyDataAlgorithm* vtkLODActor::LowResFilter
protected

Definition at line 140 of file vtkLODActor.h.

vtkPolyDataAlgorithm* vtkLODActor::MediumResFilter
protected

Definition at line 141 of file vtkLODActor.h.

vtkPolyDataMapper* vtkLODActor::LowMapper
protected

Definition at line 142 of file vtkLODActor.h.

vtkPolyDataMapper* vtkLODActor::MediumMapper
protected

Definition at line 143 of file vtkLODActor.h.

vtkTimeStamp vtkLODActor::BuildTime
protected

Definition at line 145 of file vtkLODActor.h.

int vtkLODActor::NumberOfCloudPoints
protected

Definition at line 146 of file vtkLODActor.h.


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