51 template<
unsigned int VDimension = 2 >
63 itkStaticConstMacro(
Dimension,
unsigned int, VDimension);
74 for (
unsigned int i = 0; i < VDimension; i++ )
83 for (
unsigned int i = 0; i < VDimension; i++ )
95 for (
unsigned int i = 0; i < VDimension; i++ )
104 for (
unsigned int i = 0; i < VDimension; i++ )
116 for (
unsigned int i = 0; i < VDimension; i++ )
125 for (
unsigned int i = 0; i < VDimension; i++ )
137 for (
unsigned int i = 0; i < VDimension && same; i++ )
148 for (
unsigned int i = 0; i < VDimension && same; i++ )
185 {
m_Size[element] = val; }
194 {
return m_Size[element]; }
199 {
for (
unsigned int i = 0; i < VDimension; ++i ) {
m_Size[i] = value; } }
216 #if defined( CABLE_CONFIGURATION )
219 void operator=(
const Self &);
224 template<
unsigned int VDimension >
225 std::ostream & operator<<(std::ostream & os, const Size< VDimension > & size)
228 for (
unsigned int i = 0; i + 1 < VDimension; ++i )
230 os << size[i] <<
", ";
232 if ( VDimension >= 1 )
234 os << size[VDimension - 1];
const Self operator+(const Self &vec) const
itk::SizeValueType SizeValueType
Represent the size (bounds) of a n-dimensional image.
Size< VDimension > SizeType
const Self & operator+=(const Self &vec)
SizeValueType & operator[](unsigned int dim)
const Self & operator-=(const Self &vec)
const Self & operator*=(const Self &vec)
unsigned long SizeValueType
void SetSize(const SizeValueType val[VDimension])
const Self operator-(const Self &vec) const
bool operator==(const Self &vec) const
bool operator!=(const Self &vec) const
SizeValueType operator[](unsigned int dim) const
SizeValueType m_Size[VDimension]
SizeValueType GetElement(unsigned long element) const
void SetElement(unsigned long element, SizeValueType val)
const Self operator*(const Self &vec) const
void Fill(SizeValueType value)
const SizeValueType * GetSize() const
static const unsigned int Dimension
static unsigned int GetSizeDimension(void)