1 /*=========================================================================
2 Program: vv http://www.creatis.insa-lyon.fr/rio/vv
5 - University of LYON http://www.universite-lyon.fr/
6 - Léon Bérard cancer center http://oncora1.lyon.fnclcc.fr
7 - CREATIS CNRS laboratory http://www.creatis.insa-lyon.fr
9 This software is distributed WITHOUT ANY WARRANTY; without even
10 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11 PURPOSE. See the copyright notices for more information.
13 It is distributed under dual licence
15 - BSD See included LICENSE.txt file
16 - CeCILL-B http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
17 ======================================================================-====*/
18 #ifndef CLITKVFIMAGEIO_H
19 #define CLITKVFIMAGEIO_H
22 * @file clitkVfImageIO.h
23 * @author Simon Rit <Simon Rit <simon.rit@gmail.com>>
24 * @date Mon Sep 18 10:13:21 2006
26 * @brief VectorField .vf I/O header
33 #include "clitkCommon.h"
36 #include "itkImageIOBase.h"
43 //====================================================================
44 // Class for reading Vf Image file format
45 class VfImageIO: public itk::ImageIOBase
48 /** Standard class typedefs. */
49 typedef VfImageIO Self;
50 typedef itk::ImageIOBase Superclass;
51 typedef itk::SmartPointer<Self> Pointer;
52 typedef signed short int PixelType;
54 VfImageIO():Superclass() { mustWriteHeader = false; }
56 /** Method for creation through the object factory. */
59 /** Run-time type information (and related methods). */
60 itkTypeMacro(VfImageIO, ImageIOBase);
62 /*-------- This part of the interface deals with reading data. ------ */
63 virtual void ReadImageInformation();
64 virtual bool CanReadFile( const char* FileNameToRead );
65 virtual void Read(void * buffer);
67 /*-------- This part of the interfaces deals with writing data. ----- */
68 virtual void WriteImageInformation(bool keepOfStream);
69 virtual void WriteImageInformation() { WriteImageInformation(false); }
70 virtual bool CanWriteFile(const char* filename);
71 virtual void Write(const void* buffer);
78 }; // end class VfImageIO
82 // explicit template instantiation
83 //template class itk::CreateObjectFunction<clitk::VfImageIO>;
85 #endif /* end #define CLITKVFIMAGEIO_H */