ITK  5.3.0
Insight Toolkit
itkImageMaskSpatialObject.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright NumFOCUS
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * https://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef itkImageMaskSpatialObject_h
19 #define itkImageMaskSpatialObject_h
20 
21 #include "itkImageSpatialObject.h"
23 
24 namespace itk
25 {
44 template <unsigned int TDimension = 3, typename TPixel = unsigned char>
45 class ITK_TEMPLATE_EXPORT ImageMaskSpatialObject : public ImageSpatialObject<TDimension, TPixel>
46 {
47 public:
48  ITK_DISALLOW_COPY_AND_MOVE(ImageMaskSpatialObject);
49 
54 
55  using typename Superclass::ScalarType;
56  using typename Superclass::PixelType;
57  using typename Superclass::ImageType;
58  using typename Superclass::ImagePointer;
59  using typename Superclass::IndexType;
60  using typename Superclass::RegionType;
61  using typename Superclass::SizeType;
62  using typename Superclass::TransformType;
63  using typename Superclass::PointType;
64  using typename Superclass::BoundingBoxType;
65  using typename Superclass::InterpolatorType;
66 
68 
70  itkNewMacro(Self);
71 
74 
77  bool
78  IsInsideInObjectSpace(const PointType & point) const override;
79 
80  /* Avoid hiding the overload that supports depth and name arguments */
81  using Superclass::IsInsideInObjectSpace;
82 
94  ComputeMyBoundingBoxInIndexSpace() const;
95 
96 #if !defined(ITK_LEGACY_REMOVE)
97 
100  itkLegacyMacro(RegionType GetAxisAlignedBoundingBoxRegion() const);
101 
102 #endif
103 
104 protected:
108  void
109  ComputeMyBoundingBox() override;
110 
112  ~ImageMaskSpatialObject() override = default;
113 
114  void
115  PrintSelf(std::ostream & os, Indent indent) const override;
116 
117  typename LightObject::Pointer
118  InternalClone() const override;
119 };
120 } // end of namespace itk
121 
122 #ifndef ITK_MANUAL_INSTANTIATION
123 # include "itkImageMaskSpatialObject.hxx"
124 #endif
125 
126 #endif // itkImageMaskSpatialObject_h
itkImageSpatialObject.h
itk::ImageRegion< VDimension >
itk::GTest::TypedefsAndConstructors::Dimension2::PointType
ImageBaseType::PointType PointType
Definition: itkGTestTypedefsAndConstructors.h:51
itk::GTest::TypedefsAndConstructors::Dimension2::SizeType
ImageBaseType::SizeType SizeType
Definition: itkGTestTypedefsAndConstructors.h:49
itk::SmartPointer< Self >
itk::Indent
Control indentation during Print() invocation.
Definition: itkIndent.h:49
itk::ImageSpatialObject
Implementation of an image as spatial object.
Definition: itkImageSpatialObject.h:40
itk::ImageSliceConstIteratorWithIndex
Multi-dimensional image iterator which only walks a region.
Definition: itkImageSliceConstIteratorWithIndex.h:113
itk::GTest::TypedefsAndConstructors::Dimension2::IndexType
ImageBaseType::IndexType IndexType
Definition: itkGTestTypedefsAndConstructors.h:50
itk::point
*par Constraints *The filter requires an image with at least two dimensions and a vector *length of at least The theory supports extension to scalar but *the implementation of the itk vector classes do not **The template parameter TRealType must be floating point(float or double) or *a user-defined "real" numerical type with arithmetic operations defined *sufficient to compute derivatives. **\par Performance *This filter will automatically multithread if run with *SetUsePrincipleComponents
itk::GTest::TypedefsAndConstructors::Dimension2::RegionType
ImageBaseType::RegionType RegionType
Definition: itkGTestTypedefsAndConstructors.h:54
itkImageSliceConstIteratorWithIndex.h
itk::ImageMaskSpatialObject
Implementation of an image mask as spatial object.
Definition: itkImageMaskSpatialObject.h:45
itk
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Definition: itkAnnulusOperator.h:24
itk::Object
Base class for most ITK classes.
Definition: itkObject.h:61
itk::Point
A templated class holding a geometric point in n-Dimensional space.
Definition: itkPoint.h:53
itk::DataObject
Base class for all data objects in ITK.
Definition: itkDataObject.h:293