]> Creatis software - clitk.git/blob - common/vvImageWriter.cxx
changes in license header
[clitk.git] / common / vvImageWriter.cxx
1 /*=========================================================================
2   Program:   vv                     http://www.creatis.insa-lyon.fr/rio/vv
3
4   Authors belong to:
5   - University of LYON              http://www.universite-lyon.fr/
6   - Léon Bérard cancer center       http://www.centreleonberard.fr
7   - CREATIS CNRS laboratory         http://www.creatis.insa-lyon.fr
8
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.
12
13   It is distributed under dual licence
14
15   - BSD        See included LICENSE.txt file
16   - CeCILL-B   http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
17 ===========================================================================**/
18 #ifndef VVIMAGEWRITER_CXX
19 #define VVIMAGEWRITER_CXX
20
21 #include "vvImageWriter.h"
22 #include "vvImageWriter.txx"
23
24 #include <string.h>
25
26 //------------------------------------------------------------------------------
27 vvImageWriter::vvImageWriter()
28 {
29   mImage = NULL;
30   mOutputFilename = "";
31   mLastError = "";
32   mUseAnObserver = false;
33 }
34 //------------------------------------------------------------------------------
35
36
37 //------------------------------------------------------------------------------
38 vvImageWriter::~vvImageWriter()
39 {
40 }
41 //------------------------------------------------------------------------------
42
43
44 //------------------------------------------------------------------------------
45 void vvImageWriter::Update(int dim,std::string OutputPixelType)
46 {
47   //CALL_FOR_ALL_DIMS(dim,UpdateWithDim,inputPixelType);
48   if (dim == 2)
49     UpdateWithDim<2>(OutputPixelType);
50   else if (dim == 3)
51     UpdateWithDim<3>(OutputPixelType);
52   else if (dim == 4)
53     UpdateWithDim<4>(OutputPixelType);
54   else
55     std::cerr << "dim not know in Update ! " << std::endl;
56 }
57 //------------------------------------------------------------------------------
58
59
60 //------------------------------------------------------------------------------
61 void vvImageWriter::SetOutputFileName(std::string filename)
62 {
63   mOutputFilename = filename;
64 }
65 //------------------------------------------------------------------------------
66
67 #endif
68