File failed to load: https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.3/config/TeX-MML-AM_CHTML/MathJax.js
DGtal 2.0.0
DGtal::functors::SCellToInnerPoint< KSpace > Class Template Reference

Aim: transforms a signed cell c into a point corresponding to the signed cell of greater dimension that is indirectly incident to c. More...

#include <DGtal/topology/SCellsFunctors.h>

Public Types

typedef KSpace::Point Output
typedef KSpace::SCell Input

Public Member Functions

 SCellToInnerPoint ()
 SCellToInnerPoint (ConstAlias< KSpace > aK)
 SCellToInnerPoint (const SCellToInnerPoint &other)
SCellToInnerPointoperator= (const SCellToInnerPoint &other)
Output operator() (const Input &s) const

Private Attributes

const KSpacemyK

Detailed Description

template<typename KSpace>
class DGtal::functors::SCellToInnerPoint< KSpace >

Aim: transforms a signed cell c into a point corresponding to the signed cell of greater dimension that is indirectly incident to c.

Description of template class 'SCellToInnerPoint'

For instance, a linel is mapped into the indirect incident pixel center and a surfel is mapped into the indirect incident voxel center.

Template Parameters
KSpacethe Khalimsky space
See also
SCellToPoint SCellToOuterPoint ConstIteratorAdapter KhalimskySpaceND PointVector
Examples
tutorial-examples/FMMErosion.cpp.

Definition at line 234 of file SCellsFunctors.h.

Member Typedef Documentation

◆ Input

template<typename KSpace>
typedef KSpace::SCell DGtal::functors::SCellToInnerPoint< KSpace >::Input

Definition at line 240 of file SCellsFunctors.h.

◆ Output

template<typename KSpace>
typedef KSpace::Point DGtal::functors::SCellToInnerPoint< KSpace >::Output

Definition at line 239 of file SCellsFunctors.h.

Constructor & Destructor Documentation

◆ SCellToInnerPoint() [1/3]

template<typename KSpace>
DGtal::functors::SCellToInnerPoint< KSpace >::SCellToInnerPoint ( )
inline

Default constructor.

Definition at line 253 of file SCellsFunctors.h.

253: myK(NULL) { }
Aim: transforms a signed cell c into a point corresponding to the signed cell of greater dimension th...

References myK.

Referenced by operator=(), and SCellToInnerPoint().

◆ SCellToInnerPoint() [2/3]

template<typename KSpace>
DGtal::functors::SCellToInnerPoint< KSpace >::SCellToInnerPoint ( ConstAlias< KSpace > aK)
inline

Constructor.

Parameters
aKa Khalimsky space

Definition at line 258 of file SCellsFunctors.h.

258: myK(&aK) { }

References myK.

◆ SCellToInnerPoint() [3/3]

template<typename KSpace>
DGtal::functors::SCellToInnerPoint< KSpace >::SCellToInnerPoint ( const SCellToInnerPoint< KSpace > & other)
inline

Copy constructor.

Parameters
otherany SCellToInnerPoint functor

Definition at line 264 of file SCellsFunctors.h.

265 : myK(other.myK) { }

References myK, and SCellToInnerPoint().

Member Function Documentation

◆ operator()()

template<typename KSpace>
Output DGtal::functors::SCellToInnerPoint< KSpace >::operator() ( const Input & s) const
inline

Return a point (integer coordinates) from a scell (khalimsky coordinates)

Parameters
sa linel
Returns
the inner pixel center

Definition at line 286 of file SCellsFunctors.h.

287 {
288 ASSERT( myK );
289 Input pixel( myK->sDirectIncident( s, *myK->sOrthDirs( s ) ) );
290 return Output( myK->sCoords( pixel ) ); //integer coordinates
291 }

References myK.

◆ operator=()

template<typename KSpace>
SCellToInnerPoint & DGtal::functors::SCellToInnerPoint< KSpace >::operator= ( const SCellToInnerPoint< KSpace > & other)
inline

Assignment.

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

Definition at line 272 of file SCellsFunctors.h.

273 {
274 if (this != &other)
275 {
276 myK = other.myK;
277 }
278 return *this;
279 }

References myK, and SCellToInnerPoint().

Field Documentation

◆ myK

template<typename KSpace>
const KSpace* DGtal::functors::SCellToInnerPoint< KSpace >::myK
private

Aliasing pointer on the Khalimsky space.

Definition at line 246 of file SCellsFunctors.h.

Referenced by operator()(), operator=(), SCellToInnerPoint(), SCellToInnerPoint(), and SCellToInnerPoint().


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