DGtal  0.6.devel
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
CNormalVectorEstimator.h
1 
17 #pragma once
18 
31 #if defined(CNormalVectorEstimator_RECURSES)
32 #error Recursive header files inclusion detected in CNormalVectorEstimator.h
33 #else // defined(CNormalVectorEstimator_RECURSES)
34 
35 #define CNormalVectorEstimator_RECURSES
36 
37 #if !defined CNormalVectorEstimator_h
38 
39 #define CNormalVectorEstimator_h
40 
42 // Inclusions
43 #include <iostream>
44 #include <boost/concept_archetype.hpp>
45 #include "DGtal/base/Common.h"
46 #include "DGtal/topology/CCellularGridSpaceND.h"
48 
49 namespace DGtal
50 {
51 
53 // class CNormalVectorEstimator
92 template <typename T>
94 {
95  // ----------------------- Concept checks ------------------------------
96 public:
97  typedef typename T::Surface Surface;
98  typedef typename T::SCell SCell;
99  typedef typename T::ConstIterator ConstIterator;
100  typedef typename T::Quantity Quantity;
101 
104  BOOST_CONCEPT_ASSERT(( boost::InputIterator< ConstIterator > ));
105 
107  {
108  ConceptUtils::sameType( mySurface, myX.surface() );
110  ConceptUtils::sameType( myOutIt, myX.evalAll( myOutIt ) );
112  }
114  {
115  }
116  // ------------------------- Private Datas --------------------------------
117 private:
118  T myX; // do not require T to be default constructible.
122  boost::output_iterator_archetype<Quantity> myOutIt;
123 
124  // ------------------------- Internals ------------------------------------
125 private:
126 
127 }; // end of concept CNormalVectorEstimator
128 
129 } // namespace DGtal
130 
131 // //
133 
134 #endif // !defined CNormalVectorEstimator_h
135 
136 #undef CNormalVectorEstimator_RECURSES
137 #endif // else defined(CNormalVectorEstimator_RECURSES)