19 #ifndef itkFastMarchingImageFilterBase_h
20 #define itkFastMarchingImageFilterBase_h
74 template <
typename TInput,
typename TOutput>
84 using typename Superclass::Traits;
95 using typename Superclass::InputPixelType;
99 using typename Superclass::OutputPixelType;
112 using typename Superclass::LabelType;
114 static constexpr
unsigned int ImageDimension = Traits::ImageDimension;
126 class InternalNodeStructure;
143 m_OutputRegion = size;
145 virtual OutputSizeType
148 return m_OutputRegion.GetSize();
150 itkSetMacro(OutputRegion, OutputRegionType);
151 itkGetConstReferenceMacro(OutputRegion, OutputRegionType);
152 itkSetMacro(OutputSpacing, OutputSpacingType);
153 itkGetConstReferenceMacro(OutputSpacing, OutputSpacingType);
154 itkSetMacro(OutputDirection, OutputDirectionType);
155 itkGetConstReferenceMacro(OutputDirection, OutputDirectionType);
156 itkSetMacro(OutputOrigin, OutputPointType);
157 itkGetConstReferenceMacro(OutputOrigin, OutputPointType);
158 itkSetMacro(OverrideOutputInformation,
bool);
159 itkGetConstReferenceMacro(OverrideOutputInformation,
bool);
160 itkBooleanMacro(OverrideOutputInformation);
169 PrintSelf(std::ostream & os,
Indent indent)
const override;
179 bool m_OverrideOutputInformation{
false };
183 GenerateOutputInformation()
override;
186 EnlargeOutputRequestedRegion(
DataObject * output)
override;
192 GetTotalNumberOfNodes()
const override;
195 SetOutputValue(OutputImageType * oImage,
const NodeType & iNode,
const OutputPixelType & iValue)
override;
198 const OutputPixelType
199 GetOutputValue(OutputImageType * oImage,
const NodeType & iNode)
const override;
203 GetLabelValueForGivenNode(
const NodeType & iNode)
const override;
207 SetLabelValueForGivenNode(
const NodeType & iNode,
const LabelType & iLabel)
override;
211 UpdateNeighbors(OutputImageType * oImage,
const NodeType & iNode)
override;
215 UpdateValue(OutputImageType * oImage,
const NodeType & iNode)
override;
219 CheckTopology(OutputImageType * oImage,
const NodeType & iNode)
override;
221 InitializeOutput(OutputImageType * oImage)
override;
226 GetInternalNodesUsed(OutputImageType * oImage,
const NodeType & iNode, InternalNodeStructureArray & ioNodesUsed);
230 Solve(OutputImageType * oImage,
const NodeType & iNode, InternalNodeStructureArray & iNeighbors)
const;
238 InitializeIndices2D();
240 IsChangeWellComposed2D(
const NodeType &)
const;
242 IsCriticalC1Configuration2D(
const std::bitset<9> &)
const;
244 IsCriticalC2Configuration2D(
const std::bitset<9> &)
const;
246 IsCriticalC3Configuration2D(
const std::bitset<9> &)
const;
248 IsCriticalC4Configuration2D(
const std::bitset<9> &)
const;
255 InitializeIndices3D();
257 IsCriticalC1Configuration3D(
const std::bitset<8> &)
const;
259 IsCriticalC2Configuration3D(
const std::bitset<8> &)
const;
261 IsChangeWellComposed3D(
const NodeType &)
const;
268 DoesVoxelChangeViolateWellComposedness(
const NodeType &)
const;
270 DoesVoxelChangeViolateStrictTopology(
const NodeType &)
const;
278 #ifndef ITK_MANUAL_INSTANTIATION
279 # include "itkFastMarchingImageFilterBase.hxx"
282 #endif // itkFastMarchingImageFilterBase_h