DGtal 1.3.0
|
Aim: A simple point embedder where grid steps are given for each axis. Note that the real point (0,...,0) is mapped onto the digital point (0,...,0). More...
#include <DGtal/kernel/RegularPointEmbedder.h>
Public Types | |
typedef TSpace | Space |
typedef Space::Point | Point |
typedef Space::RealPoint | RealPoint |
typedef Point | Argument |
typedef RealPoint | Value |
typedef Space::Integer | Integer |
typedef Space::RealVector | RealVector |
Public Member Functions | |
~RegularPointEmbedder () | |
RegularPointEmbedder () | |
RegularPointEmbedder & | operator= (const RegularPointEmbedder &other) |
void | init (typename RealVector::Component gridStep) |
void | init (const RealVector &gridSteps) |
Point | floor (const RealPoint &p) const |
Point | ceil (const RealPoint &p) const |
Point | round (const RealPoint &p) const |
RealPoint | embed (const Point &p) const |
RealPoint | operator() (const Point &p) const |
RealVector | gridSteps () const |
void | selfDisplay (std::ostream &out) const |
bool | isValid () const |
Protected Attributes | |
RealVector | myGridSteps |
The grid steps. More... | |
Private Member Functions | |
BOOST_CONCEPT_ASSERT ((concepts::CSpace< TSpace >)) | |
Aim: A simple point embedder where grid steps are given for each axis. Note that the real point (0,...,0) is mapped onto the digital point (0,...,0).
Description of template class 'RegularPointEmbedder'
RegularPointEmbedder is a model of CPointEmbedder.
TSpace | the type of digital Space where the digitized object lies. A model of CSpace. |
Definition at line 68 of file RegularPointEmbedder.h.
typedef Point DGtal::RegularPointEmbedder< TSpace >::Argument |
Definition at line 77 of file RegularPointEmbedder.h.
typedef Space::Integer DGtal::RegularPointEmbedder< TSpace >::Integer |
Definition at line 80 of file RegularPointEmbedder.h.
typedef Space::Point DGtal::RegularPointEmbedder< TSpace >::Point |
Definition at line 75 of file RegularPointEmbedder.h.
typedef Space::RealPoint DGtal::RegularPointEmbedder< TSpace >::RealPoint |
Definition at line 76 of file RegularPointEmbedder.h.
typedef Space::RealVector DGtal::RegularPointEmbedder< TSpace >::RealVector |
Definition at line 81 of file RegularPointEmbedder.h.
typedef TSpace DGtal::RegularPointEmbedder< TSpace >::Space |
Definition at line 74 of file RegularPointEmbedder.h.
typedef RealPoint DGtal::RegularPointEmbedder< TSpace >::Value |
Definition at line 78 of file RegularPointEmbedder.h.
DGtal::RegularPointEmbedder< TSpace >::~RegularPointEmbedder | ( | ) |
Destructor.
DGtal::RegularPointEmbedder< TSpace >::RegularPointEmbedder | ( | ) |
Constructor. The object is not valid.
|
private |
Point DGtal::RegularPointEmbedder< TSpace >::ceil | ( | const RealPoint & | p | ) | const |
p | any point in the Euclidean space. |
RealPoint DGtal::RegularPointEmbedder< TSpace >::embed | ( | const Point & | p | ) | const |
Map a digital point to its corresponding point in the Eucldiean space.
p | any digital point in the digital space. |
Point DGtal::RegularPointEmbedder< TSpace >::floor | ( | const RealPoint & | p | ) | const |
p | any point in the Euclidean space. |
RealVector DGtal::RegularPointEmbedder< TSpace >::gridSteps | ( | ) | const |
void DGtal::RegularPointEmbedder< TSpace >::init | ( | const RealVector & | gridSteps | ) |
Initializes the embedder. The real vector [gridSteps] specifies the grid steps in each direction.
gridSteps | the grid steps in each direction. |
void DGtal::RegularPointEmbedder< TSpace >::init | ( | typename RealVector::Component | gridStep | ) |
Initializes the embedder. The real value [gridStep] specifies the same grid step in every direction.
gridStep | the grid step (distance between two embedded adjacent digital points) identical in every direction. |
Referenced by main().
bool DGtal::RegularPointEmbedder< TSpace >::isValid | ( | ) | const |
Checks the validity/consistency of the object.
RealPoint DGtal::RegularPointEmbedder< TSpace >::operator() | ( | const Point & | p | ) | const |
Map a digital point to its corresponding point in the Eucldiean space.
p | any digital point in the digital space. |
RegularPointEmbedder & DGtal::RegularPointEmbedder< TSpace >::operator= | ( | const RegularPointEmbedder< TSpace > & | other | ) |
Assignment. Required by concepts::CPointPredicate.
other | the object to copy. |
Point DGtal::RegularPointEmbedder< TSpace >::round | ( | const RealPoint & | p | ) | const |
p | any point in the Euclidean space. |
void DGtal::RegularPointEmbedder< TSpace >::selfDisplay | ( | std::ostream & | out | ) | const |
Writes/Displays the object on an output stream.
out | the output stream where the object is written. |
|
protected |
The grid steps.
Definition at line 180 of file RegularPointEmbedder.h.