DGtal 1.3.0
Loading...
Searching...
No Matches
ImageLinearCellEmbedder.h
1
17#pragma once
18
31#if defined(ImageLinearCellEmbedder_RECURSES)
32#error Recursive header files inclusion detected in ImageLinearCellEmbedder.h
33#else // defined(ImageLinearCellEmbedder_RECURSES)
35#define ImageLinearCellEmbedder_RECURSES
36
37#if !defined ImageLinearCellEmbedder_h
39#define ImageLinearCellEmbedder_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/images/CImage.h"
49
50namespace DGtal
51{
52
54
66 template < typename TKSpace,
67 typename TImage,
68 typename TEmbedder >
70 {
72
73 public:
74 typedef TKSpace KSpace;
75 typedef TImage Image;
76 typedef TEmbedder Embedder;
77 typedef typename KSpace::Cell Cell;
78 typedef typename KSpace::SCell SCell;
79 typedef typename KSpace::Space Space;
80 typedef typename Space::Point Point;
81 typedef typename Space::RealPoint RealPoint;
82 typedef typename Space::RealVector RealVector;
83 typedef typename Space::Integer Integer;
84 typedef typename Image::Value ImageValue;
85 typedef Cell Argument;
87
92
97
103
111
122 ConstAlias<Embedder> e, double iso_value );
123
124 // ----------------------- Interface --------------------------------------
125 public:
126
134 RealPoint embed( const Point & p ) const;
135
143 RealPoint embedCell( const Cell & cell ) const;
144
153 RealPoint embedSCell( const SCell & scell ) const;
154
162 RealPoint operator()( const Cell & cell ) const;
163
164
165 // ----------------------- Interface --------------------------------------
166 public:
167
172 void selfDisplay ( std::ostream & out ) const;
173
178 bool isValid() const;
179
180 // ------------------------- Protected Datas ------------------------------
181 private:
182 // ------------------------- Private Datas --------------------------------
183 private:
184
193
194 // ------------------------- Hidden services ------------------------------
195 protected:
196
197 private:
198
199 }; // end of class ImageLinearCellEmbedder
200
201
208 template < typename TKSpace, typename TImage, typename TEmbedder >
209 std::ostream&
210 operator<< ( std::ostream & out,
212
213} // namespace DGtal
214
215
217// Includes inline functions.
218#include "DGtal/images/ImageLinearCellEmbedder.ih"
219
220// //
222
223#endif // !defined ImageLinearCellEmbedder_h
224
225#undef ImageLinearCellEmbedder_RECURSES
226#endif // else defined(ImageLinearCellEmbedder_RECURSES)
Aim: This class encapsulates its parameter class so that to indicate to the user that the object/poin...
Definition: ConstAlias.h:187
Aim: a cellular embedder for images. (default constructible, copy constructible, assignable)....
double myIsoValue
The threshold value for the linear embedding.
const Embedder * myPtrEmbedder
A pointer on the digital embedder.
void init(ConstAlias< KSpace > K, ConstAlias< Image > f, ConstAlias< Embedder > e, double iso_value)
RealPoint embedCell(const Cell &cell) const
const KSpace * myPtrK
A pointer on the cellular grid space.
RealPoint operator()(const Cell &cell) const
ImageLinearCellEmbedder(const ImageLinearCellEmbedder &other)
ImageLinearCellEmbedder & operator=(const ImageLinearCellEmbedder &other)
BOOST_CONCEPT_ASSERT((concepts::CImage< TImage >))
const Image * myPtrImage
A pointer on the image.
RealPoint embedSCell(const SCell &scell) const
void selfDisplay(std::ostream &out) const
RealPoint embed(const Point &p) const
TInteger Integer
Arithmetic ring induced by (+,-,*) and Integer numbers.
Definition: SpaceND.h:102
DGtal is the top-level namespace which contains all DGtal functions and types.
std::ostream & operator<<(std::ostream &out, const ClosedIntegerHalfPlane< TSpace > &object)
Represents a signed cell in a cellular grid space by its Khalimsky coordinates and a boolean value.
Aim: Defines the concept describing a read/write image, having an output iterator.
Definition: CImage.h:103
KSpace K