DGtal 1.4.0
Loading...
Searching...
No Matches
DigitalSurfaceEmbedderWithNormalVectorEstimator.h
1
17#pragma once
18
31#if defined(DigitalSurfaceEmbedderWithNormalVectorEstimator_RECURSES)
32#error Recursive header files inclusion detected in DigitalSurfaceEmbedderWithNormalVectorEstimator.h
33#else // defined(DigitalSurfaceEmbedderWithNormalVectorEstimator_RECURSES)
35#define DigitalSurfaceEmbedderWithNormalVectorEstimator_RECURSES
36
37#if !defined DigitalSurfaceEmbedderWithNormalVectorEstimator_h
39#define DigitalSurfaceEmbedderWithNormalVectorEstimator_h
40
42// Inclusions
43#include <iostream>
44#include "DGtal/base/Common.h"
45#include "DGtal/base/ConstAlias.h"
46#include "DGtal/kernel/NumberTraits.h"
47#include "DGtal/topology/CDigitalSurfaceEmbedder.h"
49
50namespace DGtal
51{
52
53 // Forward declaration.
54 template < typename TDigitalSurfaceEmbedder,
55 typename TNormalVectorEstimator >
56 class DigitalSurfaceEmbedderWithNormalVectorEstimatorGradientMap;
57
59
72 template < typename TDigitalSurfaceEmbedder,
73 typename TNormalVectorEstimator >
75 {
76 public:
78 < TDigitalSurfaceEmbedder, TNormalVectorEstimator > Self;
80
81 typedef TDigitalSurfaceEmbedder DigitalSurfaceEmbedder;
82 typedef TNormalVectorEstimator NormalVectorEstimator;
83
84 typedef typename DigitalSurfaceEmbedder::KSpace KSpace;
85 typedef typename DigitalSurfaceEmbedder::Surface Surface;
86 typedef typename DigitalSurfaceEmbedder::SCell SCell;
87 typedef typename DigitalSurfaceEmbedder::RealPoint RealPoint;
88 typedef typename DigitalSurfaceEmbedder::Argument Argument;
89 typedef typename DigitalSurfaceEmbedder::Value Value;
90
91 typedef typename KSpace::Space Space;
92 typedef typename Space::RealVector RealVector;
93 typedef typename NormalVectorEstimator::Quantity Quantity;
94 typedef typename NormalVectorEstimator::DigitalSurface NVESurface;
95
98
100
101
106
112 Self & operator=( const Self & other );
113
122
128 ( const Self & other );
129
134
135 // ----------------------- Interface --------------------------------------
136 public:
137
145 RealPoint operator()( const SCell & scell ) const;
146
150 const Surface & surface() const;
151
155 const KSpace & space() const
156 {
157 return myDSEmbedder->space();
158 }
159
165
171 RealVector gradient( const SCell & scell ) const;
172
173 // ----------------------- Interface --------------------------------------
174 public:
175
181 void selfDisplay ( std::ostream & out ) const;
182
187 bool isValid() const;
188
189 // ------------------------- Protected Datas ------------------------------
190 private:
191 // ------------------------- Private Datas --------------------------------
192 private:
193
198
199 // ------------------------- Hidden services ------------------------------
200 protected:
201
202 }; // end of class DigitalSurfaceEmbedderWithNormalVectorEstimator
203
215 template < typename TDigitalSurfaceEmbedder,
216 typename TNormalVectorEstimator >
267
274 template < typename TDigitalSurfaceEmbedder, typename TNormalVectorEstimator >
275 std::ostream&
276 operator<< ( std::ostream & out,
278
279} // namespace DGtal
280
281
283// Includes inline functions.
284#include "DGtal/geometry/surfaces/estimation/DigitalSurfaceEmbedderWithNormalVectorEstimator.ih"
285
286// //
288
289#endif // !defined DigitalSurfaceEmbedderWithNormalVectorEstimator_h
290
291#undef DigitalSurfaceEmbedderWithNormalVectorEstimator_RECURSES
292#endif // else defined(DigitalSurfaceEmbedderWithNormalVectorEstimator_RECURSES)
Aim: This class encapsulates its parameter class so that to indicate to the user that the object/poin...
Definition ConstAlias.h:187
DigitalSurfaceEmbedderWithNormalVectorEstimator< DigitalSurfaceEmbedder, NormalVectorEstimator > Embedder
DigitalSurfaceEmbedderWithNormalVectorEstimatorGradientMap< TDigitalSurfaceEmbedder, TNormalVectorEstimator > Self
const Embedder * myEmbedder
The digital surface embedder with normal vector estimator.
DigitalSurfaceEmbedderWithNormalVectorEstimatorGradientMap(ConstAlias< Embedder > embedder)
BOOST_CONCEPT_ASSERT((concepts::CDigitalSurfaceEmbedder< TDigitalSurfaceEmbedder >))
DigitalSurfaceEmbedderWithNormalVectorEstimatorGradientMap()
Default constructor. The object is not valid.
~DigitalSurfaceEmbedderWithNormalVectorEstimatorGradientMap()
Destructor. Does nothing.
Aim: Combines a digital surface embedder with a normal vector estimator to get a model of CDigitalSur...
DigitalSurfaceEmbedderWithNormalVectorEstimator(ConstAlias< DigitalSurfaceEmbedder > aDSEmbedder, ConstAlias< NormalVectorEstimator > anEstimator)
DigitalSurfaceEmbedderWithNormalVectorEstimatorGradientMap< DigitalSurfaceEmbedder, NormalVectorEstimator > GradientMap
BOOST_STATIC_ASSERT((concepts::ConceptUtils::SameType< Surface, NVESurface >::value))
const DigitalSurfaceEmbedder * myDSEmbedder
A pointer on the digital surface.
DigitalSurfaceEmbedderWithNormalVectorEstimator< TDigitalSurfaceEmbedder, TNormalVectorEstimator > Self
BOOST_CONCEPT_ASSERT((concepts::CDigitalSurfaceEmbedder< TDigitalSurfaceEmbedder >))
RealVector gradient(const SCell &scell) const
BOOST_STATIC_ASSERT((concepts::ConceptUtils::SameType< RealVector, Quantity >::value))
const NormalVectorEstimator * myEstimator
A pointer on the normal vector estimator.
RealPoint operator()(const SCell &scell) const
Aim: Implements basic operations that will be used in Point and Vector classes.
DGtal is the top-level namespace which contains all DGtal functions and types.
std::ostream & operator<<(std::ostream &out, const ClosedIntegerHalfPlane< TSpace > &object)
Aim: A digital surface embedder is a specialized mapping from signed cells to Euclidean points....