|
DGtal 2.0.0
|
Aim: A utility class for constructing different shapes (balls, diamonds, and others). More...
#include <DGtal/shapes/Shapes.h>
Public Types | |
| typedef TDomain | Domain |
| typedef Domain::Space | Space |
| typedef Domain::Space::RealPoint | RealPoint |
| typedef Domain::Point | Point |
| typedef Domain::Vector | Vector |
| typedef Domain::Predicate | Predicate |
| typedef Domain::ConstIterator | ConstIterator |
| typedef Space::Integer | Integer |
| typedef Space::UnsignedInteger | UnsignedInteger |
Public Member Functions | |
| ~Shapes () | |
| void | selfDisplay (std::ostream &out) const |
| bool | isValid () const |
Static Public Member Functions | |
| template<typename TDigitalSet, typename TShapeFunctor> | |
| static void | digitalShaper (TDigitalSet &aSet, const TShapeFunctor &aFunctor) |
| template<typename TDigitalSet, typename TShapeFunctor> | |
| static void | euclideanShaper (TDigitalSet &aSet, const TShapeFunctor &aFunctor, const double h=1.0) |
| template<typename DigitalSet, typename PointPredicate> | |
| static void | makeSetFromPointPredicate (DigitalSet &aSet, const PointPredicate &aPP) |
| template<typename TDigitalSet> | |
| static void | addNorm1Ball (TDigitalSet &aSet, const Point &aCenter, UnsignedInteger aRadius) |
| template<typename TDigitalSet> | |
| static void | addNorm2Ball (TDigitalSet &aSet, const Point &aCenter, UnsignedInteger aRadius) |
| template<typename TDigitalSet> | |
| static void | removeNorm1Ball (TDigitalSet &aSet, const Point &aCenter, UnsignedInteger aRadius) |
| template<typename TDigitalSet> | |
| static void | removeNorm2Ball (TDigitalSet &aSet, const Point &aCenter, UnsignedInteger aRadius) |
Protected Member Functions | |
| Shapes () | |
Private Member Functions | |
| BOOST_CONCEPT_ASSERT ((concepts::CDomain< TDomain >)) | |
| Shapes (const Shapes &other) | |
| Shapes & | operator= (const Shapes &other) |
Aim: A utility class for constructing different shapes (balls, diamonds, and others).
Description of template class 'Shapes'
| TDomain | the type of the domain in which shapes are created. |
Definition at line 71 of file DGtal/shapes/Shapes.h.
| typedef Domain::ConstIterator DGtal::Shapes< TDomain >::ConstIterator |
Definition at line 84 of file DGtal/shapes/Shapes.h.
| typedef TDomain DGtal::Shapes< TDomain >::Domain |
Definition at line 78 of file DGtal/shapes/Shapes.h.
| typedef Space::Integer DGtal::Shapes< TDomain >::Integer |
Definition at line 86 of file DGtal/shapes/Shapes.h.
| typedef Domain::Point DGtal::Shapes< TDomain >::Point |
Definition at line 81 of file DGtal/shapes/Shapes.h.
| typedef Domain::Predicate DGtal::Shapes< TDomain >::Predicate |
Definition at line 83 of file DGtal/shapes/Shapes.h.
| typedef Domain::Space::RealPoint DGtal::Shapes< TDomain >::RealPoint |
Definition at line 80 of file DGtal/shapes/Shapes.h.
| typedef Domain::Space DGtal::Shapes< TDomain >::Space |
Definition at line 79 of file DGtal/shapes/Shapes.h.
| typedef Space::UnsignedInteger DGtal::Shapes< TDomain >::UnsignedInteger |
Definition at line 87 of file DGtal/shapes/Shapes.h.
| typedef Domain::Vector DGtal::Shapes< TDomain >::Vector |
Definition at line 82 of file DGtal/shapes/Shapes.h.
| DGtal::Shapes< TDomain >::~Shapes | ( | ) |
Destructor.
|
protected |
Constructor. Forbidden by default (protected to avoid g++ warnings).
Referenced by operator=(), and Shapes().
|
private |
|
static |
Adds the discrete ball (norm-1) of center [aCenter] and radius [aRadius] to the (perhaps non empty) set [aSet].
| TDigitalSet | the type chosen for the digital set. |
| aSet | the set (modified) which will contain the discrete ball. |
| aCenter | the center of the ball. |
| aRadius | the radius of the ball. |
Referenced by main(), main(), main(), Objects2D::Objects2D(), testBreadthFirstPropagation(), testDepthFirstPropagation(), testDistancePropagation(), testSetTable(), testSimplePoints2D(), and testSurfelAdjacency().
|
static |
Adds the discrete ball (norm-2) of center [aCenter] and radius [aRadius] to the (perhaps non empty) set [aSet].
| TDigitalSet | the type chosen for the digital set. |
| aSet | the set (modified) which will contain the discrete ball. |
| aCenter | the center of the ball. |
| aRadius | the radius of the ball. |
Referenced by main(), main(), SCENARIO(), SCENARIO(), SCENARIO(), SCENARIO(), SCENARIO(), SCENARIO(), testBreadthFirstPropagation(), testDepthFirstPropagation(), testDigitalSetBoundary(), testDigitalSurface(), testDistancePropagation(), testFindABel(), and testKanungo2D().
|
private |
|
static |
Adds to the (perhaps non empty) set [aSet] an shape defined by an instance of ShapeFunctor. Add Points where orientation is inside. The shape functor must be a model of CDigitalOrientedShape and CDigitalBoundedShape.
| aSet | the set (modified) which will contain the shape. |
| aFunctor | a functor defining the shape. |
| TDigitalSet | a model of CDigitalSet. |
| TShapeFunctor | a model of CDigitalBoundedShape and CDigitalOrientedShape. |
Referenced by testDigitalSetToCellularGridConverter::extractCells(), getComplex(), main(), main(), and testDigitization().
|
static |
Adds to the (perhaps non empty) set [aSet] an shape defined by an instance of ShapeFunctor. Add Points where orientation is inside. The shape functor must be a model of CEuclideanOrientedShape and CEuclideanBoundedShape. The underlying digitization process is a Gauss Digitizer with grid step h.
| aSet | the set (modified) which will contain the shape. |
| aFunctor | a functor defining the shape. |
| h | grid step for the Gauss digitization. |
| TDigitalSet | a model of CDigitalSet. |
| TShapeFunctor | a model of CEuclideanBoundedShape and CEuclideanOrientedShape. |
Referenced by alphaShape(), convexHull(), main(), testDTFromSet(), testImplicitShape(), and testImplicitShape3D().
| bool DGtal::Shapes< TDomain >::isValid | ( | ) | const |
Checks the validity/consistency of the object.
|
static |
Add to the set aSet the points of the domain that satisfies the predicate aPP.
| aSet | (modified) the digital set that will contain the points. |
| aPP | a predicate on point. |
| DigitalSet | a model of CDigitalSet such that DigitalSet::Domain is Domain. |
| PointPredicate | a model of concepts::CPointPredicate such that PointPredicate::Point is Point. |
Referenced by checkCut(), checkOutputConvexHullBorder(), main(), specificTestLatticePolytope2D(), and testLatticePolytope2D().
|
private |
Assignment.
| other | the object to copy. |
References Shapes().
|
static |
Removes the discrete ball (norm-1) of center [aCenter] and radius [aRadius] to the (perhaps non empty) set [aSet].
| TDigitalSet | the type chosen for the digital set. |
| aSet | the set (modified) which will contain the discrete ball. |
| aCenter | the center of the ball. |
| aRadius | the radius of the ball. |
|
static |
Removes the discrete ball (norm-2) of center [aCenter] and radius [aRadius] to the (perhaps non empty) set [aSet].
| TDigitalSet | the type chosen for the digital set. |
| aSet | the set (modified) which will contain the discrete ball. |
| aCenter | the center of the ball. |
| aRadius | the radius of the ball. |
Referenced by testDigitalSetBoundary(), and testDigitalSurface().
| void DGtal::Shapes< TDomain >::selfDisplay | ( | std::ostream & | out | ) | const |
Writes/Displays the object on an output stream.
| out | the output stream where the object is written. |