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