Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itk::ChainCodePath2D Class Reference
[Path Representation Objects]

#include <itkChainCodePath2D.h>

Inheritance diagram for itk::ChainCodePath2D:

Inheritance graph
[legend]
Collaboration diagram for itk::ChainCodePath2D:

Collaboration graph
[legend]
List of all members.

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 preceeding, 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 interger 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 53 of file itkChainCodePath2D.h.

Public Types

typedef std::vector< int > ChainCode2DType
typedef std::vector< OffsetTypeChainCodeType
typedef SmartPointer< const
Self
ConstPointer
typedef Index< 2 > IndexType
typedef Superclass::InputType InputType
typedef OutputType OffsetType
typedef Superclass::OutputType OutputType
typedef SmartPointer< SelfPointer
typedef ChainCodePath2D Self
typedef ChainCodePath< 2 > Superclass

Public Member Functions

void ChangeStep (InputType position, OffsetType step)
Change the direction of a
step in the chaincode *void 
ChangeStep (InputType position, int encodedStep)
Remove all steps from the
chain code *virtual void 
Clear ()
virtual InputType EndOfInput () const
virtual OutputType Evaluate (const InputType &input) const
virtual IndexType EvaluateToIndex (const InputType &input) const
std::string GetChainCodeAsString (void) const
virtual const char * GetNameOfClass () const
virtual const IndexTypeGetStart ()
virtual OffsetType IncrementInput (InputType &input) const
Needed for Pipelining *virtual
void 
Initialize (void)
void InsertStep (InputType position, OffsetType step)
Insert a new step into the
chaincode at a specified position
*void 
InsertStep (InputType position, int encodedStep)
 itkStaticConstMacro (PathDimension, unsigned int, VDimension)
 itkStaticConstMacro (Dimension, unsigned int, VDimension)
 itkStaticConstMacro (Dimension, unsigned int, 2)
unsigned int NumberOfSteps () const
Set Get the index associated
with the initial position
of the path *virtual void 
SetStart (IndexType _arg)
virtual InputType StartOfInput () const

Static Public Member Functions

static Pointer New ()

Protected Member Functions

 ChainCodePath ()
 ChainCodePath2D ()
OffsetType DecodeOffset (int encodedStep) const
Encode and Decode between
an offset and a Freeman code
*int 
EncodeOffset (OffsetType step) const
virtual IndexType GetZeroIndex () const
virtual OffsetType GetZeroOffset () const
 Path ()
void PrintSelf (std::ostream &os, Indent indent) const
 ~ChainCodePath2D ()


Member Typedef Documentation

typedef std::vector<int> itk::ChainCodePath2D::ChainCode2DType
 

ChainCodePath2D stores its data as a Freeman-encoded chain code

Definition at line 82 of file itkChainCodePath2D.h.

typedef std::vector<OffsetType> itk::ChainCodePath2D::ChainCodeType
 

ChainCodeType is a usless relic of the parent class

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 79 of file itkChainCodePath2D.h.

typedef SmartPointer<const Self> itk::ChainCodePath2D::ConstPointer
 

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 65 of file itkChainCodePath2D.h.

typedef Index<2> itk::ChainCodePath2D::IndexType
 

All paths must be mapable to index space

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 76 of file itkChainCodePath2D.h.

typedef Superclass::InputType itk::ChainCodePath2D::InputType
 

Input type

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 72 of file itkChainCodePath2D.h.

typedef OutputType itk::ChainCodePath2D::OffsetType
 

The output type of this function is an Index

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 75 of file itkChainCodePath2D.h.

typedef Superclass::OutputType itk::ChainCodePath2D::OutputType
 

OutputType typedef support.

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 68 of file itkChainCodePath2D.h.

typedef SmartPointer<Self> itk::ChainCodePath2D::Pointer
 

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 64 of file itkChainCodePath2D.h.

typedef ChainCodePath2D itk::ChainCodePath2D::Self
 

Standard class typedefs.

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 61 of file itkChainCodePath2D.h.

typedef ChainCodePath<2> itk::ChainCodePath2D::Superclass
 

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 62 of file itkChainCodePath2D.h.


Constructor & Destructor Documentation

itk::ChainCodePath2D::ChainCodePath2D  )  [protected]
 

itk::ChainCodePath2D::~ChainCodePath2D  )  [protected]
 


Member Function Documentation

itk::ChainCodePath< VDimension >::ChainCodePath  )  [protected, inherited]
 

void itk::ChainCodePath2D::ChangeStep InputType  position,
OffsetType  step
[inline, virtual]
 

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 126 of file itkChainCodePath2D.h.

