DGtal 1.3.0
Loading...
Searching...
No Matches
ArithDSSIterator.h
1
18#pragma once
19
32#if defined(ArithDSSIterator_RECURSES)
33#error Recursive header files inclusion detected in ArithDSSIterator.h
34#else // defined(ArithDSSIterator_RECURSES)
36#define ArithDSSIterator_RECURSES
37
38#if !defined ArithDSSIterator_h
40#define ArithDSSIterator_h
41
43// Inclusions
44#include <iostream>
45#include "DGtal/base/Common.h"
46#include "DGtal/kernel/PointVector.h"
47#include "DGtal/kernel/CInteger.h"
49
50namespace DGtal
51{
52
54// class ArithDSSIterator
62 template<typename TInteger, int connectivity = 8>
64 {
65 // ----------------------- Standard services ------------------------------
66 public:
67
72
76 typedef TInteger Integer;
77
79
84
88 typedef std::forward_iterator_tag iterator_category;
90 typedef std::ptrdiff_t difference_type;
91 typedef const Point* pointer;
92 typedef const Point& reference;
93
99 TInteger remainder(const Point &Q);
100
106
112
119
120
121
127 bool operator==(const Self & other) const;
128
134 bool operator!=(const Self & other) const;
135
136
144 ArithDSSIterator(const Integer a, const Integer b, const Integer mu, const Point & p);
145
151
152
153
158
159 // ----------------------- Interface --------------------------------------
160 public:
161
166 void selfDisplay ( std::ostream & out ) const;
167
172 bool isValid() const;
173
174
175 // ------------------------- Protected Datas ------------------------------
176 private:
177 // ------------------------- Private Datas --------------------------------
178 private:
179
184
189
194
199
200 // ------------------------- Hidden services ------------------------------
201protected:
202
203
204public:
205
212
220 Self& operator=(const Self & other);
221
222
223
224 // ------------------------- Internals ------------------------------------
225private:
226
227 }; // end of class ArithDSSIterator
228
229
236 // std::ostream&
237 //operator<< ( std::ostream & out, const ArithDSSIterator & object );
238
239
240} // namespace DGtal
241
242
244// Includes inline functions.
245#if !defined(BUILD_INLINE)
246#include "DGtal/geometry/curves/ArithDSSIterator.ih"
247#endif
248
249
250// //
252
253#endif // !defined ArithDSSIterator_h
254
255#undef ArithDSSIterator_RECURSES
256#endif // else defined(ArithDSSIterator_RECURSES)
Aim: An iterator on the points of a Digital Straight Segment. Template parameters are the integer typ...
std::forward_iterator_tag iterator_category
bool operator==(const Self &other) const
ArithDSSIterator(const Integer a, const Integer b, const Integer mu, const Point &p)
std::ptrdiff_t difference_type
TInteger remainder(const Point &Q)
bool operator!=(const Self &other) const
BOOST_CONCEPT_ASSERT((concepts::CInteger< Integer >))
PointVector< 2, Integer > Point
ArithDSSIterator(const ArithDSSIterator &other)
Self & operator=(const Self &other)
reference operator*() const
void selfDisplay(std::ostream &out) const
Aim: Implements basic operations that will be used in Point and Vector classes.
Definition: PointVector.h:593
DGtal is the top-level namespace which contains all DGtal functions and types.
Aim: Concept checking for Integer Numbers. More precisely, this concept is a refinement of both CEucl...
Definition: CInteger.h:88