VTK-m  2.2
PointLocatorBase.h
Go to the documentation of this file.
1 //============================================================================
2 // Copyright (c) Kitware, Inc.
3 // All rights reserved.
4 // See LICENSE.txt for details.
5 //
6 // This software is distributed WITHOUT ANY WARRANTY; without even
7 // the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
8 // PURPOSE. See the above copyright notice for more information.
9 //============================================================================
10 #ifndef vtk_m_cont_internal_PointLocatorBase_h
11 #define vtk_m_cont_internal_PointLocatorBase_h
12 
14 
15 #include <vtkm/Types.h>
18 
19 namespace vtkm
20 {
21 namespace cont
22 {
23 
34 {
35 public:
36  virtual ~PointLocatorBase() = default;
37 
42  vtkm::cont::CoordinateSystem GetCoordinates() const { return this->Coords; }
45  {
46  this->Coords = coords;
47  this->SetModified();
48  }
51  {
52  this->SetCoordinates({ "coords", coords });
53  }
54 
55  void Update() const;
56 
57 protected:
58  void SetModified() { this->Modified = true; }
59  bool GetModified() const { return this->Modified; }
60 
61  virtual void Build() = 0;
62 
63 private:
65  mutable bool Modified = true;
66 };
67 
68 } // vtkm::cont
69 } // vtkm
70 
71 #endif // vtk_m_cont_internal_PointLocatorBase_h
vtkm
Groups connected points that have the same field value.
Definition: Atomic.h:19
Types.h
vtkm::cont::PointLocatorBase::SetModified
void SetModified()
Definition: PointLocatorBase.h:58
vtkm::cont::PointLocatorBase
Base class for all PointLocator classes.
Definition: PointLocatorBase.h:33
vtkm::cont::UnknownArrayHandle
An ArrayHandle of an unknown value type and storage.
Definition: UnknownArrayHandle.h:430
vtkm::cont::PointLocatorBase::GetCoordinates
vtkm::cont::CoordinateSystem GetCoordinates() const
Specify the CoordinateSystem defining the location of the cells.
Definition: PointLocatorBase.h:42
CoordinateSystem.h
vtkm::cont::CoordinateSystem
Manages a coordinate system for a DataSet.
Definition: CoordinateSystem.h:30
vtkm::cont::PointLocatorBase::GetModified
bool GetModified() const
Definition: PointLocatorBase.h:59
VTKM_CONT_EXPORT
#define VTKM_CONT_EXPORT
Definition: vtkm_cont_export.h:44
vtkm_cont_export.h
VTKM_CONT
#define VTKM_CONT
Definition: ExportMacros.h:57
vtkm::cont::PointLocatorBase::SetCoordinates
void SetCoordinates(const vtkm::cont::UnknownArrayHandle &coords)
Specify the CoordinateSystem defining the location of the cells.
Definition: PointLocatorBase.h:50
vtkm::cont::PointLocatorBase::Coords
vtkm::cont::CoordinateSystem Coords
Definition: PointLocatorBase.h:64
vtkm::cont::ExecutionObjectBase
Base ExecutionObjectBase for execution objects to inherit from so that you can use an arbitrary objec...
Definition: ExecutionObjectBase.h:31
vtkm::cont::PointLocatorBase::SetCoordinates
void SetCoordinates(const vtkm::cont::CoordinateSystem &coords)
Specify the CoordinateSystem defining the location of the cells.
Definition: PointLocatorBase.h:44
ExecutionObjectBase.h