ITK  5.2.0
Insight Toolkit
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members

#include <itkChainCodePath2D.h>

+ Inheritance diagram for itk::ChainCodePath2D:
+ Collaboration diagram for itk::ChainCodePath2D:

Public Types

using ChainCode2DType = std::vector< int >
 
using ChainCodeSizeType = Superclass::ChainCodeSizeType
 
using ChainCodeType = Superclass::ChainCodeType
 
using ConstPointer = SmartPointer< const Self >
 
using IndexType = Index< 2 >
 
using InputType = Superclass::InputType
 
using OffsetType = OutputType
 
using OutputType = Superclass::OutputType
 
using Pointer = SmartPointer< Self >
 
using Self = ChainCodePath2D
 
using Superclass = ChainCodePath< 2 >
 
- Public Types inherited from itk::ChainCodePath< 2 >
using ChainCodeSizeType = typename ChainCodeType::size_type
 
using ChainCodeType = std::vector< OffsetType >
 
using ConstPointer = SmartPointer< const Self >
 
using IndexType = Index< VDimension >
 
using InputType = typename Superclass::InputType
 
using OffsetType = OutputType
 
using OutputType = typename Superclass::OutputType
 
using Pointer = SmartPointer< Self >
 
using Self = ChainCodePath< VDimension >
 
using Superclass = Path< unsigned int, Offset< VDimension >, VDimension >
 
- Public Types inherited from itk::Path< unsigned int, Offset< VDimension >, VDimension >
using ConstPointer = SmartPointer< const Self >
 
using IndexType = Index< VDimension >
 
using InputType = unsigned int
 
using OffsetType = Offset< VDimension >
 
using OutputType = Offset< VDimension >
 
using Pointer = SmartPointer< Self >
 
using Self = Path
 
using Superclass = DataObject
 
- Public Types inherited from itk::DataObject
using ConstPointer = SmartPointer< const Self >
 
using DataObjectIdentifierType = std::string
 
using DataObjectPointerArraySizeType = std::vector< Pointer >::size_type
 
using Pointer = SmartPointer< Self >
 
using Self = DataObject
 
using Superclass = Object
 
- Public Types inherited from itk::Object
using ConstPointer = SmartPointer< const Self >
 
using Pointer = SmartPointer< Self >
 
using Self = Object
 
using Superclass = LightObject
 
- Public Types inherited from itk::LightObject
using ConstPointer = SmartPointer< const Self >
 
using Pointer = SmartPointer< Self >
 
using Self = LightObject
 

Public Member Functions

virtual ::itk::LightObject::Pointer CreateAnother () const
 
OutputType Evaluate (const InputType &input) const override
 
IndexType EvaluateToIndex (const InputType &input) const override
 
virtual const char * GetNameOfClass () const
 
OffsetType IncrementInput (InputType &input) const override
 
ChainCodeSizeType NumberOfSteps () const override
 
- Public Member Functions inherited from itk::ChainCodePath< 2 >
virtual ::itk::LightObject::Pointer CreateAnother () const
 
InputType EndOfInput () const override
 
OutputType Evaluate (const InputType &input) const override
 
IndexType EvaluateToIndex (const InputType &input) const override
 
OffsetType IncrementInput (InputType &input) const override
 
virtual void SetStart (IndexType _arg)
 
virtual const IndexTypeGetStart () const
 
virtual void InsertStep (InputType position, OffsetType step)
 
virtual void ChangeStep (InputType position, OffsetType step)
 
void Initialize () override
 
- Public Member Functions inherited from itk::Path< unsigned int, Offset< VDimension >, VDimension >
virtual OutputType Evaluate (const InputType &input) const=0
 
virtual IndexType EvaluateToIndex (const InputType &input) const=0
 
virtual OffsetType IncrementInput (InputType &input) const=0
 
virtual InputType StartOfInput () const
 
- Public Member Functions inherited from itk::DataObject
void DisconnectPipeline ()
 
bool GetDataReleased () const
 
virtual const bool & GetReleaseDataFlag () const
 
SmartPointer< ProcessObjectGetSource () const
 
DataObjectPointerArraySizeType GetSourceOutputIndex () const
 
const DataObjectIdentifierTypeGetSourceOutputName () const
 
virtual void PropagateRequestedRegion ()
 
void ReleaseData ()
 
