]> Creatis software - clitk.git/blob - registration/clitkLists.h
Debug RTStruct conversion with empty struc
[clitk.git] / registration / clitkLists.h
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 clitkLists_h
19 #define clitkLists_h
20 /**
21    =================================================
22    * @file   clitkLists.h
23    * @author Jef Vandemeulebroucke <jef@creatis.insa-lyon.fr>
24    * @date   30 April 2008
25    * 
26    * @brief 
27    * 
28    =================================================*/
29
30 #include "clitkCommon.h"
31 #include "clitkIO.h"
32 #include "clitkList.h"
33
34 // itk include
35 #include "itkLightObject.h"
36
37 using namespace std;
38
39 namespace clitk{
40
41   template <class ListItemType > 
42   class Lists: public std::vector<clitk::List<ListItemType> >
43   {
44   public:
45     //=====================================================================================
46     //Typedefs
47     typedef typename ListItemType::ValueType ValueType;
48     itkStaticConstMacro(Dimension, unsigned int, ListItemType::Dimension);
49     typedef List<ListItemType> ListType;
50     typedef itk::Image<signed short, Dimension> ImageType;
51
52     //=====================================================================================  
53     // IO
54     void Read(const std::vector<std::string>& fileNames, bool verbose=false);
55     void ReadAndConvertPointPairs(const std::vector<std::string>& fileNames, ListType& refList, const typename ImageType::Pointer referenceImage , bool verbose=false);
56     void Write(const std::vector<std::string> fileNames, const bool verbose);
57     void Print();
58   
59     //=====================================================================================
60     // Members
61     Lists< itk::FixedArray<double,1> > Norm(void);
62           
63     //=====================================================================================
64     //Constructors - Destructors
65     Lists(){};
66     Lists(unsigned int size){this->resize(size);};
67     Lists(const std::vector<std::string> fileNames, bool verbose=false ){Read(fileNames, verbose);}
68     ~Lists(){};
69   
70
71   protected:
72
73
74   };
75
76
77 } // namespace clitk
78
79 #ifndef ITK_MANUAL_INSTANTIATION
80 #include "clitkLists.txx"
81 #endif
82
83 #endif