VTK-m  2.2
Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
vtkm::cont::CellLocatorGeneral Class Reference

A CellLocator that works generally well for any supported cell set. More...

#include <CellLocatorGeneral.h>

Inheritance diagram for vtkm::cont::CellLocatorGeneral:
vtkm::cont::CellLocatorBase vtkm::cont::ExecutionObjectBase

Public Types

using ContLocatorList = vtkm::List< vtkm::cont::CellLocatorUniformGrid, vtkm::cont::CellLocatorRectilinearGrid, vtkm::cont::CellLocatorTwoLevel >
 
using ExecLocatorList = vtkm::List< vtkm::cont::internal::ExecutionObjectType< vtkm::cont::CellLocatorUniformGrid >, vtkm::cont::internal::ExecutionObjectType< vtkm::cont::CellLocatorRectilinearGrid >, vtkm::cont::internal::ExecutionObjectType< vtkm::cont::CellLocatorTwoLevel > >
 
using ExecObjType = vtkm::ListApply< ExecLocatorList, vtkm::exec::CellLocatorMultiplexer >
 
using LastCell = typename ExecObjType::LastCell
 

Public Member Functions

ExecObjType PrepareForExecution (vtkm::cont::DeviceAdapterId device, vtkm::cont::Token &token) const
 
- Public Member Functions inherited from vtkm::cont::CellLocatorBase
virtual ~CellLocatorBase ()=default
 
const vtkm::cont::UnknownCellSetGetCellSet () const
 Specify the CellSet defining the structure of the cells being searched. More...
 
void SetCellSet (const vtkm::cont::UnknownCellSet &cellSet)
 Specify the CellSet defining the structure of the cells being searched. More...
 
const vtkm::cont::CoordinateSystemGetCoordinates () const
 Specify the CoordinateSystem defining the location of the cells. More...
 
void SetCoordinates (const vtkm::cont::CoordinateSystem &coords)
 Specify the CoordinateSystem defining the location of the cells. More...
 
void Update () const
 Build the search structure used to look up cells. More...
 

Private Member Functions

void Build () override
 

Private Attributes

vtkm::cont::ListAsVariant< ContLocatorListLocatorImpl
 

Additional Inherited Members

- Protected Member Functions inherited from vtkm::cont::CellLocatorBase
void SetModified ()
 
bool GetModified () const
 

Detailed Description

A CellLocator that works generally well for any supported cell set.

CellLocatorGeneral creates a CellLocator that acts like a multiplexer to switch at runtime to any supported cell set. It is a convenient class to use when the type of CellSet cannot be determined at runtime.

Note that CellLocatorGeneral only supports a finite amount of CellSet types. Thus, it is possible to give it a cell set type that is not supported.

Also note that CellLocatorGeneral can add a significant amount of code inside of worklet that uses it, and this might cause some issues with some compilers.

Member Typedef Documentation

◆ ContLocatorList

◆ ExecLocatorList

using vtkm::cont::CellLocatorGeneral::ExecLocatorList = vtkm::List<vtkm::cont::internal::ExecutionObjectType<vtkm::cont::CellLocatorUniformGrid>, vtkm::cont::internal::ExecutionObjectType<vtkm::cont::CellLocatorRectilinearGrid>, vtkm::cont::internal::ExecutionObjectType<vtkm::cont::CellLocatorTwoLevel> >

◆ ExecObjType

◆ LastCell

using vtkm::cont::CellLocatorGeneral::LastCell = typename ExecObjType::LastCell

Member Function Documentation

◆ Build()

void vtkm::cont::CellLocatorGeneral::Build ( )
overrideprivatevirtual

◆ PrepareForExecution()

ExecObjType vtkm::cont::CellLocatorGeneral::PrepareForExecution ( vtkm::cont::DeviceAdapterId  device,
vtkm::cont::Token token 
) const

Member Data Documentation

◆ LocatorImpl

vtkm::cont::ListAsVariant<ContLocatorList> vtkm::cont::CellLocatorGeneral::LocatorImpl
private

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