17 #ifndef __itkSpecialCoordinatesImage_h
18 #define __itkSpecialCoordinatesImage_h
95 template <
class TPixel,
unsigned int VImageDimension=2>
140 itkStaticConstMacro(ImageDimension,
unsigned int, VImageDimension);
180 this->SetLargestPossibleRegion(region);
181 this->SetBufferedRegion(region);
182 this->SetRequestedRegion(region);
188 this->SetLargestPossibleRegion(region);
189 this->SetBufferedRegion(region);
190 this->SetRequestedRegion(region);
195 virtual void Initialize();
199 void FillBuffer (
const TPixel& value);
206 void SetPixel(
const IndexType &index,
const TPixel& value)
208 typename Superclass::OffsetValueType offset = this->ComputeOffset(index);
209 (*m_Buffer)[offset] = value;
218 typename Superclass::OffsetValueType offset = this->ComputeOffset(index);
219 return ( (*m_Buffer)[offset] );
228 typename Superclass::OffsetValueType offset = this->ComputeOffset(index);
229 return ( (*m_Buffer)[offset] );
237 {
return this->GetPixel(index); }
244 {
return this->GetPixel(index); }
248 TPixel *GetBufferPointer()
249 {
return m_Buffer ? m_Buffer->GetBufferPointer() : 0; }
250 const TPixel *GetBufferPointer()
const
251 {
return m_Buffer ? m_Buffer->GetBufferPointer() : 0; }
255 {
return m_Buffer.GetPointer(); }
258 {
return m_Buffer.GetPointer(); }
262 void SetPixelContainer( PixelContainer *container );
281 virtual void SetOrigin(
const double [VImageDimension] ) {}
282 virtual void SetOrigin(
const float [VImageDimension] ) {}
310 void PrintSelf(std::ostream& os,
Indent indent)
const;
314 void operator=(
const Self&);
323 #define ITK_TEMPLATE_SpecialCoordinatesImage(_, EXPORT, x, y) namespace itk { \
324 _(2(class EXPORT SpecialCoordinatesImage< ITK_TEMPLATE_2 x >)) \
325 namespace Templates { typedef SpecialCoordinatesImage< ITK_TEMPLATE_2 x > \
326 SpecialCoordinatesImage##y; } \
329 #if ITK_TEMPLATE_EXPLICIT
330 # include "Templates/itkSpecialCoordinatesImage+-.h"