Region representing a 3D box. More...
#include <ImageViz/SbImageDataAccessor.h>
Public Member Functions | |
SubVolumeRegion (const SbBox3i32 &subVolume) | |
Constructor. | |
virtual SbVec4i32 | getPosition (uint64_t i) const |
Returns position of the ith voxel of the region. | |
virtual SbVec4i32 | getSize () const |
Returns the dimensions of the region. | |
virtual uint64_t | getNumVoxel () const |
Returns number of voxels contained in the region. | |
virtual SbBox4i32 | getExtent () const |
Returns extent of region. | |
Region representing a 3D box.
Voxels are ordered line by line, slice by slice. 1st voxel is in corner (minX, minY, minZ). 2nd voxel is in (minX+1, minY, minZ). Last voxel is in (maxX, maxY, maxZ)
Definition at line 104 of file SbImageDataAccessor.h.
SbImageDataAccessor::SubVolumeRegion::SubVolumeRegion | ( | const SbBox3i32 & | subVolume | ) |
Constructor.
|
inlinevirtual |
Returns extent of region.
As this region is a 3D space, the last coordinates of the extent are always 0. The 3 first coordinates correspond to the SbBox3i32 given in the constructor.
Implements SbImageDataAccessor::Region.
Definition at line 128 of file SbImageDataAccessor.h.
|
virtual |
Returns number of voxels contained in the region.
Implements SbImageDataAccessor::Region.
|
virtual |
Returns position of the ith voxel of the region.
ie. getPosition(0) returns the lower left corner of box given in constructor.
Throws out of range exception if i >= getNumVoxel()
Implements SbImageDataAccessor::Region.
|
inlinevirtual |
Returns the dimensions of the region.
As this region represent a 3D space, getDimension()[3] is always 1. getDimension()[0], [1] and [2] correspond to size of SbBox3i32 given in constructor.
Implements SbImageDataAccessor::Region.
Definition at line 120 of file SbImageDataAccessor.h.