VTK-m
2.3
|
Structure for locating cells. More...
#include <CellLocatorBoundingIntervalHierarchy.h>
Classes | |
struct | LastCell |
Structure capturing the location of a cell in the search structure. More... | |
Public Member Functions | |
CellLocatorBoundingIntervalHierarchy (const NodeArrayHandle &nodes, const CellIdArrayHandle &cellIds, const CellSetType &cellSet, const vtkm::cont::CoordinateSystem::MultiplexerArrayType &coords, vtkm::cont::DeviceAdapterId device, vtkm::cont::Token &token) | |
vtkm::ErrorCode | FindCell (const vtkm::Vec3f &point, vtkm::Id &cellId, vtkm::Vec3f ¶metric) const |
Locate the cell containing the provided point. More... | |
vtkm::ErrorCode | FindCell (const vtkm::Vec3f &point, vtkm::Id &cellId, vtkm::Vec3f ¶metric, LastCell &lastCell) const |
Locate the cell containing the provided point. More... | |
vtkm::ErrorCode | FindCellImpl (const vtkm::Vec3f &point, vtkm::Id &cellId, vtkm::Vec3f ¶metric, LastCell &lastCell) const |
Private Types | |
enum | FindCellState { FindCellState::EnterNode, FindCellState::AscendFromNode, FindCellState::DescendLeftChild, FindCellState::DescendRightChild } |
using | NodeArrayHandle = vtkm::cont::ArrayHandle< vtkm::exec::CellLocatorBoundingIntervalHierarchyNode > |
using | CellIdArrayHandle = vtkm::cont::ArrayHandle< vtkm::Id > |
using | VisitType = vtkm::TopologyElementTagCell |
using | IncidentType = vtkm::TopologyElementTagPoint |
using | NodePortal = typename NodeArrayHandle::ReadPortalType |
using | CellIdPortal = typename CellIdArrayHandle::ReadPortalType |
using | CellSetPortal = typename CellSetType::template ExecConnectivityType< VisitType, IncidentType > |
using | CoordsPortal = typename vtkm::cont::CoordinateSystem::MultiplexerArrayType::ReadPortalType |
Private Member Functions | |
vtkm::ErrorCode | EnterNode (FindCellState &state, const vtkm::Vec3f &point, vtkm::Id &cellId, vtkm::Id nodeIndex, vtkm::Vec3f ¶metric, LastCell &lastCell) const |
void | AscendFromNode (FindCellState &state, vtkm::Id &nodeIndex) const |
void | DescendLeftChild (FindCellState &state, const vtkm::Vec3f &point, vtkm::Id &nodeIndex) const |
void | DescendRightChild (FindCellState &state, const vtkm::Vec3f &point, vtkm::Id &nodeIndex) const |
vtkm::ErrorCode | FindInLeaf (const vtkm::Vec3f &point, vtkm::Vec3f ¶metric, const vtkm::exec::CellLocatorBoundingIntervalHierarchyNode &node, vtkm::Id &containingCellId) const |
vtkm::ErrorCode | PointInCell (const vtkm::Vec3f &point, vtkm::Id &cellId, vtkm::Vec3f ¶metric) const |
Static Private Member Functions | |
template<typename CoordsType , typename CellShapeTag > | |
static vtkm::ErrorCode | IsPointInCell (const vtkm::Vec3f &point, vtkm::Vec3f ¶metric, CellShapeTag cellShape, const CoordsType &cellPoints, bool &isInside) |
Private Attributes | |
NodePortal | Nodes |
CellIdPortal | CellIds |
CellSetPortal | CellSet |
CoordsPortal | Coords |
Structure for locating cells.
Use the FindCell()
method to identify which cell contains a point in space. The FindCell()
method optionally takes a LastCell
object, which is a structure nested in this class. The LastCell
object can help speed locating cells for successive finds at nearby points.
This class is provided by vtkm::cont::CellLocatorBoundingIntervalHierarchy
when passed to a worklet.
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
strongprivate |
|
inline |
|
inlineprivate |
|
inlineprivate |
|
inlineprivate |
|
inlineprivate |
|
inline |
Locate the cell containing the provided point.
Given the point coordinate point
, this method determines which cell contains that point. The identification of the cell is returned in the cellId
reference parameter. The method also determines the cell's parametric coordinates to the point and returns that in the parametric
reference parameter. This result can be used in functions like vtkm::exec::CellInterpolate()
.
FindCell()
takes an optional LastCell
parameter. This parameter captures the location of the found cell and can be passed to the next call of FindCell()
. If the subsequent FindCell()
call is for a point that is in or near the same cell, the operation may go faster.
This method will return vtkm::ErrorCode::Success
if a cell is found. If a cell is not found, vtkm::ErrorCode::CellNotFound
is returned and cellId
is set to -1
.
|
inline |
Locate the cell containing the provided point.
Given the point coordinate point
, this method determines which cell contains that point. The identification of the cell is returned in the cellId
reference parameter. The method also determines the cell's parametric coordinates to the point and returns that in the parametric
reference parameter. This result can be used in functions like vtkm::exec::CellInterpolate()
.
FindCell()
takes an optional LastCell
parameter. This parameter captures the location of the found cell and can be passed to the next call of FindCell()
. If the subsequent FindCell()
call is for a point that is in or near the same cell, the operation may go faster.
This method will return vtkm::ErrorCode::Success
if a cell is found. If a cell is not found, vtkm::ErrorCode::CellNotFound
is returned and cellId
is set to -1
.
|
inline |
|
inlineprivate |
|
inlinestaticprivate |
|
inlineprivate |
|
private |
|
private |
|
private |
|
private |