]> Creatis software - clitk.git/blob - vv/vvImageWriter.cxx
remove MACRO for vvTool and others minors stuffs
[clitk.git] / vv / vvImageWriter.cxx
1 /*=========================================================================
2
3  Program:   vv
4  Language:  C++
5  Author :   Pierre Seroul (pierre.seroul@gmail.com)
6
7 Copyright (C) 2008
8 Léon Bérard cancer center http://oncora1.lyon.fnclcc.fr
9 CREATIS-LRMN http://www.creatis.insa-lyon.fr
10
11 This program is free software: you can redistribute it and/or modify
12 it under the terms of the GNU General Public License as published by
13 the Free Software Foundation, version 3 of the License.
14
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18 GNU General Public License for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with this program.  If not, see <http://www.gnu.org/licenses/>.
22
23 =========================================================================*/
24 #ifndef vvImageWriter_CXX
25 #define vvImageWriter_CXX
26
27 #include "vvImageWriter.h"
28 #include "vvImageWriter.txx"
29
30 #include <string.h>
31 //====================================================================
32 vvImageWriter::vvImageWriter() {
33     mImage = NULL;
34     mOutputFilename = "";
35     mLastError = "";
36     mUseAnObserver = false;
37 }
38 //====================================================================
39
40 //====================================================================
41 vvImageWriter::~vvImageWriter() {
42 }
43 //====================================================================
44
45 //====================================================================
46 void vvImageWriter::Update(int dim,std::string OutputPixelType) {
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 void vvImageWriter::SetOutputFileName(std::string filename) {
61     mOutputFilename = filename;
62 }
63 //====================================================================
64
65 #endif
66