DGtal  0.6.devel
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Types | Public Member Functions | Private Attributes
DGtal::SCellToOuterPoint< KSpace > Class Template Reference

#include <SCellsFunctors.h>

Public Types

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

Public Member Functions

 SCellToOuterPoint ()
 SCellToOuterPoint (const KSpace &aK)
 SCellToOuterPoint (const SCellToOuterPoint &other)
SCellToOuterPointoperator= (const SCellToOuterPoint &other)
Output operator() (const Input &s) const

Private Attributes

const KSpace * myK

Detailed Description

template<typename KSpace>
class DGtal::SCellToOuterPoint< KSpace >

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

Description of template class 'SCellToOuterPoint'

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

Template Parameters:
KSpacethe Khalimsky space
See also:
SCellToPoint SCellToInnerPoint ConstIteratorAdapter KhalimskySpaceND PointVector

Definition at line 387 of file SCellsFunctors.h.


Member Typedef Documentation

template<typename KSpace>
typedef KSpace::SCell DGtal::SCellToOuterPoint< KSpace >::Input

Definition at line 392 of file SCellsFunctors.h.

template<typename KSpace>
typedef KSpace::Point DGtal::SCellToOuterPoint< KSpace >::Output

Definition at line 391 of file SCellsFunctors.h.


Constructor & Destructor Documentation

template<typename KSpace>
DGtal::SCellToOuterPoint< KSpace >::SCellToOuterPoint ( )
inline

Default constructor.

Definition at line 405 of file SCellsFunctors.h.

: myK(NULL) { }
template<typename KSpace>
DGtal::SCellToOuterPoint< KSpace >::SCellToOuterPoint ( const KSpace &  aK)
inline

Constructor.

Parameters:
aKa Khalimsky space

Definition at line 410 of file SCellsFunctors.h.

: myK(&aK) { }
template<typename KSpace>
DGtal::SCellToOuterPoint< KSpace >::SCellToOuterPoint ( const SCellToOuterPoint< KSpace > &  other)
inline

Copy constructor.

Parameters:
otherany SCellToOuterPoint modifier

Definition at line 416 of file SCellsFunctors.h.

: myK(other.myK) { }

Member Function Documentation

template<typename KSpace>
Output DGtal::SCellToOuterPoint< KSpace >::operator() ( const Input s) const
inline

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

Parameters:
sa linel
Returns:
the outer pixel center

Definition at line 438 of file SCellsFunctors.h.

References DGtal::SCellToOuterPoint< KSpace >::myK.

{
ASSERT( myK );
Input pixel( myK->sDirectIncident( s, *myK->sOrthDirs( s ) ) );
return Output( myK->sCoords( pixel ) ); //integer coordinates
}
template<typename KSpace>
SCellToOuterPoint& DGtal::SCellToOuterPoint< KSpace >::operator= ( const SCellToOuterPoint< KSpace > &  other)
inline

Assignment.

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

Definition at line 424 of file SCellsFunctors.h.

References DGtal::SCellToOuterPoint< KSpace >::myK.

{
if (this != &other)
{
myK = other.myK;
}
return *this;
}

Field Documentation

template<typename KSpace>
const KSpace* DGtal::SCellToOuterPoint< KSpace >::myK
private

Aliasing pointer on the Khalimsky space.

Definition at line 398 of file SCellsFunctors.h.

Referenced by DGtal::SCellToOuterPoint< KSpace >::operator()(), and DGtal::SCellToOuterPoint< KSpace >::operator=().


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