ITK
4.2.0
Insight Segmentation and Registration Toolkit
|
#include <itkImageRandomConstIteratorWithIndex.h>
Public Types | |
typedef Superclass::AccessorType | AccessorType |
typedef Superclass::ImageType | ImageType |
typedef Superclass::IndexType | IndexType |
typedef Superclass::IndexValueType | IndexValueType |
typedef Superclass::InternalPixelType | InternalPixelType |
typedef Superclass::OffsetType | OffsetType |
typedef Superclass::OffsetValueType | OffsetValueType |
typedef Superclass::PixelContainer | PixelContainer |
typedef Superclass::PixelContainerPointer | PixelContainerPointer |
typedef Superclass::PixelType | PixelType |
typedef Superclass::RegionType | RegionType |
typedef ImageRandomConstIteratorWithIndex | Self |
typedef Superclass::SizeType | SizeType |
typedef Superclass::SizeValueType | SizeValueType |
typedef ImageConstIteratorWithIndex < TImage > | Superclass |
Public Types inherited from itk::ImageConstIteratorWithIndex< TImage > | |
typedef TImage::AccessorFunctorType | AccessorFunctorType |
Private Types | |
typedef Statistics::MersenneTwisterRandomVariateGenerator::Pointer | GeneratorPointer |
Private Member Functions | |
void | RandomJump () |
Private Attributes | |
GeneratorPointer | m_Generator |
SizeValueType | m_NumberOfPixelsInRegion |
SizeValueType | m_NumberOfSamplesDone |
SizeValueType | m_NumberOfSamplesRequested |
Additional Inherited Members | |
Static Public Member Functions inherited from itk::ImageConstIteratorWithIndex< TImage > | |
static unsigned int | GetImageDimension () |
Static Public Attributes inherited from itk::ImageConstIteratorWithIndex< TImage > | |
static const unsigned int | ImageDimension = TImage::ImageDimension |
Protected Attributes inherited from itk::ImageConstIteratorWithIndex< TImage > | |
const InternalPixelType * | m_Begin |
IndexType | m_BeginIndex |
const InternalPixelType * | m_End |
IndexType | m_EndIndex |
TImage::ConstWeakPointer | m_Image |
OffsetValueType | m_OffsetTable [ImageDimension+1] |
AccessorType | m_PixelAccessor |
AccessorFunctorType | m_PixelAccessorFunctor |
const InternalPixelType * | m_Position |
IndexType | m_PositionIndex |
RegionType | m_Region |
bool | m_Remaining |
A multi-dimensional image iterator that visits a random set of pixels within an image region.
ImageRandomConstIteratorWithIndex is a multi-dimensional iterator class that is templated over image type. ImageRandomConstIteratorWithIndex is constrained to walk only within the specified region. It samples random pixel positions at each increment or decrement.
ImageRandomConstIteratorWithIndex assumes a particular layout of the image data. The is arranged in a 1D array as if it were [][][][slice][row][col] with Index[0] = col, Index[1] = row, Index[2] = slice, etc.
The operator++ method provides a simple syntax for walking around a region of a multidimensional image. operator++ performs a jump to a random position within the specified image region. This is designed to facilitate the extraction of random samples from the image.
This is the typical use of this iterator in a loop:
or
Definition at line 116 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::AccessorType itk::ImageRandomConstIteratorWithIndex< TImage >::AccessorType |
Accessor type that converts data between internal and external representations.
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 133 of file itkImageRandomConstIteratorWithIndex.h.
|
private |
Definition at line 218 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::ImageType itk::ImageRandomConstIteratorWithIndex< TImage >::ImageType |
Image typedef support.
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 128 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::IndexType itk::ImageRandomConstIteratorWithIndex< TImage >::IndexType |
Inherit types from the superclass
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 124 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::IndexValueType itk::ImageRandomConstIteratorWithIndex< TImage >::IndexValueType |
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Definition at line 134 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::InternalPixelType itk::ImageRandomConstIteratorWithIndex< TImage >::InternalPixelType |
Internal Pixel Type
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 131 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::OffsetType itk::ImageRandomConstIteratorWithIndex< TImage >::OffsetType |
Type of the Offset taken from the image
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 126 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::OffsetValueType itk::ImageRandomConstIteratorWithIndex< TImage >::OffsetValueType |
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Definition at line 135 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::PixelContainer itk::ImageRandomConstIteratorWithIndex< TImage >::PixelContainer |
PixelContainer typedef support. Used to refer to the container for the pixel data. While this was already typdef'ed in the superclass, it needs to be redone here for this subclass to compile properly with gcc.
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 129 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::PixelContainerPointer itk::ImageRandomConstIteratorWithIndex< TImage >::PixelContainerPointer |
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 130 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::PixelType itk::ImageRandomConstIteratorWithIndex< TImage >::PixelType |
External Pixel Type
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 132 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::RegionType itk::ImageRandomConstIteratorWithIndex< TImage >::RegionType |
Region typedef support.
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 127 of file itkImageRandomConstIteratorWithIndex.h.
typedef ImageRandomConstIteratorWithIndex itk::ImageRandomConstIteratorWithIndex< TImage >::Self |
Standard class typedefs.
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 120 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::SizeType itk::ImageRandomConstIteratorWithIndex< TImage >::SizeType |
Size typedef support.
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 125 of file itkImageRandomConstIteratorWithIndex.h.
typedef Superclass::SizeValueType itk::ImageRandomConstIteratorWithIndex< TImage >::SizeValueType |
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Definition at line 136 of file itkImageRandomConstIteratorWithIndex.h.
typedef ImageConstIteratorWithIndex< TImage > itk::ImageRandomConstIteratorWithIndex< TImage >::Superclass |
Reimplemented in itk::ImageRandomIteratorWithIndex< TImage >.
Definition at line 121 of file itkImageRandomConstIteratorWithIndex.h.
itk::ImageRandomConstIteratorWithIndex< TImage >::ImageRandomConstIteratorWithIndex | ( | ) |
Default constructor. Needed since we provide a cast constructor.
|
inline |
Definition at line 140 of file itkImageRandomConstIteratorWithIndex.h.
itk::ImageRandomConstIteratorWithIndex< TImage >::ImageRandomConstIteratorWithIndex | ( | const ImageType * | ptr, |
const RegionType & | region | ||
) |
Constructor establishes an iterator to walk a particular image and a particular region of that image.
|
inline |
Constructor that can be used to cast from an ImageIterator to an ImageRandomConstIteratorWithIndex. Many routines return an ImageIterator, but for a particular task, you may want an ImageRandomConstIteratorWithIndex. Rather than provide overloaded APIs that return different types of Iterators, itk returns ImageIterators and uses constructors to cast from an ImageIterator to a ImageRandomConstIteratorWithIndex.
Definition at line 152 of file itkImageRandomConstIteratorWithIndex.h.
SizeValueType itk::ImageRandomConstIteratorWithIndex< TImage >::GetNumberOfSamples | ( | void | ) | const |
|
inline |
Move an iterator to the beginning of the region.
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Definition at line 158 of file itkImageRandomConstIteratorWithIndex.h.
|
inline |
Move an iterator to one position past the End of the region.
Definition at line 166 of file itkImageRandomConstIteratorWithIndex.h.
|
inline |
Is the iterator at the beginning of the region?
Definition at line 174 of file itkImageRandomConstIteratorWithIndex.h.
|
inline |
Is the iterator at the end of the region?
Reimplemented from itk::ImageConstIteratorWithIndex< TImage >.
Definition at line 180 of file itkImageRandomConstIteratorWithIndex.h.
|
inline |
Increment (prefix) the selected dimension. No bounds checking is performed.
Definition at line 187 of file itkImageRandomConstIteratorWithIndex.h.
|
inline |
Decrement (prefix) the selected dimension. No bounds checking is performed.
Definition at line 197 of file itkImageRandomConstIteratorWithIndex.h.
|
private |
void itk::ImageRandomConstIteratorWithIndex< TImage >::ReinitializeSeed | ( | ) |
Reinitialize the seed of the random number generator
void itk::ImageRandomConstIteratorWithIndex< TImage >::ReinitializeSeed | ( | int | ) |
void itk::ImageRandomConstIteratorWithIndex< TImage >::SetNumberOfSamples | ( | SizeValueType | number | ) |
Set/Get number of random samples to get from the image region
|
private |
Definition at line 219 of file itkImageRandomConstIteratorWithIndex.h.
|
private |
Definition at line 222 of file itkImageRandomConstIteratorWithIndex.h.
|
private |
Definition at line 221 of file itkImageRandomConstIteratorWithIndex.h.
|
private |
Definition at line 220 of file itkImageRandomConstIteratorWithIndex.h.