]> Creatis software - clitk.git/blob - registration/clitkDeformationListStatisticsFilter.h
Debug RTStruct conversion with empty struc
[clitk.git] / registration / clitkDeformationListStatisticsFilter.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 __clitkDeformationListStatistics_h
19 #define __clitkDeformationListStatistics_h
20 #include "clitkImageCommon.h"
21 #include "clitkList.h"
22 #include "clitkLists.h"
23
24 //itk include
25 #include "itkLightObject.h"
26 #include "itkImage.h"
27 #include "itkImageRegionIterator.h"
28 #include "itkImageRegionIteratorWithIndex.h"
29 #include "itkNumericTraits.h"
30 #if ITK_VERSION_MAJOR <= 4
31 #include "itkSimpleFastMutexLock.h"
32 #else
33 #include <mutex>
34 #endif
35 #include "itkImageMaskSpatialObject.h"
36
37 namespace clitk
38 {
39   
40   template < class ListItemType >  
41   class ITK_EXPORT DeformationListStatisticsFilter : public itk::LightObject
42   
43   {
44   public:
45     typedef DeformationListStatisticsFilter     Self;
46     typedef itk::LightObject    Superclass;
47     typedef itk::SmartPointer<Self>            Pointer;
48     typedef itk::SmartPointer<const Self>      ConstPointer;
49
50    
51     /** Method for creation through the object factory. */
52     itkNewMacro(Self);  
53     
54      //====================================
55     //Typedefs
56     typedef typename ListItemType::ValueType ValueType;
57     itkStaticConstMacro(Dimension, unsigned int, ListItemType::Dimension);
58     //typedef itk::Vector<ValueType, Dimension> ListItemType;
59     typedef std::vector<ValueType> ValueListType;
60     typedef clitk::List<ListItemType> ListType;
61     typedef clitk::Lists<ListItemType> ListsType;  
62
63     //====================================
64     //Get
65     void GetStatistics( const ListType &,  ValueType & mean, ValueType & sd, ValueType & max);
66     void GetStatistics( const ListsType &,  ValueListType & mean, ValueListType & sd, ValueListType & max);
67     void GetStatistics( const ListsType &,  ValueType & mean , ValueType & sd, ValueType & max, ValueListType & meanList, ValueListType & sdList, ValueListType & maxList);
68  
69     void GetStatistics( const ListType &, ListItemType & meanXYZ, ListItemType & sdXYZ, ListItemType & maxXYZ );
70     void GetStatistics( const ListsType &, ListType & meanXYZ, ListType & sdXYZ, ListType & maxXYZ );
71     void GetStatistics( const ListsType &, ListItemType & mean , ListItemType & sd, ListItemType & max, ListType & meanXYZList, ListType & sdXYZList, ListType & maxXYZList );
72     
73   protected:
74     DeformationListStatisticsFilter(){};
75     ~DeformationListStatisticsFilter() {};
76     
77   private:
78
79   };
80
81
82
83
84
85 } // end namespace clitk
86 #ifndef ITK_MANUAL_INSTANTIATION
87 #include "clitkDeformationListStatisticsFilter.txx"
88 #endif
89
90 #endif // #define __clitkDeformationListStatistics_h