struct DGtal::concepts::CDigitalSurfaceContainer< T >
Aim: The digital surface container concept describes a minimal set of inner types and methods so as to describe the data of digital surfaces.
Description of concept 'CDigitalSurfaceContainer'
Digital surfaces arise in many different contexts:
- an explicit set of oriented surfels
- the boundary of an explicit set of spels
- the boundary of an explicit set of digital points
- the boundary of a set of digital points, defined implicitly by a predicate: Point -> bool
- a set of oriented surfels, defined implicitly by a predicate: Surfel -> bool
- a set of oriented surfels, implicitly by a predicate: Oriented Surfel -> bool
- the boundary of a region in a labelled image
- the frontier between two regions in a labelled image
Since there are so many digital surfaces, it is necessary to provide a mechanism to handle them generically. The class DigitalSurface will be the common proxy to hide models of CDigitalSurfaceContainer.
Hence CDigitalSurfaceContainer describes how to access the data representing the digital surface in common way.
See Models of digital surface containers
Associated types :
- KSpace: the type of cellular grid space in which lies the digital surface.
- Surfel: the type of an oriented n-1-cell in this space.
- SurfelConstIterator: the type for iterating over the of surfels of the digital surface, must be a model of boost_concepts::SinglePassIteratorConcept, boost_concepts::ReadableIteratorConcept
- DigitalSurfaceTracker: the type for tracking surfels over the digital surface
- Size: the integral type for counting elements.
Valid expressions and semantics
|Name ||Expression ||Type requirements ||Return type ||Precondition ||Semantics ||Post condition ||Complexity |
|space accessor||x.space() ||const KSpace & ||returns a reference to the cellular grid space in which lies the digital surface. |
|inside test ||x.isInside( s ) ||bool ||returns |
true iff the surfel
s belongs to this digital surface.
|begin of range||x.begin() ||SurfelConstIterator ||returns a const iterator pointing to the first element in the digital surface, seen as a collection of surfels. |
|end of range ||x.end() ||SurfelConstIterator ||returns an iterator pointing past the last element in the digital surface, seen as a collection of surfels. |
|tracker instanciation ||x.newTracker( s ) ||DigitalSurfaceTracker* ||returns a dynamically allocated instance of tracker initialized at the surfel s. |
|connectedness test ||x.connectedness() |
|returns either DISCONNECTED, CONNECTED, UNKNOWN depending on the surface. |
|number of surfels ||x.nbSurfels() ||Size ||returns the number of surfels of this surface. |
|empty container test ||x.empty() ||bool ||returns |
true iff the digital surface contains no surfel.
- Template Parameters
Definition at line 127 of file CDigitalSurfaceContainer.h.