vtkStaticPointLocator

Struct vtkStaticPointLocator 

Source
pub struct vtkStaticPointLocator(/* private fields */);
Expand description

quickly locate points in 3-space

vtkStaticPointLocator is a spatial search object to quickly locate points in 3D. vtkStaticPointLocator works by dividing a specified region of space into a regular array of cuboid buckets, and then keeping a list of points that lie in each bucket. Typical operation involves giving a position in 3D and finding the closest point; or finding the N closest points.

vtkStaticPointLocator is an accelerated version of vtkPointLocator. It is threaded (via vtkSMPTools), and supports one-time static construction (i.e., incremental point insertion is not supported). If you need to incrementally insert points, use the vtkPointLocator or its kin to do so.

@warning This class is templated. It may run slower than serial execution if the code is not optimized during compilation. Build in Release or ReleaseWithDebugInfo.

@warning Make sure that you review the documentation for the superclasses vtkAbstactPointLocator and vtkLocator. In particular the Automatic data member can be used to automatically determine divisions based on the average number of points per bucket.

@warning Other types of spatial locators have been developed such as octrees and kd-trees. These are often more efficient for the operations described here.

@warning Frequently vtkStaticPointLocator is used in lieu of vtkPointLocator. They are very similar in terms of algorithmic approach, however vtkStaticCellLocator is threaded and is typically much faster for a large number of points (on the order of 3-5x faster). For small numbers of points, vtkPointLocator is just as fast as vtkStaticPointLocator.

@sa vtkPointLocator vtkCellLocator vtkLocator vtkAbstractPointLocator

Implementations§

Source§

impl vtkStaticPointLocator

Source

pub fn new() -> Self

Creates a new vtkStaticPointLocator wrapped inside vtkNew

Trait Implementations§

Source§

impl Default for vtkStaticPointLocator

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl Drop for vtkStaticPointLocator

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.