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