DGtal 1.3.0
|
Aim: A class for computing the Gauss digitization of some Euclidean shape, i.e. its intersection with some \( h_1 Z \times h_2 Z \times \cdots \times h_n Z \). Note that the real point (0,...,0) is mapped onto the digital point (0,...,0). More...
#include <DGtal/shapes/GaussDigitizer.h>
Public Types | |
typedef TSpace | Space |
typedef Space::Integer | Integer |
typedef Space::Point | Point |
typedef Space::Vector | Vector |
typedef Space::RealPoint | RealPoint |
typedef Space::RealPoint | RealVector |
typedef TEuclideanShape | EuclideanShape |
typedef HyperRectDomain< Space > | Domain |
typedef RegularPointEmbedder< Space > | PointEmbedder |
Public Member Functions | |
BOOST_CONCEPT_ASSERT ((concepts::CEuclideanOrientedShape< TEuclideanShape >)) | |
~GaussDigitizer () | |
GaussDigitizer () | |
GaussDigitizer & | operator= (const GaussDigitizer &other) |
void | attach (ConstAlias< EuclideanShape > shape) |
void | init (const RealPoint &xLow, const RealPoint &xUp, typename RealVector::Component gridStep) |
void | init (const RealPoint &xLow, const RealPoint &xUp, const RealVector &gridSteps) |
const PointEmbedder & | pointEmbedder () const |
Domain | getDomain () const |
Point | floor (const RealPoint &p) const |
Point | ceil (const RealPoint &p) const |
Point | round (const RealPoint &p) const |
RealPoint | embed (const Point &p) const |
Orientation | orientation (const Point &p) const |
bool | operator() (const Point &p) const |
const Point & | getLowerBound () const |
const Point & | getUpperBound () const |
Vector | resolution () const |
RealVector | gridSteps () const |
void | selfDisplay (std::ostream &out) const |
bool | isValid () const |
Protected Attributes | |
CountedConstPtrOrConstPtr< EuclideanShape > | myEShape |
The referenced shape or 0 if not initialized. More... | |
RegularPointEmbedder< Space > | myPointEmbedder |
The embedder. More... | |
Point | myLowerPoint |
Digital lowest point. More... | |
Point | myUpperPoint |
Digital uppest point. More... | |
Aim: A class for computing the Gauss digitization of some Euclidean shape, i.e. its intersection with some \( h_1 Z \times h_2 Z \times \cdots \times h_n Z \). Note that the real point (0,...,0) is mapped onto the digital point (0,...,0).
Description of template class 'GaussDigitizer'
GaussDigitizer is a model of CDigitalEuclideanShape and CDigitalBoundedShape. It is thus a model of concepts::CPointPredicate. A Gauss digitizer owns a RegularPointEmbedder, a model of CPointEmbedder.
TSpace | the type of digital Space where the digitized object lies. |
TEuclideanShape | a model of CEuclideanOrientedShape and CEuclideanBoundedShape |
Definition at line 79 of file GaussDigitizer.h.
typedef HyperRectDomain<Space> DGtal::GaussDigitizer< TSpace, TEuclideanShape >::Domain |
Definition at line 90 of file GaussDigitizer.h.
typedef TEuclideanShape DGtal::GaussDigitizer< TSpace, TEuclideanShape >::EuclideanShape |
Definition at line 89 of file GaussDigitizer.h.
typedef Space::Integer DGtal::GaussDigitizer< TSpace, TEuclideanShape >::Integer |
Definition at line 84 of file GaussDigitizer.h.
typedef Space::Point DGtal::GaussDigitizer< TSpace, TEuclideanShape >::Point |
Definition at line 85 of file GaussDigitizer.h.
typedef RegularPointEmbedder<Space> DGtal::GaussDigitizer< TSpace, TEuclideanShape >::PointEmbedder |
Definition at line 91 of file GaussDigitizer.h.
typedef Space::RealPoint DGtal::GaussDigitizer< TSpace, TEuclideanShape >::RealPoint |
Definition at line 87 of file GaussDigitizer.h.
typedef Space::RealPoint DGtal::GaussDigitizer< TSpace, TEuclideanShape >::RealVector |
Definition at line 88 of file GaussDigitizer.h.
typedef TSpace DGtal::GaussDigitizer< TSpace, TEuclideanShape >::Space |
Definition at line 83 of file GaussDigitizer.h.
typedef Space::Vector DGtal::GaussDigitizer< TSpace, TEuclideanShape >::Vector |
Definition at line 86 of file GaussDigitizer.h.
DGtal::GaussDigitizer< TSpace, TEuclideanShape >::~GaussDigitizer | ( | ) |
Destructor.
DGtal::GaussDigitizer< TSpace, TEuclideanShape >::GaussDigitizer | ( | ) |
Constructor. The object is not valid.
void DGtal::GaussDigitizer< TSpace, TEuclideanShape >::attach | ( | ConstAlias< EuclideanShape > | shape | ) |
shape | the digitizer now references the given shape. |
Referenced by ballGenerator(), estimatorOnShapeDigitization(), getComplex(), laplace_sphere(), main(), testCombinatorialSurface(), testCompareEstimator(), testCurvature2d(), testDigitalSurfaceBoostGraphInterface(), testDigitization(), testEstimatorCache(), testFitting(), testGaussianCurvature3d(), testMeanCurvature3d(), testPrincipalCurvatures3d(), testRaySurface(), testTrueLocalEstimatorOnShapeDigitization(), and testUmbrellaComputer().
DGtal::GaussDigitizer< TSpace, TEuclideanShape >::BOOST_CONCEPT_ASSERT | ( | (concepts::CEuclideanOrientedShape< TEuclideanShape >) | ) |
Point DGtal::GaussDigitizer< TSpace, TEuclideanShape >::ceil | ( | const RealPoint & | p | ) | const |
p | any point in the Euclidean space. |
RealPoint DGtal::GaussDigitizer< TSpace, TEuclideanShape >::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. |
Referenced by DGtal::GaussDigitizer< TSpace, TEuclideanShape >::orientation().
Point DGtal::GaussDigitizer< TSpace, TEuclideanShape >::floor | ( | const RealPoint & | p | ) | const |
p | any point in the Euclidean space. |
Domain DGtal::GaussDigitizer< TSpace, TEuclideanShape >::getDomain | ( | ) | const |
Referenced by ballGenerator(), estimatorOnShapeDigitization(), laplace_sphere(), main(), testCombinatorialSurface(), testCompareEstimator(), testDigitalSurfaceBoostGraphInterface(), testDigitization(), testTrueLocalEstimatorOnShapeDigitization(), and testUmbrellaComputer().
const Point & DGtal::GaussDigitizer< TSpace, TEuclideanShape >::getLowerBound | ( | ) | const |
Referenced by ballGenerator(), estimatorOnShapeDigitization(), testCompareEstimator(), testCurvature2d(), testDigitization(), testEstimatorCache(), testGaussianCurvature3d(), testMeanCurvature3d(), testPrincipalCurvatures3d(), testRaySurface(), and testTrueLocalEstimatorOnShapeDigitization().
const Point & DGtal::GaussDigitizer< TSpace, TEuclideanShape >::getUpperBound | ( | ) | const |
Referenced by ballGenerator(), estimatorOnShapeDigitization(), testCompareEstimator(), testCurvature2d(), testDigitization(), testEstimatorCache(), testGaussianCurvature3d(), testMeanCurvature3d(), testPrincipalCurvatures3d(), testRaySurface(), and testTrueLocalEstimatorOnShapeDigitization().
RealVector DGtal::GaussDigitizer< TSpace, TEuclideanShape >::gridSteps | ( | ) | const |
void DGtal::GaussDigitizer< TSpace, TEuclideanShape >::init | ( | const RealPoint & | xLow, |
const RealPoint & | xUp, | ||
const RealVector & | gridSteps | ||
) |
Initializes the digital bounds of the digitizer so as to cover at least the space specified by [xLow] and [xUp]. The real vector [gridSteps] specifies the grid steps in each direction.
xLow | Euclidean lower bound for the digitizer. |
xUp | Euclidean upper bound for the digitizer. |
gridSteps | the grid steps in each direction. |
void DGtal::GaussDigitizer< TSpace, TEuclideanShape >::init | ( | const RealPoint & | xLow, |
const RealPoint & | xUp, | ||
typename RealVector::Component | gridStep | ||
) |
Initializes the digital bounds of the digitizer so as to cover at least the space specified by [xLow] and [xUp]. The real value [gridStep] specifies the same grid step in every direction.
xLow | Euclidean lower bound for the digitizer. |
xUp | Euclidean upper bound for the digitizer. |
gridStep | the grid step (distance between two embedded adjacent digital points) identical in every direction. |
Referenced by ballGenerator(), estimatorOnShapeDigitization(), laplace_sphere(), main(), testCombinatorialSurface(), testCompareEstimator(), testCurvature2d(), testDigitalSurfaceBoostGraphInterface(), testDigitization(), testEstimatorCache(), testGaussianCurvature3d(), testMeanCurvature3d(), testPrincipalCurvatures3d(), testRaySurface(), testTrueLocalEstimatorOnShapeDigitization(), and testUmbrellaComputer().
bool DGtal::GaussDigitizer< TSpace, TEuclideanShape >::isValid | ( | ) | const |
Checks the validity/consistency of the object.
bool DGtal::GaussDigitizer< TSpace, TEuclideanShape >::operator() | ( | const Point & | p | ) | const |
p | any point in the digital plane. |
GaussDigitizer & DGtal::GaussDigitizer< TSpace, TEuclideanShape >::operator= | ( | const GaussDigitizer< TSpace, TEuclideanShape > & | other | ) |
Assignment. Required by concepts::CPointPredicate.
other | the object to copy. |
|
inline |
Orientation method to match with CDigitalOrientedShape concept.
p | a digital point |
Definition at line 194 of file GaussDigitizer.h.
References DGtal::GaussDigitizer< TSpace, TEuclideanShape >::embed(), and DGtal::GaussDigitizer< TSpace, TEuclideanShape >::myEShape.
const PointEmbedder & DGtal::GaussDigitizer< TSpace, TEuclideanShape >::pointEmbedder | ( | ) | const |
Referenced by main().
Vector DGtal::GaussDigitizer< TSpace, TEuclideanShape >::resolution | ( | ) | const |
Point DGtal::GaussDigitizer< TSpace, TEuclideanShape >::round | ( | const RealPoint & | p | ) | const |
p | any point in the Euclidean space. |
void DGtal::GaussDigitizer< TSpace, TEuclideanShape >::selfDisplay | ( | std::ostream & | out | ) | const |
Writes/Displays the object on an output stream.
out | the output stream where the object is written. |
|
protected |
The referenced shape or 0 if not initialized.
Definition at line 248 of file GaussDigitizer.h.
Referenced by DGtal::GaussDigitizer< TSpace, TEuclideanShape >::orientation().
|
protected |
Digital lowest point.
Definition at line 254 of file GaussDigitizer.h.
|
protected |
The embedder.
Definition at line 251 of file GaussDigitizer.h.
|
protected |
Digital uppest point.
Definition at line 257 of file GaussDigitizer.h.