1 #ifndef CLITKVFIMAGEIO_H
2 #define CLITKVFIMAGEIO_H
5 * @file clitkVfImageIO.h
6 * @author Simon Rit <Simon Rit <simon.rit@gmail.com>>
7 * @date Mon Sep 18 10:13:21 2006
9 * @brief VectorField .vf I/O header
16 #include "clitkCommon.h"
19 #include "itkImageIOBase.h"
26 //====================================================================
27 // Class for reading Vf Image file format
28 class VfImageIO: public itk::ImageIOBase
31 /** Standard class typedefs. */
32 typedef VfImageIO Self;
33 typedef itk::ImageIOBase Superclass;
34 typedef itk::SmartPointer<Self> Pointer;
35 typedef signed short int PixelType;
37 VfImageIO():Superclass() { mustWriteHeader = false; }
39 /** Method for creation through the object factory. */
42 /** Run-time type information (and related methods). */
43 itkTypeMacro(VfImageIO, ImageIOBase);
45 /*-------- This part of the interface deals with reading data. ------ */
46 virtual void ReadImageInformation();
47 virtual bool CanReadFile( const char* FileNameToRead );
48 virtual void Read(void * buffer);
50 /*-------- This part of the interfaces deals with writing data. ----- */
51 virtual void WriteImageInformation(bool keepOfStream);
52 virtual void WriteImageInformation() { WriteImageInformation(false); }
53 virtual bool CanWriteFile(const char* filename);
54 virtual void Write(const void* buffer);
61 }; // end class VfImageIO
65 // explicit template instantiation
66 template class itk::CreateObjectFunction<clitk::VfImageIO>;
68 #endif /* end #define CLITKVFIMAGEIO_H */