virtual void ReleaseDataFlagOff ()
 
virtual void ReleaseDataFlagOn ()
 
virtual void ResetPipeline ()
 
void SetReleaseDataFlag (bool flag)
 
bool ShouldIReleaseData () const
 
virtual void Update ()
 
virtual void UpdateOutputData ()
 
virtual void UpdateOutputInformation ()
 
void SetPipelineMTime (ModifiedTimeType time)
 
virtual const ModifiedTimeTypeGetPipelineMTime () const
 
virtual ModifiedTimeType GetUpdateMTime () const
 
virtual void SetRealTimeStamp (RealTimeStamp _arg)
 
virtual const RealTimeStampGetRealTimeStamp () const
 
virtual void PrepareForNewData ()
 
virtual void DataHasBeenGenerated ()
 
virtual void SetRequestedRegionToLargestPossibleRegion ()
 
virtual bool RequestedRegionIsOutsideOfTheBufferedRegion ()
 
virtual bool VerifyRequestedRegion ()
 
virtual void CopyInformation (const DataObject *)
 
virtual void SetRequestedRegion (const DataObject *)
 
virtual void Graft (const DataObject *)
 
- Public Member Functions inherited from itk::Object
unsigned long AddObserver (const EventObject &event, Command *)
 
unsigned long AddObserver (const EventObject &event, Command *) const
 
unsigned long AddObserver (const EventObject &event, std::function< void(const EventObject &)> function) const
 
virtual void DebugOff () const
 
virtual void DebugOn () const
 
CommandGetCommand (unsigned long tag)
 
bool GetDebug () const
 
MetaDataDictionaryGetMetaDataDictionary ()
 
const MetaDataDictionaryGetMetaDataDictionary () const
 
virtual ModifiedTimeType GetMTime () const
 
virtual const TimeStampGetTimeStamp () const
 
bool HasObserver (const EventObject &event) const
 
void InvokeEvent (const EventObject &)
 
void InvokeEvent (const EventObject &) const
 
virtual void Modified () const
 
void Register () const override
 
void RemoveAllObservers ()
 
void RemoveObserver (unsigned long tag)
 
void SetDebug (bool debugFlag) const
 
void SetReferenceCount (int) override
 
void UnRegister () const noexcept override
 
void SetMetaDataDictionary (const MetaDataDictionary &rhs)
 
void SetMetaDataDictionary (MetaDataDictionary &&rrhs)
 
virtual void SetObjectName (std::string _arg)
 
virtual const std::string & GetObjectName () const
 
- Public Member Functions inherited from itk::LightObject
Pointer Clone () const
 
virtual void Delete ()
 
virtual int GetReferenceCount () const
 
void Print (std::ostream &os, Indent indent=0) const
 

Static Public Member Functions

static Pointer New ()
 
- Static Public Member Functions inherited from itk::ChainCodePath< 2 >
static Pointer New ()
 
- Static Public Member Functions inherited from itk::DataObject
static bool GetGlobalReleaseDataFlag ()
 
static void GlobalReleaseDataFlagOff ()
 
static void GlobalReleaseDataFlagOn ()
 
static Pointer New ()
 
static void SetGlobalReleaseDataFlag (bool val)
 
- Static Public Member Functions inherited from itk::Object
static bool GetGlobalWarningDisplay ()
 
static void GlobalWarningDisplayOff ()
 
static void GlobalWarningDisplayOn ()
 
static Pointer New ()
 
static void SetGlobalWarningDisplay (bool val)
 
- Static Public Member Functions inherited from itk::LightObject
static void BreakOnError ()
 
static Pointer New ()
 

Static Public Attributes

static constexpr unsigned int Dimension = 2
 
- Static Public Attributes inherited from itk::ChainCodePath< 2 >
static constexpr unsigned int Dimension
 
- Static Public Attributes inherited from itk::Path< unsigned int, Offset< VDimension >, VDimension >
static constexpr unsigned int PathDimension
 
ChainCode2DType m_Chain2D
 
int m_FreemanCode [3][3]
 
OffsetType m_ReverseFreemanCode [9]
 
void InsertStep (InputType position, int encodedStep)
 
void InsertStep (InputType position, OffsetType step) override
 
void ChangeStep (InputType position, int encodedStep)
 
void ChangeStep (InputType position, OffsetType step) override
 
