ITK  4.1.0
Insight Segmentation and Registration Toolkit
itkReflectImageFilter.h
Go to the documentation of this file.
00001 /*=========================================================================
00002  *
00003  *  Copyright Insight Software Consortium
00004  *
00005  *  Licensed under the Apache License, Version 2.0 (the "License");
00006  *  you may not use this file except in compliance with the License.
00007  *  You may obtain a copy of the License at
00008  *
00009  *         http://www.apache.org/licenses/LICENSE-2.0.txt
00010  *
00011  *  Unless required by applicable law or agreed to in writing, software
00012  *  distributed under the License is distributed on an "AS IS" BASIS,
00013  *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00014  *  See the License for the specific language governing permissions and
00015  *  limitations under the License.
00016  *
00017  *=========================================================================*/
00018 #ifndef __itkReflectImageFilter_h
00019 #define __itkReflectImageFilter_h
00020 
00021 #include "itkImageToImageFilter.h"
00022 
00023 namespace itk
00024 {
00034 template< class TInputImage, class TOutputImage >
00035 class ITK_EXPORT ReflectImageFilter:public ImageToImageFilter< TInputImage, TOutputImage >
00036 {
00037 public:
00039   typedef ReflectImageFilter                              Self;
00040   typedef ImageToImageFilter< TInputImage, TOutputImage > Superclass;
00041   typedef SmartPointer< Self >                            Pointer;
00042   typedef SmartPointer< const Self >                      ConstPointer;
00043 
00045   itkNewMacro(Self);
00046 
00048   itkTypeMacro(ReflectImageFilter, ImageToImageFilter);
00049 
00051   typedef TInputImage                            InputImageType;
00052   typedef typename    InputImageType::Pointer    InputImagePointer;
00053   typedef typename    InputImageType::RegionType InputImageRegionType;
00054   typedef typename    InputImageType::PixelType  InputImagePixelType;
00055 
00056   typedef TOutputImage                             OutputImageType;
00057   typedef typename     OutputImageType::Pointer    OutputImagePointer;
00058   typedef typename     OutputImageType::RegionType OutputImageRegionType;
00059   typedef typename     OutputImageType::PixelType  OutputImagePixelType;
00060 
00062   itkGetConstMacro(Direction, unsigned int);
00063   itkSetMacro(Direction, unsigned int);
00065 
00067   itkStaticConstMacro(InputImageDimension, unsigned int,
00068                       TInputImage::ImageDimension);
00069   itkStaticConstMacro(OutputImageDimension, unsigned int,
00070                       TOutputImage::ImageDimension);
00072 
00073 #ifdef ITK_USE_CONCEPT_CHECKING
00074 
00075   itkConceptMacro( SameDimensionCheck,
00076                    ( Concept::SameDimension< InputImageDimension, OutputImageDimension > ) );
00077   itkConceptMacro( InputConvertibleToOutputCheck,
00078                    ( Concept::Convertible< InputImagePixelType, OutputImagePixelType > ) );
00079 
00081 #endif
00082 protected:
00083   ReflectImageFilter();
00084   virtual ~ReflectImageFilter() {}
00085   void PrintSelf(std::ostream & os, Indent indent) const;
00087 
00092   void GenerateData(void);
00093 
00094 private:
00095   ReflectImageFilter(const Self &); //purposely not implemented
00096   void operator=(const Self &);     //purposely not implemented
00097 
00098   unsigned int m_Direction;
00099 };
00100 } // end namespace itk
00101 
00102 #ifndef ITK_MANUAL_INSTANTIATION
00103 #include "itkReflectImageFilter.hxx"
00104 #endif
00105 
00106 #endif
00107