Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

vtkLocator Class Reference

abstract base class for objects that accelerate spatial searches. More...

#include <vtkLocator.h>

Inheritance diagram for vtkLocator:

Inheritance graph
[legend]
Collaboration diagram for vtkLocator:

Collaboration graph
[legend]
List of all members.

Public Methods

virtual const char * GetClassName ()
virtual int IsA (const char *type)
void PrintSelf (ostream &os, vtkIndent indent)
virtual void SetDataSet (vtkDataSet *)
virtual vtkDataSetGetDataSet ()
virtual void SetMaxLevel (int)
virtual int GetMaxLevel ()
virtual int GetLevel ()
virtual void SetAutomatic (int)
virtual int GetAutomatic ()
virtual void AutomaticOn ()
virtual void AutomaticOff ()
virtual void SetTolerance (float)
virtual float GetTolerance ()
virtual void SetRetainCellLists (int)
virtual int GetRetainCellLists ()
virtual void RetainCellListsOn ()
virtual void RetainCellListsOff ()
virtual void Update ()
virtual void Initialize ()
virtual void BuildLocator ()=0
virtual void FreeSearchStructure ()=0
virtual void GenerateRepresentation (int level, vtkPolyData *pd)=0
virtual unsigned long GetBuildTime ()

Static Public Methods

int IsTypeOf (const char *type)
vtkLocator * SafeDownCast (vtkObject *o)

Protected Methods

 vtkLocator ()
 ~vtkLocator ()
 vtkLocator (const vtkLocator &)
void operator= (const vtkLocator &)

Protected Attributes

vtkDataSetDataSet
int Automatic
float Tolerance
int MaxLevel
int Level
int RetainCellLists
vtkTimeStamp BuildTime

Detailed Description

abstract base class for objects that accelerate spatial searches.

Date:
2000/12/10 20:08:12
Revision:
1.41

vtkLocator is an abstract base class for spatial search objects, or locators. The principle behind locators is that they divide 3-space into small pieces (or "buckets") that can be quickly found in response to queries like point location, line intersection, or object-object intersection.

The purpose of this base class is to provide ivars and methods shared by all locators. The GenerateRepresentation() is one such interesting method. This method works in conjunction with vtkLocatorFilter to create polygonal representations for the locator. For example, if the locator is an OBB tree (i.e., vtkOBBTree.h), then the representation is a set of one or more oriented bounding boxes, depending upon the specified level.

Locators typically work as follows. One or more "entities", such as points or cells, are inserted into the tree. These entities are associated with one or more buckets. Then, when performing geometric operations, the operations are performed first on the buckets, and then if the operation tests positive, then on the entities in the bucket. For example, during collision tests, the locators are collided first to identify intersecting buckets. If an intersection is found, more expensive operations are then carried out on the entities in the bucket.

To obtain good performance, locators are often organized in a tree structure. In such a structure, there are frequently multiple "levels" corresponding to different nodes in the tree. So the word level (in the context of the locator) can be used to specify a particular representation in the tree. For example, in an octree (which is a tree with 8 children), level 0 is the bounding box, or root octant, and level 1 consists of its eight children.

See also:
vtkPointLocator vtkCellLocator vtkOBBTree vtkLocatorFilter

Definition at line 85 of file vtkLocator.h.


Constructor & Destructor Documentation

vtkLocator::vtkLocator   [protected]
 

vtkLocator::~vtkLocator   [protected]
 

vtkLocator::vtkLocator const vtkLocator &    [inline, protected]
 

Definition at line 151 of file vtkLocator.h.


Member Function Documentation

virtual const char* vtkLocator::GetClassName   [virtual]
 

Return the class name as a string. This method is defined in all subclasses of vtkObject with the vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkObject.

Reimplemented in vtkMergePoints2D, vtkPointLocator, vtkPointLocator2D, vtkCellLocator, vtkMergePoints, and vtkOBBTree.