void Clear () override
 
std::string GetChainCodeAsString () const
 
 ChainCodePath2D ()
 
 ~ChainCodePath2D () override
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
int EncodeOffset (OffsetType step) const
 
OffsetType DecodeOffset (int encodedStep) const
 

Additional Inherited Members

- Protected Member Functions inherited from itk::ChainCodePath< 2 >
 ChainCodePath ()
 
 ~ChainCodePath () override=default
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
- Protected Member Functions inherited from itk::Path< unsigned int, Offset< VDimension >, VDimension >
virtual IndexType GetZeroIndex () const
 
virtual OffsetType GetZeroOffset () const
 
 Path ()
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
 ~Path () override=default
 
- Protected Member Functions inherited from itk::DataObject
 DataObject ()
 
 ~DataObject () override
 
virtual void PropagateResetPipeline ()
 
- Protected Member Functions inherited from itk::Object
 Object ()
 
 ~Object () override
 
bool PrintObservers (std::ostream &os, Indent indent) const
 
virtual void SetTimeStamp (const TimeStamp &timeStamp)
 
- Protected Member Functions inherited from itk::LightObject
virtual LightObject::Pointer InternalClone () const
 
 LightObject ()
 
virtual void PrintHeader (std::ostream &os, Indent indent) const
 
virtual void PrintTrailer (std::ostream &os, Indent indent) const
 
virtual ~LightObject ()
 
- Protected Attributes inherited from itk::LightObject
std::atomic< int > m_ReferenceCount
 

Detailed Description

Represent a 2D path as a sequence of connected image index offsets.

This class is intended to represent sequences of connected indices in a 2D image plane. It does so by storing the offset of each index from its immediately preceding, connected, index using a standard Freeman code (1=up, 2=up to the right, and so on proceeding clockwise to 8=up to the left). The only image index stored directly is thatof the first index. ChainCodePath2D maps a 1D integer input (step number) to a 2D integer output (either an offset or an image index, depending on whether Evaluate or EvaluateToIndex is called).

See also
ChainCodePath
ParametricPath
Path
Index

Definition at line 51 of file itkChainCodePath2D.h.

Member Typedef Documentation

◆ ChainCode2DType

using itk::ChainCodePath2D::ChainCode2DType = std::vector<int>

ChainCodePath2D stores its data as a Freeman-encoded chain code

Definition at line 82 of file itkChainCodePath2D.h.

◆ ChainCodeSizeType

using itk::ChainCodePath2D::ChainCodeSizeType = Superclass::ChainCodeSizeType

Definition at line 79 of file itkChainCodePath2D.h.

◆ ChainCodeType

using itk::ChainCodePath2D::ChainCodeType = Superclass::ChainCodeType

ChainCodeType is a useless relic of the parent class

Definition at line 78 of file itkChainCodePath2D.h.

◆ ConstPointer

Definition at line 64 of file itkChainCodePath2D.h.

◆ IndexType

Definition at line 75 of file itkChainCodePath2D.h.

◆ InputType

using itk::ChainCodePath2D::InputType = Superclass::InputType

Definition at line 71 of file itkChainCodePath2D.h.

◆ OffsetType

The output type of this function is an Index

Definition at line 74 of file itkChainCodePath2D.h.

◆ OutputType

using itk::ChainCodePath2D::OutputType = Superclass::OutputType

OutputType type alias support

Definition at line 70 of file itkChainCodePath2D.h.

◆ Pointer

Definition at line 63 of file itkChainCodePath2D.h.

◆ Self

Standard class type aliases.

Definition at line 60 of file itkChainCodePath2D.h.

◆ Superclass

Definition at line 61 of file itkChainCodePath2D.h.

Constructor & Destructor Documentation

◆ ChainCodePath2D()

itk::ChainCodePath2D::ChainCodePath2D ( )
protected

Insert a new step into the chaincode at a specified position

◆ ~ChainCodePath2D()

itk::ChainCodePath2D::~ChainCodePath2D ( )
overrideprotected

Insert a new step into the chaincode at a specified position

Member Function Documentation

◆ ChangeStep() [1/2]

void itk::ChainCodePath2D::ChangeStep ( InputType  position,
int  encodedStep 
)
inline

Change the direction of a step in the chaincode

Definition at line 131 of file itkChainCodePath2D.h.

◆ ChangeStep() [2/2]

