ITK 6.0.0
Insight Toolkit
 
Loading...
Searching...
No Matches
itkPolarToCartesianTransform.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 itkPolarToCartesianTransform_h
19#define itkPolarToCartesianTransform_h
20
21#include <iostream>
22#include "itkTransform.h"
23#include "itkMacro.h"
24#include "itkMatrix.h"
25
26namespace itk
27{
28
54template <typename TParametersValueType = double, // Data type for scalars (float or double)
55 unsigned int NDimensions = 3> // Number of dimensions
56class ITK_TEMPLATE_EXPORT PolarToCartesianTransform : public Transform<TParametersValueType, NDimensions, NDimensions>
57{
58public:
59 ITK_DISALLOW_COPY_AND_MOVE(PolarToCartesianTransform);
60
66
68 itkNewMacro(Self);
69
71 itkOverrideGetNameOfClassMacro(PolarToCartesianTransform);
72
74 static constexpr unsigned int SpaceDimension = NDimensions;
75 static constexpr unsigned int ParametersDimension = 0;
76
79
82
85
89
93
95 using InputVnlVectorType = vnl_vector_fixed<TParametersValueType, Self::SpaceDimension>;
96 using OutputVnlVectorType = vnl_vector_fixed<TParametersValueType, Self::SpaceDimension>;
97
101
107 TransformPoint(const InputPointType & point) const override;
108
111 TransformVector(const InputVectorType &) const override
112 {
113 itkExceptionMacro(<< "Method not applicable for this type of transform.");
114 return OutputVectorType();
115 }
116
118 OutputVnlVectorType
119 TransformVector(const InputVnlVectorType &) const override
120 {
121 itkExceptionMacro(<< "Method not applicable for this type of transform.");
122 return OutputVnlVectorType();
123 }
124
126 typename Superclass::OutputVectorPixelType
127 TransformVector(const typename Superclass::InputVectorPixelType &, const InputPointType &) const override
128 {
129 itkExceptionMacro(<< "Method not applicable for this type of transform.");
130 return typename Superclass::OutputVectorPixelType();
131 }
132
133 using Superclass::TransformVector;
134
136 OutputCovariantVectorType
138 {
139 itkExceptionMacro(<< "Method not applicable for this type of transform.");
141 }
142
143 using Superclass::TransformCovariantVector;
144
145 void
147 {
148 itkExceptionMacro(<< "Method not implemented yet.");
149 }
150
151 void
153 {}
154
155 void
157 {}
158
161 itkGetConstReferenceMacro(Center, OutputPointType);
162
168 itkGetConstReferenceMacro(AngleOffset, typename InputPointType::ValueType);
169
174 itkSetMacro(ConstArcIncr, bool);
175 itkGetMacro(ConstArcIncr, bool);
176 itkBooleanMacro(ConstArcIncr);
177
182 itkSetMacro(ReturnNaN, bool);
183 itkGetMacro(ReturnNaN, bool);
184 itkBooleanMacro(ReturnNaN);
185
186protected:
189
191 void
192 PrintSelf(std::ostream & os, Indent indent) const override;
193
194private:
197 bool m_ConstArcIncr = false;
198 bool m_ReturnNaN = false;
199}; // class PolarToCartesianTransform
200
201} // namespace itk
202
203
204#ifndef ITK_MANUAL_INSTANTIATION
205# include "itkPolarToCartesianTransform.hxx"
206#endif
207
208#endif
A templated class holding a n-Dimensional covariant vector.
Control indentation during Print() invocation.
Definition itkIndent.h:53
A templated class holding a geometric point in n-Dimensional space.
Definition itkPoint.h:54
void PrintSelf(std::ostream &os, Indent indent) const override
void SetParameters(const ParametersType &) override
static constexpr unsigned int ParametersDimension
Point< TParametersValueType, Self::SpaceDimension > InputPointType
OutputVectorType TransformVector(const InputVectorType &) const override
OutputVnlVectorType TransformVector(const InputVnlVectorType &) const override
typename Superclass::ParametersType ParametersType
typename Superclass::JacobianType JacobianType
OutputPointType TransformPoint(const InputPointType &point) const override
OutputCovariantVectorType TransformCovariantVector(const InputCovariantVectorType &) const override
static constexpr unsigned int SpaceDimension
Point< TParametersValueType, Self::SpaceDimension > OutputPointType
vnl_vector_fixed< TParametersValueType, Self::SpaceDimension > InputVnlVectorType
Vector< TParametersValueType, Self::SpaceDimension > InputVectorType
typename Superclass::ScalarType ScalarType
vnl_vector_fixed< TParametersValueType, Self::SpaceDimension > OutputVnlVectorType
Superclass::OutputVectorPixelType TransformVector(const typename Superclass::InputVectorPixelType &, const InputPointType &) const override
CovariantVector< TParametersValueType, Self::SpaceDimension > InputCovariantVectorType
Transform< TParametersValueType, NDimensions, NDimensions > Superclass
Vector< TParametersValueType, Self::SpaceDimension > OutputVectorType
CovariantVector< TParametersValueType, Self::SpaceDimension > OutputCovariantVectorType
void SetFixedParameters(const ParametersType &) override
void ComputeJacobianWithRespectToParameters(const InputPointType &, JacobianType &) const override
Implements transparent reference counting.
OptimizerParameters< ParametersValueType > ParametersType
VariableLengthVector< TParametersValueType > OutputVectorPixelType
VariableLengthVector< TParametersValueType > InputVectorPixelType
A templated class holding a n-Dimensional vector.
Definition itkVector.h:63
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
#define itkSetMacro(name, type)