ITK  4.8.0
Insight Segmentation and Registration Toolkit
itkGaussianSpatialObject.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
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  * http://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 itkGaussianSpatialObject_h
19 #define itkGaussianSpatialObject_h
20 
22 
23 namespace itk
24 {
42 template< unsigned int TDimension = 3 >
44  public SpatialObject< TDimension >
45 {
46 public:
47 
49  typedef double ScalarType;
54  typedef typename Superclass::PointType PointType;
57 
58  itkStaticConstMacro(NumberOfDimensions, unsigned int,
59  TDimension);
60 
61  itkNewMacro(Self);
62  itkTypeMacro(GaussianSpatialObject, SpatialObject);
63 
67  itkSetMacro(Radius, ScalarType);
68  itkGetConstReferenceMacro(Radius, ScalarType);
70 
73  itkSetMacro(Sigma, ScalarType);
74  itkGetConstReferenceMacro(Sigma, ScalarType);
76 
79  itkSetMacro(Maximum, ScalarType);
80  itkGetConstReferenceMacro(Maximum, ScalarType);
82 
86  ScalarType SquaredZScore(const PointType & point) const;
87 
89  virtual bool ValueAt(const PointType & point, ScalarType & value,
90  unsigned int depth = 0,
91  char *name = ITK_NULLPTR) const ITK_OVERRIDE;
92 
95  virtual bool IsEvaluableAt(const PointType & point,
96  unsigned int depth = 0,
97  char *name = ITK_NULLPTR) const ITK_OVERRIDE;
98 
100  virtual bool IsInside(const PointType & point,
101  unsigned int depth,
102  char *name) const ITK_OVERRIDE;
103 
107  virtual bool IsInside(const PointType & point) const;
108 
111  virtual bool ComputeLocalBoundingBox() const ITK_OVERRIDE;
112 
115  typename EllipseSpatialObject< TDimension >::Pointer GetEllipsoid() const;
116 
117 protected:
118  GaussianSpatialObject(const Self &); //purposely not implemented
119  void operator=(const Self &); //purposely not implemented
120 
123 
127 
129  virtual void PrintSelf(std::ostream & os, Indent indent) const ITK_OVERRIDE;
130 };
131 } // end namespace itk
132 
133 #ifndef ITK_MANUAL_INSTANTIATION
134 #include "itkGaussianSpatialObject.hxx"
135 #endif
136 
137 #endif // itkGaussianSpatialObject_h
Point< ScalarType, VDimension > PointType
static const unsigned int NumberOfDimensions
BoundingBox< IdentifierType, VDimension, ScalarType, VectorContainerType > BoundingBoxType
virtual bool ComputeLocalBoundingBox() const override
Superclass::TransformType TransformType
SmartPointer< Superclass > SuperclassPointer
SmartPointer< const Self > ConstPointer
virtual void PrintSelf(std::ostream &os, Indent indent) const override
Superclass::BoundingBoxType BoundingBoxType
virtual bool IsEvaluableAt(const PointType &point, unsigned int depth=0, char *name=nullptr) const override
EllipseSpatialObject< TDimension >::Pointer GetEllipsoid() const
ScalarType SquaredZScore(const PointType &point) const
virtual bool IsInside(const PointType &point, unsigned int depth, char *name) const override
Implementation of the composite pattern.
SpatialObject< TDimension > Superclass
Represents a multivariate Gaussian function.
virtual bool ValueAt(const PointType &point, ScalarType &value, unsigned int depth=0, char *name=nullptr) const override
Control indentation during Print() invocation.
Definition: itkIndent.h:49
ScalableAffineTransform< double, VDimension > TransformType
Base class for all data objects in ITK.