int vtkLocator::IsTypeOf const char *    type [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 vtkObject.

Reimplemented in vtkMergePoints2D, vtkPointLocator, vtkPointLocator2D, vtkCellLocator, vtkMergePoints, and vtkOBBTree.

virtual int vtkLocator::IsA const char *    type [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 vtkObject.

Reimplemented in vtkMergePoints2D, vtkPointLocator, vtkPointLocator2D, vtkCellLocator, vtkMergePoints, and vtkOBBTree.

vtkLocator* vtkLocator::SafeDownCast vtkObject   o [static]
 

Will cast the supplied object to vtkObject* is this is a safe operation (i.e., a safe downcast); otherwise NULL is returned. This method is defined in all subclasses of vtkObject with the vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkObject.

Reimplemented in vtkMergePoints2D, vtkPointLocator, vtkPointLocator2D, vtkCellLocator, vtkMergePoints, and vtkOBBTree.

void vtkLocator::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 vtkObject.

Reimplemented in vtkPointLocator, vtkPointLocator2D, and vtkCellLocator.

virtual void vtkLocator::SetDataSet vtkDataSet   [virtual]
 

Build the locator from the points/cells defining this dataset.

virtual vtkDataSet* vtkLocator::GetDataSet   [virtual]
 

virtual void vtkLocator::SetMaxLevel int    [virtual]
 

Set the maximum allowable level for the tree. If the Automatic ivar is off, this will be the target depth of the locator.

virtual int vtkLocator::GetMaxLevel   [virtual]
 

virtual int vtkLocator::GetLevel   [virtual]
 

Get the level of the locator (determined automatically if Automatic is true). The value of this ivar may change each time the locator is built.

virtual void vtkLocator::SetAutomatic int    [virtual]
 

Boolean controls whether locator depth/resolution of locator is computed automatically from average number of entities in bucket. If not set, there will be an explicit method to control the construction of the locator (found in the subclass).

virtual int vtkLocator::GetAutomatic   [virtual]
 

virtual void vtkLocator::AutomaticOn   [virtual]
 

virtual void vtkLocator::AutomaticOff   [virtual]
 

virtual void vtkLocator::SetTolerance float    [virtual]
 

Specify absolute tolerance (in world coordinates) for performing geometric operations.

virtual float vtkLocator::GetTolerance   [virtual]
 

virtual void vtkLocator::SetRetainCellLists int    [virtual]
 

Boolean controls whether to maintain list of entities in each bucket. Normally the lists are maintained, but if the locator is being used as a geometry simplification technique, there is no need to keep them.

virtual int vtkLocator::GetRetainCellLists   [virtual]
 

virtual void vtkLocator::RetainCellListsOn   [virtual]
 

virtual void vtkLocator::RetainCellListsOff   [virtual]
 

virtual void vtkLocator::Update   [virtual]
 

Cause the locator to rebuild itself if it or its input dataset has changed.

virtual void vtkLocator::Initialize   [virtual]
 

Initialize locator. Frees memory and resets object as appropriate.

Reimplemented in vtkPointLocator, and vtkPointLocator2D.

virtual void vtkLocator::BuildLocator   [pure virtual]
 

Build the locator from the input dataset.

Reimplemented in vtkPointLocator, vtkPointLocator2D, vtkCellLocator, and vtkOBBTree.

virtual void vtkLocator::FreeSearchStructure   [pure virtual]
 

Free the memory required for the spatial data structure.

Reimplemented in vtkPointLocator, vtkPointLocator2D, vtkCellLocator, and vtkOBBTree.

virtual void vtkLocator::GenerateRepresentation int    level,
vtkPolyData   pd
[pure virtual]
 

Method to build a representation at a particular level. Note that the method GetLevel() returns the maximum number of levels available for the tree. You must provide a vtkPolyData object into which to place the data.

Reimplemented in vtkPointLocator, vtkPointLocator2D, vtkCellLocator, and vtkOBBTree.

virtual unsigned long vtkLocator::GetBuildTime   [virtual]
 

Return the time of the last data structure build.

void vtkLocator::operator= const vtkLocator &    [inline, protected]
 

Definition at line 152 of file vtkLocator.h.


Member Data Documentation

vtkDataSet* vtkLocator::DataSet [protected]
 

Definition at line 154 of file vtkLocator.h.

int vtkLocator::Automatic [protected]
 

Definition at line 155 of file vtkLocator.h.

float vtkLocator::Tolerance [protected]
 

Definition at line 156 of file vtkLocator.h.

int vtkLocator::MaxLevel [protected]
 

Definition at line 157 of file vtkLocator.h.

int vtkLocator::Level [protected]
 

Definition at line 158 of file vtkLocator.h.

int vtkLocator::RetainCellLists [protected]
 

Definition at line 159 of file vtkLocator.h.

vtkTimeStamp vtkLocator::BuildTime [protected]
 

Definition at line 161 of file vtkLocator.h.


The documentation for this class was generated from the following file:
Generated on Wed Nov 21 12:52:46 2001 for VTK by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001