Skip to content

Locator ​

Introduction ​

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

Methods ​

extend ​

Method use to decorate a given object (publicAPI+model) with vtkLocator characteristics.

ArgumentTypeRequiredDescription
publicAPIYesobject on which methods will be bounds (public)
modelYesobject on which data structure will be bounds (protected)
initialValuesILocatorInitialValuesNo(default: {})

getAutomatic ​

Get whether locator depth/resolution of locator is computed automatically from average number of entities in bucket.

getDataSet ​

Get the dataset associated with this locator.

Returns ​

TypeDescription
vtkDataSetThe dataset associated with this locator.

getLevel ​

Get the current level of the locator.

Returns ​

TypeDescription
NumberThe current level of the locator.

getMaxLevel ​

Get the maximum level of the locator.

Returns ​

TypeDescription
NumberThe maximum level of the locator.

getTolerance ​

Get the tolerance used for the locator.

Returns ​

TypeDescription
NumberThe tolerance value.

getUseExistingSearchStructure ​

Get whether to use an existing search structure.

Returns ​

TypeDescription
BooleanWhether an existing search structure is used.

setAutomatic ​

Set whether locator depth/resolution of locator is computed automatically from average number of entities in bucket.

ArgumentTypeRequiredDescription
automaticBooleanYes- The automatic flag.

Returns ​

TypeDescription
BooleanWhether the operation was successful.

setDataSet ​

Set the dataset associated with this locator.

ArgumentTypeRequiredDescription
dataSetvtkDataSetYes- The dataset to associate with this locator.

Returns ​

TypeDescription
BooleanWhether the operation was successful.

setLevel ​

Set the current level of the locator.

ArgumentTypeRequiredDescription
levelNumberYes- The level to set.

Returns ​

TypeDescription
BooleanWhether the operation was successful.

setMaxLevel ​

Set the maximum level of the locator.

ArgumentTypeRequiredDescription
maxLevelNumberYes- The maximum level to set.

Returns ​

TypeDescription
BooleanWhether the operation was successful.

setTolerance ​

Set the tolerance used for the locator.

ArgumentTypeRequiredDescription
toleranceNumberYes- The tolerance value to set.

Returns ​

TypeDescription
BooleanWhether the operation was successful.

setUseExistingSearchStructure ​

Set whether to use an existing search structure.

ArgumentTypeRequiredDescription
useExistingSearchStructureBooleanYes- Whether to use an existing search structure.

Returns ​

TypeDescription
BooleanWhether the operation was successful.