Change the direction of a step in the chaincode* void itk::ChainCodePath2D::ChangeStep InputType  position,
int  encodedStep
[inline]
 

Definition at line 121 of file itkChainCodePath2D.h.

Remove all steps from the chain code* virtual void itk::ChainCodePath2D::Clear  )  [inline, virtual]
 

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 134 of file itkChainCodePath2D.h.

OffsetType itk::ChainCodePath2D::DecodeOffset int  encodedStep  )  const [inline, protected]
 

Definition at line 153 of file itkChainCodePath2D.h.

Encode and Decode between an offset and a Freeman code* int itk::ChainCodePath2D::EncodeOffset OffsetType  step  )  const [inline, protected]
 

Definition at line 149 of file itkChainCodePath2D.h.

virtual InputType itk::ChainCodePath< VDimension >::EndOfInput  )  const [inline, virtual, inherited]
 

Where does the path end (what is the last valid input value)?

Reimplemented from itk::Path< unsigned int, Offset< VDimension >, VDimension >.

Definition at line 95 of file itkChainCodePath.h.

virtual OutputType itk::ChainCodePath2D::Evaluate const InputType input  )  const [virtual]
 

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

Reimplemented from itk::ChainCodePath< 2 >.

virtual IndexType itk::ChainCodePath2D::EvaluateToIndex const InputType input  )  const [virtual]
 

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

Reimplemented from itk::ChainCodePath< 2 >.

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

virtual const char* itk::ChainCodePath2D::GetNameOfClass  )  const [virtual]
 

Run-time type information (and related methods).

Reimplemented from itk::ChainCodePath< 2 >.

virtual const IndexType& itk::ChainCodePath< VDimension >::GetStart  )  [virtual, inherited]
 

virtual IndexType itk::Path< unsigned int , Offset< VDimension > , VDimension >::GetZeroIndex  )  const [protected, virtual, inherited]
 

virtual OffsetType itk::Path< unsigned int , Offset< VDimension > , VDimension >::GetZeroOffset  )  const [protected, virtual, inherited]
 

virtual OffsetType itk::ChainCodePath2D::IncrementInput InputType input  )  const [virtual]
 

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.

Reimplemented from itk::ChainCodePath< 2 >.

Needed for Pipelining* virtual void itk::ChainCodePath< VDimension >::Initialize void   )  [inline, virtual, inherited]
 

Definition at line 143 of file itkChainCodePath.h.

void itk::ChainCodePath2D::InsertStep InputType  position,
OffsetType  step
[inline, virtual]
 

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 113 of file itkChainCodePath2D.h.

Insert a new step into the chaincode at a specified position* void itk::ChainCodePath2D::InsertStep InputType  position,
int  encodedStep
[inline]
 

Definition at line 108 of file itkChainCodePath2D.h.

itk::Path< unsigned int , Offset< VDimension > , VDimension >::itkStaticConstMacro PathDimension  ,
unsigned  int,
VDimension 
[inherited]
 

Path dimension. The dimension of a path is fixed at construction.

itk::ChainCodePath< VDimension >::itkStaticConstMacro Dimension  ,
unsigned  int,
VDimension 
[inherited]
 

Dimension underlying input image.

itk::ChainCodePath2D::itkStaticConstMacro Dimension  ,
unsigned  int,
 

Dimension underlying input image.

static Pointer itk::ChainCodePath2D::New  )  [static]
 

New() method for dynamic construction

Reimplemented from itk::ChainCodePath< 2 >.

unsigned int itk::ChainCodePath2D::NumberOfSteps  )  const [inline, virtual]
 

How many steps in the chaincode?

Reimplemented from itk::ChainCodePath< 2 >.

Definition at line 104 of file itkChainCodePath2D.h.

itk::Path< unsigned int , Offset< VDimension > , VDimension >::Path  )  [protected, inherited]
 

void itk::ChainCodePath2D::PrintSelf std::ostream &  os,
Indent  indent
const [protected]
 

Reimplemented from itk::ChainCodePath< 2 >.

Set Get the index associated with the initial position of the path* virtual void itk::ChainCodePath< VDimension >::SetStart IndexType  _arg  )  [virtual, inherited]
 

virtual InputType itk::Path< unsigned int , Offset< VDimension > , VDimension >::StartOfInput  )  const [inline, virtual, inherited]
 

Where does the path begin? For most types of paths, the path will begin at zero. This value can be overridden in children, and is necessary for iterators to know how to go to the beginning of a path.

Definition at line 79 of file itkPath.h.


The documentation for this class was generated from the following file:
Generated at Sun Jul 9 19:12:58 2006 for ITK by doxygen 1.4.2 written by Dimitri van Heesch, © 1997-2000