18 #ifndef itkImageRegionSplitter_h
19 #define itkImageRegionSplitter_h
67 template<
unsigned int VImageDimension >
84 itkStaticConstMacro(ImageDimension,
unsigned int, VImageDimension);
88 {
return VImageDimension; }
106 virtual unsigned int GetNumberOfSplits(
const RegionType & region,
107 unsigned int requestedNumber);
113 virtual RegionType GetSplit(
unsigned int i,
unsigned int numberOfPieces,
123 unsigned int requestedNumber)
const ITK_OVERRIDE
133 Self *nonconst_this =
const_cast<Self*
>(
this);
140 unsigned int numberOfPieces,
152 Self *nonconst_this =
const_cast<Self*
>(
this);
153 region = nonconst_this->
GetSplit(i, numberOfPieces, region);
155 for (
unsigned int d = 0; d < dim; ++d)
157 regionIndex[d] = region.
GetIndex(d);
158 regionSize[d] = region.
GetSize(d);
160 return numberOfPieces;
163 virtual void PrintSelf(std::ostream & os,
Indent indent)
const ITK_OVERRIDE;
170 #ifndef ITK_MANUAL_INSTANTIATION
171 #include "itkImageRegionSplitter.hxx"
ImageRegionSplitterBase Superclass
SmartPointer< Self > Pointer
const IndexType & GetIndex() const
itk::SizeValueType SizeValueType
Divide a region into several pieces.
Represent the size (bounds) of a n-dimensional image.
signed long IndexValueType
SizeType::SizeValueType SizeValueType
An image region represents a structured region of data.
Size< VImageDimension > SizeType
virtual unsigned int GetNumberOfSplitsInternal(unsigned int, const IndexValueType regionIndex[], const SizeValueType regionSize[], unsigned int requestedNumber) const override
SmartPointer< const Self > ConstPointer
void SetSize(const SizeValueType val[VDimension])
Index< VImageDimension > IndexType
unsigned int GetSplit(unsigned int i, unsigned int numberOfPieces, ImageRegion< VImageDimension > ®ion) const
Get a region definition that represents the ith piece a specified region.
unsigned int GetNumberOfSplits(const ImageRegion< VImageDimension > ®ion, unsigned int requestedNumber) const
Divide an image region into several pieces.
const SizeType & GetSize() const
ImageRegion< VImageDimension > RegionType
virtual unsigned int GetSplitInternal(unsigned int dim, unsigned int i, unsigned int numberOfPieces, IndexValueType regionIndex[], SizeValueType regionSize[]) const override
Control indentation during Print() invocation.
Base class for most ITK classes.
void SetIndex(const IndexValueType val[VIndexDimension])
static unsigned int GetImageDimension()