Go to the documentation of this file.
10 #ifndef vtk_m_RangeId3_h
11 #define vtk_m_RangeId3_h
79 return (this->X.
IsNonEmpty() && this->Y.IsNonEmpty() && this->Z.IsNonEmpty());
87 return (this->X.
Contains(val[0]) && this->Y.Contains(val[1]) && this->Z.Contains(val[2]));
103 return vtkm::Id3(this->X.
Length(), this->Y.Length(), this->Z.Length());
112 template <
typename T>
142 return unionRangeId3;
153 return ((this->X == range.
X) && (this->Y == range.
Y) && (this->Z == range.
Z));
159 return ((this->X != range.
X) || (this->Y != range.
Y) || (this->Z != range.
Z));
200 return stream <<
"{ X:" << range.
X <<
", Y:" << range.
Y <<
", Z:" << range.
Z <<
" }";
204 #endif //vtk_m_RangeId3_h
VTKM_EXEC_CONT vtkm::RangeId3 operator+(const vtkm::RangeId3 &other) const
Operator for union
Definition: RangeId3.h:148
vtkm::RangeId X
Definition: RangeId3.h:29
Groups connected points that have the same field value.
Definition: Atomic.h:19
#define VTKM_EXEC_CONT
Definition: ExportMacros.h:52
vtkm::RangeId Y
Definition: RangeId3.h:30
vtkm::Int32 IdComponent
Represents a component ID (index of component in a vector).
Definition: Types.h:168
VTKM_EXEC_CONT bool operator==(const vtkm::RangeId3 &range) const
Definition: RangeId3.h:151
Represent a range of vtkm::Id values.
Definition: RangeId.h:28
VTKM_EXEC_CONT bool IsNonEmpty() const
Determine if the range is valid.
Definition: RangeId.h:54
VTKM_EXEC_CONT RangeId3(const vtkm::RangeId &xrange, const vtkm::RangeId &yrange, const vtkm::RangeId &zrange)
Definition: RangeId3.h:36
VTKM_EXEC_CONT void Include(const vtkm::RangeId3 &range)
Expand range to include other range.
Definition: RangeId3.h:126
VTKM_EXEC_CONT vtkm::Id3 Center() const
Returns the center of the range.
Definition: RangeId3.h:95
vtkm::Int32 Id
Represents an ID (index into arrays).
Definition: Types.h:191
VTKM_EXEC_CONT vtkm::RangeId & operator[](IdComponent c) noexcept
Definition: RangeId3.h:162
vtkm::RangeId Z
Definition: RangeId3.h:31
VTKM_EXEC_CONT bool operator!=(const vtkm::RangeId3 &range) const
Definition: RangeId3.h:157
VTKM_EXEC_CONT vtkm::Id Center() const
Returns the center of the range.
Definition: RangeId.h:77
VTKM_CONT std::ostream & operator<<(std::ostream &stream, const vtkm::Bounds &bounds)
Helper function for printing bounds during testing.
Definition: Bounds.h:237
#define VTKM_CONT
Definition: ExportMacros.h:57
VTKM_EXEC_CONT bool Contains(vtkm::Id value) const
Determines if a value is within the range.
Definition: RangeId.h:62
VTKM_EXEC_CONT vtkm::Id Length() const
Returns the length of the range.
Definition: RangeId.h:70
VTKM_EXEC_CONT bool IsNonEmpty() const
Determine if the range is non-empty.
Definition: RangeId3.h:77
vtkm::Vec< vtkm::Id, 3 > Id3
Id3 corresponds to a 3-dimensional index for 3d arrays.
Definition: Types.h:1003
VTKM_EXEC_CONT void Include(const vtkm::Vec< T, 3 > &point)
Expand range to include a value.
Definition: RangeId3.h:113
const VTKM_EXEC_CONT vtkm::RangeId & operator[](IdComponent c) const noexcept
Definition: RangeId3.h:179
VTKM_EXEC_CONT void Include(vtkm::Id value)
Expand range to include a value.
Definition: RangeId.h:86
VTKM_EXEC_CONT vtkm::RangeId3 Union(const vtkm::RangeId3 &other) const
Return the union of this and another range.
Definition: RangeId3.h:138
VTKM_EXEC_CONT RangeId3(const vtkm::Id range[6])
Initialize range with an array of 6 values in the order xmin, xmax, ymin, ymax, zmin,...
Definition: RangeId3.h:55
Represent 3D integer range.
Definition: RangeId3.h:27
VTKM_EXEC_CONT bool Contains(const vtkm::Id3 &val) const
Determines if an Id3 value is within the range.
Definition: RangeId3.h:85
VTKM_EXEC_CONT RangeId3(vtkm::Id minX, vtkm::Id maxX, vtkm::Id minY, vtkm::Id maxY, vtkm::Id minZ, vtkm::Id maxZ)
Definition: RangeId3.h:44
VTKM_EXEC_CONT vtkm::Id3 Dimensions() const
Definition: RangeId3.h:101
VTKM_EXEC_CONT RangeId3(const vtkm::Id3 &min, const vtkm::Id3 &max)
Initialize range with the minimum and the maximum corners.
Definition: RangeId3.h:65