Orfeo Toolbox  3.16
itkLabelReconstructionLabelMapFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Insight Segmentation & Registration Toolkit
4  Module: $RCSfile: itkLabelReconstructionLabelMapFilter.h,v $
5  Language: C++
6  Date: $Date: 2006/03/28 19:59:05 $
7  Version: $Revision: 1.6 $
8 
9  Copyright (c) Insight Software Consortium. All rights reserved.
10  See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
11 
12  This software is distributed WITHOUT ANY WARRANTY; without even
13  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14  PURPOSE. See the above copyright notices for more information.
15 
16 =========================================================================*/
17 #ifndef __itkLabelReconstructionLabelMapFilter_h
18 #define __itkLabelReconstructionLabelMapFilter_h
19 
22 
23 namespace itk {
29 template<class TImage, class TMarkerImage, class TAttributeAccessor=
30  typename Functor::AttributeLabelObjectAccessor< typename TImage::LabelObjectType > >
32  public InPlaceLabelMapFilter<TImage>
33 {
34 public:
41 
43  typedef TImage ImageType;
44  typedef typename ImageType::Pointer ImagePointer;
45  typedef typename ImageType::ConstPointer ImageConstPointer;
46  typedef typename ImageType::PixelType PixelType;
47  typedef typename ImageType::IndexType IndexType;
48  typedef typename ImageType::LabelObjectType LabelObjectType;
49 
50  typedef TMarkerImage MarkerImageType;
51  typedef typename MarkerImageType::Pointer MarkerImagePointer;
52  typedef typename MarkerImageType::ConstPointer MarkerImageConstPointer;
53  typedef typename MarkerImageType::PixelType MarkerImagePixelType;
54 
55  typedef TAttributeAccessor AttributeAccessorType;
56 
58  itkStaticConstMacro(ImageDimension, unsigned int,
59  TImage::ImageDimension);
60 
62  itkNewMacro(Self);
63 
67 
68 #ifdef ITK_USE_CONCEPT_CHECKING
69 
70 /* itkConceptMacro(InputEqualityComparableCheck,
71  (Concept::EqualityComparable<PixelType>));
72  itkConceptMacro(IntConvertibleToInputCheck,
73  (Concept::Convertible<int, PixelType>));
74  itkConceptMacro(InputOStreamWritableCheck,
75  (Concept::OStreamWritable<PixelType>));*/
77 #endif
78 
80  void SetMarkerImage(TMarkerImage *input)
81  {
82  // Process object is not const-correct so the const casting is required.
83  this->SetNthInput( 1, const_cast<TMarkerImage *>(input) );
84  }
85 
87  MarkerImageType * GetMarkerImage()
88  {
89  return static_cast<MarkerImageType*>(const_cast<DataObject *>(this->ProcessObject::GetInput(1)));
90  }
91 
93  void SetInput1(TImage *input)
94  {
95  this->SetInput( input );
96  }
97 
99  void SetInput2(TMarkerImage *input)
100  {
101  this->SetMarkerImage( input );
102  }
103 
104 protected:
107 
108  virtual void ThreadedGenerateData( LabelObjectType * labelObject );
109 
110 private:
111  LabelReconstructionLabelMapFilter(const Self&); //purposely not implemented
112  void operator=(const Self&); //purposely not implemented
113 
114 } ; // end of class
115 
116 } // end namespace itk
117 
118 #ifndef ITK_MANUAL_INSTANTIATION
120 #endif
121 
122 #endif
123 
124 

Generated at Sat Feb 2 2013 23:49:53 for Orfeo Toolbox with doxygen 1.8.1.1