ITK  4.4.0
Insight Segmentation and Registration Toolkit
itkReflectImageFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef __itkReflectImageFilter_h
19 #define __itkReflectImageFilter_h
20 #if !defined( ITK_LEGACY_REMOVE )
21 
22 #include "itkImageToImageFilter.h"
23 
24 namespace itk
25 {
37 template< class TInputImage, class TOutputImage >
38 class ITK_EXPORT ReflectImageFilter:public ImageToImageFilter< TInputImage, TOutputImage >
39 {
40 public:
42  typedef ReflectImageFilter Self;
43  typedef ImageToImageFilter< TInputImage, TOutputImage > Superclass;
44  typedef SmartPointer< Self > Pointer;
45  typedef SmartPointer< const Self > ConstPointer;
46 
48  itkNewMacro(Self);
49 
51  itkTypeMacro(ReflectImageFilter, ImageToImageFilter);
52 
54  typedef TInputImage InputImageType;
55  typedef typename InputImageType::Pointer InputImagePointer;
56  typedef typename InputImageType::RegionType InputImageRegionType;
57  typedef typename InputImageType::PixelType InputImagePixelType;
58 
59  typedef TOutputImage OutputImageType;
60  typedef typename OutputImageType::Pointer OutputImagePointer;
61  typedef typename OutputImageType::RegionType OutputImageRegionType;
62  typedef typename OutputImageType::PixelType OutputImagePixelType;
63 
65  itkGetConstMacro(Direction, unsigned int);
66  itkSetMacro(Direction, unsigned int);
68 
70  itkStaticConstMacro(InputImageDimension, unsigned int,
71  TInputImage::ImageDimension);
72  itkStaticConstMacro(OutputImageDimension, unsigned int,
73  TOutputImage::ImageDimension);
75 
76 #ifdef ITK_USE_CONCEPT_CHECKING
77 
78  itkConceptMacro( SameDimensionCheck,
79  ( Concept::SameDimension< InputImageDimension, OutputImageDimension > ) );
80  itkConceptMacro( InputConvertibleToOutputCheck,
81  ( Concept::Convertible< InputImagePixelType, OutputImagePixelType > ) );
82 
84 #endif
85 
86 protected:
87  ReflectImageFilter();
88  virtual ~ReflectImageFilter() {}
89  void PrintSelf(std::ostream & os, Indent indent) const;
90 
95  void GenerateData(void);
96 
97 private:
98  ReflectImageFilter(const Self &); //purposely not implemented
99  void operator=(const Self &); //purposely not implemented
100 
101  unsigned int m_Direction;
102 };
103 } // end namespace itk
104 
105 #ifndef ITK_MANUAL_INSTANTIATION
106 #include "itkReflectImageFilter.hxx"
107 #endif
108 
109 #endif //#if !defined( ITK_LEGACY_REMOVE )
110 #endif
111