18 #ifndef itkSparseFieldLevelSetImageFilter_h
19 #define itkSparseFieldLevelSetImageFilter_h
35 template<
typename TValue >
72 template<
typename TNeighborhoodType >
85 {
return m_ArrayIndex[i]; }
88 {
return m_NeighborhoodOffset[i]; }
94 {
return m_StrideTable[i]; }
99 void Print(std::ostream & os)
const;
227 template<
typename TInputImage,
typename TOutputImage >
255 static constexpr
unsigned int ImageDimension = TOutputImage::ImageDimension;
289 itkSetMacro(NumberOfLayers,
unsigned int);
290 itkGetConstMacro(NumberOfLayers,
unsigned int);
295 itkGetConstMacro(IsoSurfaceValue,
ValueType);
308 itkSetMacro(InterpolateSurfaceLocation,
bool);
309 itkGetConstMacro(InterpolateSurfaceLocation,
bool);
314 { this->SetInterpolateSurfaceLocation(
true); }
316 { this->SetInterpolateSurfaceLocation(
false); }
319 #ifdef ITK_USE_CONCEPT_CHECKING
333 void PrintSelf(std::ostream & os,
Indent indent)
const override;
344 {
return ( value + dt * change ); }
349 void PostProcessOutput()
override;
355 virtual void InitializeBackgroundPixels();
358 void Initialize()
override;
364 void CopyInputToOutput()
override;
367 void AllocateUpdateBuffer()
override;
371 void ApplyUpdate(
const TimeStepType& dt)
override;
375 TimeStepType CalculateChange()
override;
380 void ConstructLayer(StatusType from, StatusType to);
386 void ConstructActiveLayer();
389 void InitializeActiveLayerValues();
398 void PropagateLayerValues(StatusType from, StatusType to,
399 StatusType promote,
int InOrOut);
405 void PropagateAllLayerValues();
410 void UpdateActiveLayerValues(TimeStepType dt, LayerType *StatusUpList,
411 LayerType *StatusDownList);
414 void ProcessStatusList(LayerType *InputList, LayerType *OutputList,
415 StatusType ChangeToStatus, StatusType SearchForStatus);
418 void ProcessOutsideList(LayerType *OutsideList, StatusType ChangeToStatus);
420 itkGetConstMacro(ValueZero, ValueType);
429 double m_ConstantGradientValue{1.0};
472 unsigned int m_NumberOfLayers{2};
496 bool m_InterpolateSurfaceLocation{
true};
504 bool m_BoundsCheckingActive{
false};
508 #ifndef ITK_MANUAL_INSTANTIATION
509 #include "itkSparseFieldLevelSetImageFilter.hxx"
SparseFieldLevelSetNode * Previous
const InputImageType * m_InputImage
static StatusType m_StatusActiveChangingUp
SparseFieldCityBlockNeighborList< NeighborhoodIterator< OutputImageType > > m_NeighborList
typename FiniteDifferenceFunctionType::NeighborhoodScalesType NeighborhoodScalesType
Light weight base class for most itk classes.
typename OutputImageType::IndexType IndexType
OutputImageType * m_OutputImage
void InterpolateSurfaceLocationOff()
std::vector< LayerPointerType > LayerListType
static ValueType m_ValueZero
std::vector< OffsetType > m_NeighborhoodOffset
A convenience class for storing indices which reference neighbor pixels within a neighborhood.
typename OutputImageType::ValueType ValueType
typename LayerType::Pointer LayerPointerType
virtual ValueType CalculateUpdateValue(const IndexType &, const TimeStepType &dt, const ValueType &value, const ValueType &change)
StatusImageType::Pointer m_StatusImage
static StatusType m_StatusActiveChangingDown
ValueType m_IsoSurfaceValue
int GetStride(unsigned int i)
This class implements a finite difference partial differential equation solver for evolving surfaces ...
constexpr unsigned int Dimension
TInputImage InputImageType
static StatusType m_StatusNull
typename NeighborhoodType::OffsetType OffsetType
static ValueType m_ValueOne
ImageBaseType::IndexType IndexType
std::vector< unsigned int > m_ArrayIndex
typename Superclass::RadiusType RadiusType
SparseFieldLevelSetNode * Next
typename Superclass::OffsetType OffsetType
LayerNodeStorageType::Pointer m_LayerNodeStore
Control indentation during Print() invocation.
const unsigned int & GetSize() const
const RadiusType & GetRadius() const
void InterpolateSurfaceLocationOn()
const unsigned int & GetArrayIndex(unsigned int i) const
static StatusType m_StatusChanging
A very simple linked list that is used to manage nodes in a layer of a sparse field level-set solver...
OutputImageType::Pointer m_ShiftedImage
typename FiniteDifferenceFunctionType::RadiusType RadiusType
#define itkConceptMacro(name, concept)
typename FiniteDifferenceFunctionType::TimeStepType TimeStepType
A specialized memory management object for allocating and destroying contiguous blocks of objects...
const OffsetType & GetNeighborhoodOffset(unsigned int i) const
Defines iteration of a local N-dimensional neighborhood of pixels across an itk::Image.
Templated n-dimensional image class.
std::vector< ValueType > UpdateBufferType
static StatusType m_StatusBoundaryPixel
typename NeighborhoodType::RadiusType RadiusType
UpdateBufferType m_UpdateBuffer