[ VIGRA Homepage | Function Index | Class Index | Namespaces | File List | Main Page ]
![]() |
Utilities to manage pixel neighborhoods | ![]() |
Namespaces | |
vigra::EightNeighborhood | |
vigra::FourNeighborhood | |
Classes | |
class | NeighborCode |
Encapsulation of direction management for the 8-neighborhood. More... | |
class | NeighborCode |
Encapsulation of direction management for 4-neighborhood. More... | |
class | NeighborOffsetCirculator< NEIGHBORCODE > |
Circulator that walks around a given location. More... | |
Typedefs | |
typedef EightNeighborhood::NeighborCode | EightNeighborCode |
typedef NeighborOffsetCirculator< EightNeighborCode > | EightNeighborOffsetCirculator |
typedef FourNeighborhood::NeighborCode | FourNeighborCode |
typedef NeighborOffsetCirculator< FourNeighborCode > | FourNeighborOffsetCirculator |
Enumerations | |
enum | AtImageBorder { NotAtBorder = 0, RightBorder = 1, LeftBorder = 2, TopBorder = 4, BottomBorder = 8, FrontBorder = 16 } |
Encode whether a point is near the image border. More... | |
enum | Direction { Error = -1, East = 0, North, West, South, DirectionCount, CausalFirst = North, CausalLast = West, AntiCausalFirst = South, AntiCausalLast = East } |
enum | Direction { Error = -1, East = 0, NorthEast, North, NorthWest, West, SouthWest, South, SouthEast, DirectionCount, CausalFirst = NorthEast, CausalLast = West, AntiCausalFirst = SouthWest, AntiCausalLast = East } |
Functions | |
AtImageBorder | isAtImageBorder (int x, int y, int width, int height) |
Find out whether a point is at the image border. More... | |
4- and 8-neighborhood definitions and circulators.
#include <vigra/pixelneighborhood.hxx>
See also: vigra::NeighborhoodCirculator
typedef FourNeighborhood::NeighborCode FourNeighborCode |
Export vigra::FourNeighborhood::NeighborCode into the scope of namespace vigra.
typedef EightNeighborhood::NeighborCode EightNeighborCode |
Export vigra::EightNeighborhood::NeighborCode into the scope of namespace vigra.
typedef NeighborOffsetCirculator<EightNeighborCode> EightNeighborOffsetCirculator |
Specialization of NeighborOffsetCirculator for 8-neighborhood.
typedef NeighborOffsetCirculator<FourNeighborCode> FourNeighborOffsetCirculator |
Specialization of NeighborOffsetCirculator for 4-neighborhood.
enum AtImageBorder |
Encode whether a point is near the image border.
This enum is used with isAtImageBorder() and vigra::RestrictedNeighborhoodCirculator.
#include <vigra/pixelneighborhood.hxx>
Namespace: vigra
Enumerator | |
---|---|
NotAtBorder |
|
RightBorder |
|
LeftBorder |
|
TopBorder |
|
BottomBorder |
|
FrontBorder |
|
enum Direction |
Freeman direction codes for the 4-neighborhood. East = 0
, North = 1
etc. DirectionCount
may be used for portable loop termination conditions. CausalFirst
and CausalLast
are the first and last (inclusive) neighbors in the causal neighborhood, i.e. in the set of neighbors that have already been visited when the image is traversed in scan order. AntiCausalFirst
and AntiCausalLast
are the opposite.
Enumerator | |
---|---|
Error |
|
East |
|
North |
|
West |
|
South |
|
DirectionCount |
|
CausalFirst |
|
CausalLast |
|
AntiCausalFirst |
|
AntiCausalLast |
|
enum Direction |
Freeman direction codes for the 8-neighborhood. East = 0
, North = 1
etc. DirectionCount
may be used for portable loop termination conditions. CausalFirst
and CausalLast
are the first and last (inclusive) neighbors in the causal neighborhood, i.e. in the set of neighbors that have already been visited when the image is traversed in scan order. AntiCausalFirst
and AntiCausalLast
are the opposite.
Enumerator | |
---|---|
Error |
|
East |
|
NorthEast |
|
North |
|
NorthWest |
|
West |
|
SouthWest |
|
South |
|
SouthEast |
|
DirectionCount |
|
CausalFirst |
|
CausalLast |
|
AntiCausalFirst |
|
AntiCausalLast |
|
AtImageBorder vigra::isAtImageBorder | ( | int | x, |
int | y, | ||
int | width, | ||
int | height | ||
) |
Find out whether a point is at the image border.
This function checks if x == 0 or x == width - 1 and y == 0 or y == height - 1 and returns the appropriate value of vigra::AtImageBorder, or zero when the point is not at the image border. The behavior of the function is undefined if (x,y) is not inside the image.
#include <vigra/pixelneighborhood.hxx>
Namespace: vigra
© Ullrich Köthe (ullrich.koethe@iwr.uni-heidelberg.de) |