DGtal  1.4.2
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
DGtal::L1LocalDistance< TImage, TSet > Class Template Reference

Aim: Class for the computation of the L1-distance at some point p, from the available distance values of some points lying in the 1-neighborhood of p (ie. points at a L1-distance to p equal to 1). More...

#include <DGtal/geometry/volumes/distance/FMMPointFunctors.h>

Public Types

typedef TImage Image
 
typedef Image::Point Point
 
typedef Image::Value Value
 
typedef TSet Set
 

Public Member Functions

 BOOST_CONCEPT_ASSERT ((concepts::CImage< TImage >))
 image More...
 
 BOOST_CONCEPT_ASSERT ((concepts::CDigitalSet< TSet >))
 set More...
 
 BOOST_STATIC_ASSERT ((boost::is_same< Point, typename TSet::Point >::value))
 
 L1LocalDistance (Image &aImg, TSet &aSet)
 
 L1LocalDistance (const L1LocalDistance &other)
 
L1LocalDistanceoperator= (const L1LocalDistance &other)
 
 ~L1LocalDistance ()
 
Value operator() (const Point &aPoint)
 
void selfDisplay (std::ostream &out) const
 

Data Fields

ImagemyImgPtr
 Aliasing pointer on the underlying image. More...
 
SetmySetPtr
 Aliasing pointer on the underlying set. More...
 

Private Types

typedef std::vector< ValueValues
 

Private Member Functions

Value compute (Values &aValueList) const
 

Detailed Description

template<typename TImage, typename TSet>
class DGtal::L1LocalDistance< TImage, TSet >

Aim: Class for the computation of the L1-distance at some point p, from the available distance values of some points lying in the 1-neighborhood of p (ie. points at a L1-distance to p equal to 1).

Description of template class 'L1LocalDistance'

The computed value is merely the minimum over all the available distance values in the 1-neighborhood of p, plus one.

It is a model of CPointFunctor.

Template Parameters
TImagemodel of CImage used for the mapping point-distance value
TSetmodel of CDigitalSet for storing points whose distance value is known
See also
FMM

Definition at line 472 of file FMMPointFunctors.h.

Member Typedef Documentation

◆ Image

template<typename TImage , typename TSet >
typedef TImage DGtal::L1LocalDistance< TImage, TSet >::Image

Definition at line 480 of file FMMPointFunctors.h.

◆ Point

template<typename TImage , typename TSet >
typedef Image::Point DGtal::L1LocalDistance< TImage, TSet >::Point

Definition at line 481 of file FMMPointFunctors.h.

◆ Set

template<typename TImage , typename TSet >
typedef TSet DGtal::L1LocalDistance< TImage, TSet >::Set

Definition at line 486 of file FMMPointFunctors.h.

◆ Value

template<typename TImage , typename TSet >
typedef Image::Value DGtal::L1LocalDistance< TImage, TSet >::Value

Definition at line 482 of file FMMPointFunctors.h.

◆ Values

template<typename TImage , typename TSet >
typedef std::vector<Value> DGtal::L1LocalDistance< TImage, TSet >::Values
private

Definition at line 491 of file FMMPointFunctors.h.

Constructor & Destructor Documentation

◆ L1LocalDistance() [1/2]

template<typename TImage , typename TSet >
DGtal::L1LocalDistance< TImage, TSet >::L1LocalDistance ( Image aImg,
TSet &  aSet 
)

Constructor from an image and a set. NB: only pointers are stored

Parameters
aImgany distance map
aSetany digital set

◆ L1LocalDistance() [2/2]

template<typename TImage , typename TSet >
DGtal::L1LocalDistance< TImage, TSet >::L1LocalDistance ( const L1LocalDistance< TImage, TSet > &  other)

Copy constructor.

Parameters
otherthe object to clone.

◆ ~L1LocalDistance()

template<typename TImage , typename TSet >
DGtal::L1LocalDistance< TImage, TSet >::~L1LocalDistance ( )

Destructor. Does nothing.

Member Function Documentation

◆ BOOST_CONCEPT_ASSERT() [1/2]

template<typename TImage , typename TSet >
DGtal::L1LocalDistance< TImage, TSet >::BOOST_CONCEPT_ASSERT ( (concepts::CDigitalSet< TSet >)  )

set

◆ BOOST_CONCEPT_ASSERT() [2/2]

template<typename TImage , typename TSet >
DGtal::L1LocalDistance< TImage, TSet >::BOOST_CONCEPT_ASSERT ( (concepts::CImage< TImage >)  )

image

◆ BOOST_STATIC_ASSERT()

template<typename TImage , typename TSet >
DGtal::L1LocalDistance< TImage, TSet >::BOOST_STATIC_ASSERT ( (boost::is_same< Point, typename TSet::Point >::value)  )

◆ compute()

template<typename TImage , typename TSet >
Value DGtal::L1LocalDistance< TImage, TSet >::compute ( Values aValueList) const
private

Returns the L1-distance at some point, knowing the distance of its neighbors

Parameters
aValueListthe distance of (some of) the neighbors
Returns
the computed distance.

◆ operator()()

template<typename TImage , typename TSet >
Value DGtal::L1LocalDistance< TImage, TSet >::operator() ( const Point aPoint)

L1-distance computation at aPoint , from the available distance values of the 1-neighbors of aPoint .

Parameters
aPointthe point for which the distance is computed
Returns
the distance value at aPoint.

◆ operator=()

template<typename TImage , typename TSet >
L1LocalDistance& DGtal::L1LocalDistance< TImage, TSet >::operator= ( const L1LocalDistance< TImage, TSet > &  other)

Assignment.

Parameters
otherthe object to copy.
Returns
a reference on 'this'.

◆ selfDisplay()

template<typename TImage , typename TSet >
void DGtal::L1LocalDistance< TImage, TSet >::selfDisplay ( std::ostream &  out) const

Writes/Displays the object on an output stream.

Parameters
outthe output stream where the object is written.

Field Documentation

◆ myImgPtr

template<typename TImage , typename TSet >
Image* DGtal::L1LocalDistance< TImage, TSet >::myImgPtr

Aliasing pointer on the underlying image.

Definition at line 496 of file FMMPointFunctors.h.

◆ mySetPtr

template<typename TImage , typename TSet >
Set* DGtal::L1LocalDistance< TImage, TSet >::mySetPtr

Aliasing pointer on the underlying set.

Definition at line 498 of file FMMPointFunctors.h.


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