36 #ifndef VIGRA_PIXELNEIGHBORHOOD_HXX
37 #define VIGRA_PIXELNEIGHBORHOOD_HXX
132 namespace FourNeighborhood
191 InitialDirection =
East,
192 OppositeDirPrefix = 1,
193 OppositeOffset =
West
199 static unsigned int b[];
200 static unsigned int c[];
206 static unsigned int directionBit(
Direction d)
208 return StaticData<0>::b[d];
215 return StaticData<0>::c[b];
223 return StaticData<0>::bd[b][index];
231 return StaticData<0>::d[
code];
245 return StaticData<0>::rd[fromCode][toCode];
253 return relativeDiff(static_cast<Direction>(fromCode), static_cast<Direction>(toCode));
287 return (diff.
y == 0) ?
293 return (diff.
y == 0) ?
337 unsigned int NeighborCode::StaticData<DUMMY>::b[] = {1 <<
East,
343 unsigned int NeighborCode::StaticData<DUMMY>::c[] = { 4, 3, 3, 0, 3, 2, 2, 0, 3, 2, 2};
346 Direction NeighborCode::StaticData<DUMMY>::bd[11][4] = {
361 Diff2D NeighborCode::StaticData<DUMMY>::d[] = {
362 Diff2D(1, 0), Diff2D(0, -1), Diff2D(-1, 0), Diff2D(0, 1)
366 Diff2D NeighborCode::StaticData<DUMMY>::rd[][4] = {
367 { Diff2D(0, 0), Diff2D(-1, -1), Diff2D(-2, 0), Diff2D(-1, 1) },
368 { Diff2D(1, 1), Diff2D(0, 0), Diff2D(-1, 1), Diff2D(0, 2) },
369 { Diff2D(2, 0), Diff2D(1, -1), Diff2D(0, 0), Diff2D(1, 1) },
370 { Diff2D(1, -1), Diff2D(0, -2), Diff2D(-1, -1), Diff2D(0, 0) }
388 namespace EightNeighborhood
450 InitialDirection =
East,
451 OppositeDirPrefix = 1,
452 OppositeOffset =
West
458 static unsigned int b[];
459 static unsigned int c[];
465 static unsigned int directionBit(
Direction d)
467 return StaticData<0>::b[d];
474 return StaticData<0>::c[b];
482 return StaticData<0>::bd[b][index];
490 return StaticData<0>::d[
code];
504 return StaticData<0>::rd[fromCode][toCode];
512 return relativeDiff(static_cast<Direction>(fromCode), static_cast<Direction>(toCode));
629 unsigned int NeighborCode::StaticData<DUMMY>::b[] = {
640 unsigned int NeighborCode::StaticData<DUMMY>::c[] = { 8, 5, 5, 0, 5, 3, 3, 0, 5, 3, 3};
643 Direction NeighborCode::StaticData<DUMMY>::bd[11][8] = {
647 {
Error,
Error, Error, Error, Error, Error, Error, Error},
651 {
Error,
Error, Error, Error, Error, Error, Error, Error},
658 Diff2D NeighborCode::StaticData<DUMMY>::d[] = {
659 Diff2D(1, 0), Diff2D(1, -1), Diff2D(0, -1), Diff2D(-1, -1),
660 Diff2D(-1, 0), Diff2D(-1, 1), Diff2D(0, 1), Diff2D(1, 1)
664 Diff2D NeighborCode::StaticData<DUMMY>::rd[][8] = {
665 { Diff2D(0, 0), Diff2D(0, -1), Diff2D(-1, -1), Diff2D(-2, -1),
666 Diff2D(-2, 0), Diff2D(-2, 1), Diff2D(-1, 1), Diff2D(0, 1) },
667 { Diff2D(0, 1), Diff2D(0, 0), Diff2D(-1, 0), Diff2D(-2, 0),
668 Diff2D(-2, 1), Diff2D(-2, 2), Diff2D(-1, 2), Diff2D(0, 2) },
669 { Diff2D(1, 1), Diff2D(1, 0), Diff2D(0, 0), Diff2D(-1, 0),
670 Diff2D(-1, 1), Diff2D(-1, 2), Diff2D(0, 2), Diff2D(1, 2) },
671 { Diff2D(2, 1), Diff2D(2, 0), Diff2D(1, 0), Diff2D(0, 0),
672 Diff2D(0, 1), Diff2D(0, 2), Diff2D(1, 2), Diff2D(2, 2) },
673 { Diff2D(2, 0), Diff2D(2, -1), Diff2D(1, -1), Diff2D(0, -1),
674 Diff2D(0, 0), Diff2D(0, 1), Diff2D(1, 1), Diff2D(2, 1) },
675 { Diff2D(2, -1), Diff2D(2, -2), Diff2D(1, -2), Diff2D(0, -2),
676 Diff2D(0, -1), Diff2D(0, 0), Diff2D(1, 0), Diff2D(2, 0) },
677 { Diff2D(1, -1), Diff2D(1, -2), Diff2D(0, -2), Diff2D(-1, -2),
678 Diff2D(-1, -1), Diff2D(-1, 0), Diff2D(0, 0), Diff2D(1, 0) },
679 { Diff2D(0, -1), Diff2D(0, -2), Diff2D(-1, -2), Diff2D(-2, -2),
680 Diff2D(-2, -1), Diff2D(-2, 0), Diff2D(-1, 0), Diff2D(0, 0) }
711 template<
class NEIGHBORCODE>
713 :
public NEIGHBORCODE
716 typedef NEIGHBORCODE NeighborCode;
760 direction_ =
static_cast<Direction>((direction_+1) % NEIGHBORCODE::DirectionCount);
767 direction_ =
static_cast<Direction>((direction_ + NEIGHBORCODE::DirectionCount-1) % NEIGHBORCODE::DirectionCount);
790 direction_ =
static_cast<Direction>((direction_ + d) % NEIGHBORCODE::DirectionCount);
792 direction_ =
static_cast<Direction>(direction_ + NEIGHBORCODE::DirectionCount);
799 direction_ =
static_cast<Direction>((direction_ - d) % NEIGHBORCODE::DirectionCount);
801 direction_ =
static_cast<Direction>(direction_ + NEIGHBORCODE::DirectionCount);
823 direction_ =
static_cast<Direction>((direction_ + NEIGHBORCODE::South) % NEIGHBORCODE::DirectionCount);
833 direction_ =
static_cast<Direction>((direction_ + NEIGHBORCODE::North) % NEIGHBORCODE::DirectionCount);
858 return direction_ == o.direction_;
864 return direction_ != o.direction_;
870 return direction_ - o.direction_;
895 return NEIGHBORCODE::diff(direction_);
902 return NEIGHBORCODE::diff(dir);
910 Direction toDir =
static_cast<Direction>((direction_ + offset) % NEIGHBORCODE::DirectionCount);
912 toDir =
static_cast<Direction>(toDir + NEIGHBORCODE::DirectionCount);
913 return NEIGHBORCODE::relativeDiff(direction_, toDir);
919 return NEIGHBORCODE::dX(direction_);
925 return NEIGHBORCODE::dY(direction_);
932 return NEIGHBORCODE::isDiagonal(direction_);
946 return NEIGHBORCODE::directionBit(direction_);
953 return static_cast<Direction>((NEIGHBORCODE::OppositeDirPrefix*direction_ + NEIGHBORCODE::OppositeOffset) % NEIGHBORCODE::DirectionCount);
960 return NEIGHBORCODE::directionBit(
opposite());
967 int result = (direction_ + offset) % NEIGHBORCODE::DirectionCount;
969 result += NEIGHBORCODE::DirectionCount;
1036 template <
class IMAGEITERATOR,
class NEIGHBORCODE>
1084 Direction d = NEIGHBOROFFSETCIRCULATOR::InitialDirection)
1085 : IMAGEITERATOR(aCenter), neighborCode_(d)
1157 (oldDirection, neighborCode_.
direction()));
1170 (oldDirection, neighborCode_.
direction()));
1183 (oldDirection, neighborCode_.
direction()));
1194 (oldDirection, neighborCode_.
direction()));
1221 return neighborCode_ == rhs.neighborCode_ &&
1228 return neighborCode_ != rhs.neighborCode_ ||
1235 return neighborCode_ - rhs.neighborCode_;
1241 return IMAGEITERATOR::operator*();
1247 return IMAGEITERATOR::operator[](neighborCode_.
relativeDiff(d));
1253 return IMAGEITERATOR::operator->();
1283 return neighborCode_.
diff();
1293 NEIGHBOROFFSETCIRCULATOR neighborCode_;
1344 template <
class IMAGEITERATOR,
class NEIGHBORCODE>
1392 :
BaseType(
center, NEIGHBORCODE::nearBorderDirections(atBorder, 0)),
1393 whichBorder_(atBorder),
1394 count_(NEIGHBORCODE::nearBorderDirectionCount(atBorder)),
1429 current_ =
static_cast<Direction>((current_ + count_ + d) % count_);
1430 BaseType::turnTo(NEIGHBORCODE::nearBorderDirections(whichBorder_, current_));
1459 return current_ == rhs.current_;
1465 return current_ != rhs.current_;
1471 return (current_ - rhs.current_) % count_;
1511 typename NeighborCode::difference_type
const &
diff()
const
1524 signed char count_, current_;
static const Direction DirectionCount
Definition: pixelneighborhood.hxx:617
Definition: pixelneighborhood.hxx:447
RestrictedNeighborhoodCirculator(IMAGEITERATOR const ¢er=IMAGEITERATOR(), AtImageBorder atBorder=NotAtBorder)
Definition: pixelneighborhood.hxx:1390
static Diff2D const & southEast()
Definition: pixelneighborhood.hxx:602
base_type center() const
Definition: pixelneighborhood.hxx:1263
bool isDiagonal() const
Definition: pixelneighborhood.hxx:1287
Diff2D const & north()
Definition: pixelneighborhood.hxx:331
static Diff2D const & west()
Definition: pixelneighborhood.hxx:314
Definition: pixelneighborhood.hxx:186
NEIGHBORCODE::Direction Direction
Definition: pixelneighborhood.hxx:1057
NeighborhoodCirculator & operator-=(difference_type d)
Definition: pixelneighborhood.hxx:1127
NeighborOffsetCirculator & turnRound()
Definition: pixelneighborhood.hxx:841
RestrictedNeighborhoodCirculator & operator-=(difference_type d)
Definition: pixelneighborhood.hxx:1435
Definition: pixelneighborhood.hxx:443
static Diff2D const & top()
Definition: pixelneighborhood.hxx:588
bool operator!=(NeighborhoodCirculator const &rhs) const
Definition: pixelneighborhood.hxx:1226
reference diff() const
Definition: pixelneighborhood.hxx:893
Circulator that walks around a given location in a given image, using a restricted neighborhood...
Definition: pixelneighborhood.hxx:1345
static Diff2D const & north()
Definition: pixelneighborhood.hxx:313
IMAGEITERATOR base_type
Definition: pixelneighborhood.hxx:1045
static int dX(Direction code)
Definition: pixelneighborhood.hxx:257
Definition: pixelneighborhood.hxx:437
NeighborhoodCirculator operator--(int)
Definition: pixelneighborhood.hxx:1111
int y
Definition: diff2d.hxx:392
Direction
Definition: pixelneighborhood.hxx:434
BaseType::index_reference index_reference
Definition: pixelneighborhood.hxx:1373
Definition: pixelneighborhood.hxx:439
static Diff2D const & top()
Definition: pixelneighborhood.hxx:308
static const Direction SouthWest
Definition: pixelneighborhood.hxx:614
Definition: pixelneighborhood.hxx:188
RestrictedNeighborhoodCirculator operator--(int)
Definition: pixelneighborhood.hxx:1419
RestrictedNeighborhoodCirculator & operator--()
Definition: pixelneighborhood.hxx:1413
bool isDiagonal() const
Definition: pixelneighborhood.hxx:1517
NEIGHBORCODE NeighborCode
Definition: pixelneighborhood.hxx:1049
static Diff2D const & diff(Direction code)
Definition: pixelneighborhood.hxx:488
static bool isDiagonal(Direction)
Definition: pixelneighborhood.hxx:305
static const Direction Error
Definition: pixelneighborhood.hxx:323
NeighborOffsetCirculator & turnLeft()
Definition: pixelneighborhood.hxx:831
NeighborOffsetCirculator< FourNeighborCode > FourNeighborOffsetCirculator
Definition: pixelneighborhood.hxx:980
difference_type operator-(RestrictedNeighborhoodCirculator const &rhs) const
Definition: pixelneighborhood.hxx:1469
Definition: pixelneighborhood.hxx:189
NeighborOffsetCirculator(Direction dir=NEIGHBORCODE::InitialDirection)
Definition: pixelneighborhood.hxx:752
bool operator==(RestrictedNeighborhoodCirculator const &rhs) const
Definition: pixelneighborhood.hxx:1457
static unsigned int nearBorderDirectionCount(AtImageBorder b)
Definition: pixelneighborhood.hxx:213
AtImageBorder
Encode whether a point is near the image border.
Definition: pixelneighborhood.hxx:68
Definition: pixelneighborhood.hxx:75
int x
Definition: diff2d.hxx:385
NeighborOffsetCirculator & operator+=(difference_type d)
Definition: pixelneighborhood.hxx:788
static Diff2D const & northWest()
Definition: pixelneighborhood.hxx:598
RestrictedNeighborhoodCirculator operator-(difference_type d) const
Definition: pixelneighborhood.hxx:1449
static Diff2D const & topRight()
Definition: pixelneighborhood.hxx:587
BaseType::pointer pointer
Definition: pixelneighborhood.hxx:1377
pointer operator->() const
Definition: pixelneighborhood.hxx:1251
unsigned int directionBit() const
Definition: pixelneighborhood.hxx:1275
Definition: pixelneighborhood.hxx:444
NEIGHBORCODE::Direction Direction
Definition: pixelneighborhood.hxx:720
Two dimensional difference vector.
Definition: diff2d.hxx:185
IMAGEITERATOR::pointer pointer
Definition: pixelneighborhood.hxx:1070
AtImageBorder isAtImageBorder(int x, int y, int width, int height)
Find out whether a point is at the image border.
Definition: pixelneighborhood.hxx:111
unsigned int directionBit() const
Definition: pixelneighborhood.hxx:1505
static Diff2D const & left()
Definition: pixelneighborhood.hxx:309
NeighborOffsetCirculator operator++(int)
Definition: pixelneighborhood.hxx:772
NeighborOffsetCirculator< EightNeighborCode > EightNeighborOffsetCirculator
Definition: pixelneighborhood.hxx:976
static unsigned int nearBorderDirectionCount(AtImageBorder b)
Definition: pixelneighborhood.hxx:472
NeighborOffsetCirculator operator--(int)
Definition: pixelneighborhood.hxx:780
Diff2D const & west()
Definition: pixelneighborhood.hxx:332
Definition: pixelneighborhood.hxx:185
static const Direction South
Definition: pixelneighborhood.hxx:327
pointer operator->() const
Definition: pixelneighborhood.hxx:1481
BaseType::reference reference
Definition: pixelneighborhood.hxx:1369
int difference_type
Definition: pixelneighborhood.hxx:740
Diff2D const & east()
Definition: pixelneighborhood.hxx:330
NeighborhoodCirculator & operator++()
Definition: pixelneighborhood.hxx:1091
index_reference operator[](difference_type d) const
Definition: pixelneighborhood.hxx:880
unsigned int directionBit() const
Definition: pixelneighborhood.hxx:944
NeighborCode::Direction Direction
Definition: pixelneighborhood.hxx:321
static Direction nearBorderDirections(AtImageBorder b, int index)
Definition: pixelneighborhood.hxx:480
Encapsulation of direction management for 4-neighborhood.
Definition: pixelneighborhood.hxx:165
Definition: pixelneighborhood.hxx:73
static const Direction South
Definition: pixelneighborhood.hxx:615
IMAGEITERATOR::reference reference
Definition: pixelneighborhood.hxx:1061
Definition: pixelneighborhood.hxx:445
NeighborOffsetCirculator operator+(difference_type d) const
Definition: pixelneighborhood.hxx:806
Definition: pixelneighborhood.hxx:448
static Diff2D const & south()
Definition: pixelneighborhood.hxx:601
static int dY(int code)
Definition: pixelneighborhood.hxx:522
NeighborhoodCirculator & moveCenterToNeighbor()
Definition: pixelneighborhood.hxx:1201
static Diff2D const & left()
Definition: pixelneighborhood.hxx:590
NeighborhoodCirculator & turnRound()
Definition: pixelneighborhood.hxx:1178
bool operator!=(NeighborOffsetCirculator const &o) const
Definition: pixelneighborhood.hxx:862
static Diff2D const & east()
Definition: pixelneighborhood.hxx:595
NeighborhoodCirculator & turnTo(Direction d)
Definition: pixelneighborhood.hxx:1189
NeighborhoodCirculator & operator+=(difference_type d)
Definition: pixelneighborhood.hxx:1119
static Diff2D const & bottomLeft()
Definition: pixelneighborhood.hxx:591
NeighborOffsetCirculator & operator-=(difference_type d)
Definition: pixelneighborhood.hxx:797
Direction
Definition: pixelneighborhood.hxx:179
NEIGHBOROFFSETCIRCULATOR::difference_type difference_type
Definition: pixelneighborhood.hxx:1074
static Diff2D const & diff(Direction code)
Definition: pixelneighborhood.hxx:229
Circulator that walks around a given location.
Definition: pixelneighborhood.hxx:712
Definition: pixelneighborhood.hxx:442
NEIGHBORCODE::difference_type value_type
Definition: pixelneighborhood.hxx:724
RestrictedNeighborhoodCirculator operator++(int)
Definition: pixelneighborhood.hxx:1405
FFTWComplex< R > & operator+=(FFTWComplex< R > &a, const FFTWComplex< R > &b)
add-assignment
Definition: fftw3.hxx:859
static const Direction NorthWest
Definition: pixelneighborhood.hxx:612
static Diff2D const & diff(int code)
Definition: pixelneighborhood.hxx:237
Diff2D const & northWest()
Definition: pixelneighborhood.hxx:622
base_type const & base() const
Definition: pixelneighborhood.hxx:1487
static int dY(Direction code)
Definition: pixelneighborhood.hxx:259
Direction direction(difference_type offset) const
Definition: pixelneighborhood.hxx:965
value_type const * pointer
Definition: pixelneighborhood.hxx:736
static Direction nearBorderDirections(AtImageBorder b, int index)
Definition: pixelneighborhood.hxx:221
NEIGHBORCODE NeighborCode
Definition: pixelneighborhood.hxx:1357
NeighborCode::Direction Direction
Definition: pixelneighborhood.hxx:607
Definition: pixelneighborhood.hxx:180
Definition: pixelneighborhood.hxx:184
reference operator*() const
Definition: pixelneighborhood.hxx:1475
static Diff2D const & diff(int code)
Definition: pixelneighborhood.hxx:496
NeighborhoodCirculator & turnLeft()
Definition: pixelneighborhood.hxx:1165
bool operator!=(FFTWComplex< R > const &a, const FFTWComplex< R > &b)
not equal
Definition: fftw3.hxx:841
Definition: pixelneighborhood.hxx:446
static const Direction NorthEast
Definition: pixelneighborhood.hxx:610
static int dX(Direction code)
Definition: pixelneighborhood.hxx:516
static Diff2D const & bottomRight()
Definition: pixelneighborhood.hxx:593
static Diff2D const & relativeDiff(int fromCode, int toCode)
Definition: pixelneighborhood.hxx:251
bool operator==(FFTWComplex< R > const &a, const FFTWComplex< R > &b)
equal
Definition: fftw3.hxx:825
BaseType::difference_type difference_type
Definition: pixelneighborhood.hxx:1381
static Direction code(Diff2D const &diff)
Definition: pixelneighborhood.hxx:269
static const Direction West
Definition: pixelneighborhood.hxx:613
RestrictedNeighborhoodCirculator operator+(difference_type d) const
Definition: pixelneighborhood.hxx:1441
Circulator that walks around a given location in a given image.
Definition: pixelneighborhood.hxx:1037
int dY() const
Definition: pixelneighborhood.hxx:923
static Diff2D const & northEast()
Definition: pixelneighborhood.hxx:596
NeighborOffsetCirculator & operator++()
Definition: pixelneighborhood.hxx:758
difference_type operator-(NeighborOffsetCirculator const &o) const
Definition: pixelneighborhood.hxx:868
NeighborhoodCirculator & operator--()
Definition: pixelneighborhood.hxx:1105
index_reference operator[](difference_type d) const
Definition: pixelneighborhood.hxx:1245
static const Direction SouthEast
Definition: pixelneighborhood.hxx:616
static const Direction North
Definition: pixelneighborhood.hxx:611
Direction opposite() const
Definition: pixelneighborhood.hxx:951
NeighborhoodCirculator & swapCenterNeighbor()
Definition: pixelneighborhood.hxx:1211
difference_type operator-(NeighborhoodCirculator const &rhs) const
Definition: pixelneighborhood.hxx:1233
bool isDiagonal() const
Definition: pixelneighborhood.hxx:930
static Diff2D const & relativeDiff(Direction fromCode, Direction toCode)
Definition: pixelneighborhood.hxx:243
NeighborhoodCirculator operator++(int)
Definition: pixelneighborhood.hxx:1097
NeighborhoodCirculator operator+(difference_type d) const
Definition: pixelneighborhood.hxx:1133
static Diff2D const & east()
Definition: pixelneighborhood.hxx:312
static Direction code(Diff2D const &diff)
Definition: pixelneighborhood.hxx:533
static int dX(int code)
Definition: pixelneighborhood.hxx:520
BaseType::iterator_category iterator_category
Definition: pixelneighborhood.hxx:1385
Diff2D const & south()
Definition: pixelneighborhood.hxx:333
static Diff2D const & bottom()
Definition: pixelneighborhood.hxx:592
Direction direction() const
Definition: pixelneighborhood.hxx:1499
BaseType::Direction Direction
Definition: pixelneighborhood.hxx:1365
static reference diff(Direction dir)
Definition: pixelneighborhood.hxx:900
Direction direction() const
Definition: pixelneighborhood.hxx:1269
static int dX(int code)
Definition: pixelneighborhood.hxx:261
bool operator!=(RestrictedNeighborhoodCirculator const &rhs) const
Definition: pixelneighborhood.hxx:1463
pointer operator->() const
Definition: pixelneighborhood.hxx:886
static const Direction East
Definition: pixelneighborhood.hxx:324
NeighborOffsetCirculator & operator--()
Definition: pixelneighborhood.hxx:765
Diff2D const & south()
Definition: pixelneighborhood.hxx:625
static const Direction DirectionCount
Definition: pixelneighborhood.hxx:328
static const Direction North
Definition: pixelneighborhood.hxx:325
RestrictedNeighborhoodCirculator & operator++()
Definition: pixelneighborhood.hxx:1399
Diff2D const & southEast()
Definition: pixelneighborhood.hxx:626
NeighborCode::difference_type const & diff() const
Definition: pixelneighborhood.hxx:1511
Direction direction() const
Definition: pixelneighborhood.hxx:937
static int dY(int code)
Definition: pixelneighborhood.hxx:263
static Diff2D const & southWest()
Definition: pixelneighborhood.hxx:600
Definition: pixelneighborhood.hxx:74
static Diff2D const & bottom()
Definition: pixelneighborhood.hxx:310
Diff2D const & southWest()
Definition: pixelneighborhood.hxx:624
bool operator==(NeighborOffsetCirculator const &o) const
Definition: pixelneighborhood.hxx:856
static Diff2D const & right()
Definition: pixelneighborhood.hxx:307
Definition: pixelneighborhood.hxx:182
base_type const & base() const
Definition: pixelneighborhood.hxx:1257
NeighborhoodCirculator operator-(difference_type d) const
Definition: pixelneighborhood.hxx:1141
Definition: pixelneighborhood.hxx:436
static Direction code(FourNeighborhood::Direction d)
Definition: pixelneighborhood.hxx:526
Diff2D const & west()
Definition: pixelneighborhood.hxx:623
int dX() const
Definition: pixelneighborhood.hxx:917
value_type const & index_reference
Definition: pixelneighborhood.hxx:732
FourNeighborhood::NeighborCode FourNeighborCode
Definition: pixelneighborhood.hxx:379
static Diff2D const & north()
Definition: pixelneighborhood.hxx:597
reference operator*() const
Definition: pixelneighborhood.hxx:1239
static const Direction East
Definition: pixelneighborhood.hxx:609
reference index_reference
Definition: pixelneighborhood.hxx:1066
static Diff2D const & relativeDiff(int fromCode, int toCode)
Definition: pixelneighborhood.hxx:510
static const Direction West
Definition: pixelneighborhood.hxx:326
Definition: pixelneighborhood.hxx:183
Definition: pixelneighborhood.hxx:70
NeighborOffsetCirculator & turnTo(Direction d)
Definition: pixelneighborhood.hxx:849
NeighborOffsetCirculator operator-(difference_type d) const
Definition: pixelneighborhood.hxx:812
Definition: pixelneighborhood.hxx:71
Definition: pixelneighborhood.hxx:72
Definition: pixelneighborhood.hxx:438
RestrictedNeighborhoodCirculator & operator+=(difference_type d)
Definition: pixelneighborhood.hxx:1427
static Diff2D const & south()
Definition: pixelneighborhood.hxx:315
Definition: pixelneighborhood.hxx:441
static Diff2D const & relativeDiff(Direction fromCode, Direction toCode)
Definition: pixelneighborhood.hxx:502
NeighborhoodCirculator & turnRight()
Definition: pixelneighborhood.hxx:1152
NEIGHBOROFFSETCIRCULATOR::value_type const & diff() const
Definition: pixelneighborhood.hxx:1281
static bool isDiagonal(Direction code)
Definition: pixelneighborhood.hxx:584
static Diff2D const & topLeft()
Definition: pixelneighborhood.hxx:589
NeighborOffsetCirculator & turnRight()
Definition: pixelneighborhood.hxx:821
IMAGEITERATOR base_type
Definition: pixelneighborhood.hxx:1353
IMAGEITERATOR::value_type value_type
Definition: pixelneighborhood.hxx:1053
EightNeighborhood::NeighborCode EightNeighborCode
Definition: pixelneighborhood.hxx:687
BaseType::value_type value_type
Definition: pixelneighborhood.hxx:1361
unsigned int oppositeDirectionBit() const
Definition: pixelneighborhood.hxx:958
Diff2D const & east()
Definition: pixelneighborhood.hxx:619
random_access_circulator_tag iterator_category
Definition: pixelneighborhood.hxx:744
bool operator==(NeighborhoodCirculator const &rhs) const
Definition: pixelneighborhood.hxx:1219
value_type relativeDiff(difference_type offset) const
Definition: pixelneighborhood.hxx:908
Diff2D const & north()
Definition: pixelneighborhood.hxx:621
reference operator*() const
Definition: pixelneighborhood.hxx:874
Definition: pixelneighborhood.hxx:181
base_type center() const
Definition: pixelneighborhood.hxx:1493
Definition: pixelneighborhood.hxx:440
static Diff2D const & west()
Definition: pixelneighborhood.hxx:599
Diff2D const & northEast()
Definition: pixelneighborhood.hxx:620
NEIGHBOROFFSETCIRCULATOR::iterator_category iterator_category
Definition: pixelneighborhood.hxx:1078
static Diff2D const & right()
Definition: pixelneighborhood.hxx:586
NeighborhoodCirculator(IMAGEITERATOR const &aCenter=IMAGEITERATOR(), Direction d=NEIGHBOROFFSETCIRCULATOR::InitialDirection)
Definition: pixelneighborhood.hxx:1083
Definition: pixelneighborhood.hxx:435
Definition: pixelneighborhood.hxx:187
value_type const & reference
Definition: pixelneighborhood.hxx:728
Encapsulation of direction management for the 8-neighborhood.
Definition: pixelneighborhood.hxx:420
static int dY(Direction code)
Definition: pixelneighborhood.hxx:518