void itk::ChainCodePath2D::ChangeStep ( InputType  position,
OffsetType  step 
)
inlineoverride

Insert a new step into the chaincode at a specified position

Definition at line 139 of file itkChainCodePath2D.h.

◆ Clear()

void itk::ChainCodePath2D::Clear ( )
inlineoverridevirtual

Remove all steps from the chain code

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 147 of file itkChainCodePath2D.h.

◆ CreateAnother()

virtual::itk::LightObject::Pointer itk::ChainCodePath2D::CreateAnother ( ) const
virtual

Create an object from an instance, potentially deferring to a factory. This method allows you to create an instance of an object that is exactly the same type as the referring object. This is useful in cases where an object has been cast back to a base class.

Reimplemented from itk::Object.

◆ DecodeOffset()

OffsetType itk::ChainCodePath2D::DecodeOffset ( int  encodedStep) const
inlineprotected

Insert a new step into the chaincode at a specified position

Definition at line 171 of file itkChainCodePath2D.h.

◆ EncodeOffset()

int itk::ChainCodePath2D::EncodeOffset ( OffsetType  step) const
inlineprotected

Encode and Decode between an offset and a Freeman code

Definition at line 165 of file itkChainCodePath2D.h.

◆ Evaluate()

OutputType itk::ChainCodePath2D::Evaluate ( const InputType input) const
override

Evaluate the chaincode for the offset at the specified path-position.

◆ EvaluateToIndex()

IndexType itk::ChainCodePath2D::EvaluateToIndex ( const InputType input) const
override

Like Evaluate(), but returns the index at the specified path-position.

◆ GetChainCodeAsString()

std::string itk::ChainCodePath2D::GetChainCodeAsString ( ) const

Insert a new step into the chaincode at a specified position

◆ GetNameOfClass()

virtual const char* itk::ChainCodePath2D::GetNameOfClass ( ) const
virtual

Run-time type information (and related methods).

Reimplemented from itk::ChainCodePath< 2 >.

◆ IncrementInput()

OffsetType itk::ChainCodePath2D::IncrementInput ( InputType input) const
override

Increment the input variable passed by reference and return the offset stored at the previous path-position. If the chaincode is unable to be incremented, input is not changed and an offset of zero is returned, which may be used to check for the end of the chain code.

◆ InsertStep() [1/2]

void itk::ChainCodePath2D::InsertStep ( InputType  position,
int  encodedStep 
)
inline

Insert a new step into the chaincode at a specified position

Definition at line 115 of file itkChainCodePath2D.h.

◆ InsertStep() [2/2]

void itk::ChainCodePath2D::InsertStep ( InputType  position,
OffsetType  step 
)
inlineoverride

Insert a new step into the chaincode at a specified position

Definition at line 123 of file itkChainCodePath2D.h.

◆ New()

static Pointer itk::ChainCodePath2D::New ( )
static

New() method for dynamic construction

◆ NumberOfSteps()

ChainCodeSizeType itk::ChainCodePath2D::NumberOfSteps ( ) const
inlineoverridevirtual

How many steps in the chaincode?

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 108 of file itkChainCodePath2D.h.

◆ PrintSelf()

void itk::ChainCodePath2D::PrintSelf ( std::ostream &  os,
Indent  indent 
) const
overrideprotectedvirtual

Insert a new step into the chaincode at a specified position

Reimplemented from itk::DataObject.

Member Data Documentation

◆ Dimension

constexpr unsigned int itk::ChainCodePath2D::Dimension = 2
staticconstexpr

Dimension underlying input image.

Definition at line 57 of file itkChainCodePath2D.h.

◆ m_Chain2D

ChainCode2DType itk::ChainCodePath2D::m_Chain2D
private

Insert a new step into the chaincode at a specified position

Definition at line 177 of file itkChainCodePath2D.h.

◆ m_FreemanCode

int itk::ChainCodePath2D::m_FreemanCode[3][3]
private

Insert a new step into the chaincode at a specified position

Definition at line 186 of file itkChainCodePath2D.h.

◆ m_ReverseFreemanCode

OffsetType itk::ChainCodePath2D::m_ReverseFreemanCode[9]
private

Insert a new step into the chaincode at a specified position

Definition at line 190 of file itkChainCodePath2D.h.


The documentation for this class was generated from the following file: