[ VIGRA Homepage | Function Index | Class Index | Namespaces | File List | Main Page ]
Encapsulation of direction management of neighbors for a 3D 6-neighborhood. More...
#include <vigra/voxelneighborhood.hxx>
Public Types | |
enum | Direction |
Encapsulation of direction management of neighbors for a 3D 6-neighborhood.
provides enumeration of all directions. DirectionCount may be used for portable loop termination conditions.
|
static |
The number of valid neighbors if the current center is at the volume border.
|
static |
The valid direction codes when the center is at the volume border. index must be in the range 0...nearBorderDirectionCount(b)-1
.
|
static |
The valid direction three codes in anti causal direction (means: look back in scanline direction)when the center is at the volume border. Should be used with isAtVolumeBorderCausal to determine the Directions, as this avoids using of the nonesense border ids (e.g. 0,1,8,9...) of this table. index must be in the range 0...nearBorderDirectionCount(b)-1
.
transform direction code into corresponding Diff3D offset. (note: there is no bounds checking on the code you pass.)
Equivalent to diff(static_cast<Direction>(code))
. (note: there is no bounds checking on the code you pass.)
Get the relative offset from one neighbor to the other. For example, relativeDiff(East, West) == multi_differencetype(-2,0,0)
. (note: there is no bounds checking on the code you pass.)
Equivalent to relativeDiff(static_cast<Direction>(fromCode), static_cast<Direction>(toCode)). (note: there is no bounds checking on the code you pass.)
transform Diff3D offset into corresponding direction code. The code Direction::Error
will be returned if diff
is not in the 3DSix-Neighborhood.
Check whether a code refers to a diagonal direction. Useful if you want to abstract the differences between 6- and 26-neighborhood. Always false
for 6-neighborhood.
© Ullrich Köthe (ullrich.koethe@iwr.uni-heidelberg.de) |