DGtal  0.9.2
CCellEmbedder.h
1 
17 #pragma once
18 
31 #if defined(CCellEmbedder_RECURSES)
32 #error Recursive header files inclusion detected in CCellEmbedder.h
33 #else // defined(CCellEmbedder_RECURSES)
34 
35 #define CCellEmbedder_RECURSES
36 
37 #if !defined CCellEmbedder_h
38 
39 #define CCellEmbedder_h
40 
42 // Inclusions
43 #include <iostream>
44 #include "DGtal/base/Common.h"
45 #include "DGtal/base/CUnaryFunctor.h"
46 #include "DGtal/topology/CCellularGridSpaceND.h"
48 
49 // @since 0.8 In DGtal::concepts
50 namespace DGtal {
51  namespace concepts {
52 
54 // class CCellEmbedder
95 template <typename T>
96 struct CCellEmbedder : CUnaryFunctor<T, typename T::Cell, typename T::RealPoint>
97 {
98  // ----------------------- Concept checks ------------------------------
99 public:
100  typedef typename T::KSpace KSpace;
101  typedef typename T::Cell Cell;
102  typedef typename T::RealPoint RealPoint;
103  typedef typename T::Argument Argument;
104  typedef typename T::Value Value;
105 
111  {
113  }
114 
116  { // operator()
118  }
119  // ------------------------- Private Datas --------------------------------
120 private:
121  T myX; // do not require T to be default constructible.
122  Cell myP;
123  RealPoint myRP;
124 
125  // ------------------------- Internals ------------------------------------
126 private:
127 
128 }; // end of concept CCellEmbedder
129 
130 } // namespace concepts
131 } // namespace DGtal
132 
133 // //
135 
136 #endif // !defined CCellEmbedder_h
137 
138 #undef CCellEmbedder_RECURSES
139 #endif // else defined(CCellEmbedder_RECURSES)
BOOST_CONCEPT_ASSERT((CCellularGridSpaceND< KSpace >))
Aim: A cell embedder is a mapping from unsigned cells to Euclidean points. It adds inner types to fun...
Definition: CCellEmbedder.h:96
Aim: Defines a unary functor, which associates arguments to results.
Definition: CUnaryFunctor.h:89
BOOST_STATIC_ASSERT((ConceptUtils::SameType< Cell, typename KSpace::Cell >::value))
void sameType(const T &t1, const T &t2)
DGtal is the top-level namespace which contains all DGtal functions and types.
Aim: This concept describes a cellular grid space in nD. In these spaces obtained by cartesian produc...