ITK
4.1.0
Insight Segmentation and Registration Toolkit
|
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 __itkHalfToFullHermitianImageFilter_h 00019 #define __itkHalfToFullHermitianImageFilter_h 00020 00021 #include "itkImageToImageFilter.h" 00022 00023 namespace itk 00024 { 00043 template< class TInputImage > 00044 class HalfToFullHermitianImageFilter : 00045 public ImageToImageFilter< TInputImage, TInputImage > 00046 { 00047 public: 00049 typedef TInputImage InputImageType; 00050 typedef typename InputImageType::PixelType InputImagePixelType; 00051 typedef typename InputImageType::IndexType InputImageIndexType; 00052 typedef typename InputImageType::IndexValueType InputImageIndexValueType; 00053 typedef typename InputImageType::SizeType InputImageSizeType; 00054 typedef typename InputImageType::SizeValueType InputImageSizeValueType; 00055 typedef typename InputImageType::RegionType InputImageRegionType; 00056 typedef TInputImage OutputImageType; 00057 typedef typename OutputImageType::PixelType OutputImagePixelType; 00058 typedef typename OutputImageType::IndexType OutputImageIndexType; 00059 typedef typename OutputImageType::IndexValueType OutputImageIndexValueType; 00060 typedef typename OutputImageType::SizeType OutputImageSizeType; 00061 typedef typename OutputImageType::SizeValueType OutputImageSizeValueType; 00062 typedef typename OutputImageType::RegionType OutputImageRegionType; 00063 00064 typedef HalfToFullHermitianImageFilter Self; 00065 typedef ImageToImageFilter< TInputImage, TInputImage > Superclass; 00066 typedef SmartPointer< Self > Pointer; 00067 typedef SmartPointer< const Self > ConstPointer; 00068 00070 itkNewMacro(Self); 00071 00073 itkTypeMacro(HalfToFullHermitianImageFilter, 00074 ImageToImageFilter); 00075 00077 itkStaticConstMacro(ImageDimension, unsigned int, 00078 TInputImage::ImageDimension); 00079 00081 void SetActualXDimensionIsOdd(bool isOdd) 00082 { 00083 m_ActualXDimensionIsOdd = isOdd; 00084 } 00085 void SetActualXDimensionIsOddOn() 00086 { 00087 this->SetActualXDimensionIsOdd(true); 00088 } 00089 void SetActualXDimensionIsOddOff() 00090 { 00091 this->SetActualXDimensionIsOdd(false); 00092 } 00093 bool GetActualXDimensionIsOdd() 00094 { 00095 return m_ActualXDimensionIsOdd; 00096 } 00098 00099 protected: 00100 HalfToFullHermitianImageFilter() : m_ActualXDimensionIsOdd(false) {} 00101 ~HalfToFullHermitianImageFilter() {} 00102 00103 void ThreadedGenerateData(const OutputImageRegionType & outputRegionForThread, 00104 ThreadIdType threadId); 00105 00107 virtual void GenerateOutputInformation(); 00108 00110 virtual void GenerateInputRequestedRegion(); 00111 00112 private: 00113 HalfToFullHermitianImageFilter(const Self &); // purposely not implemented 00114 void operator=(const Self &); // purposely not implemented 00115 00116 bool m_ActualXDimensionIsOdd; 00117 }; 00118 } // end namespace itk 00119 00120 #ifndef ITK_MANUAL_INSTANTIATION 00121 #include "itkHalfToFullHermitianImageFilter.hxx" 00122 #endif 00123 00124 #endif // __itkHalfToFullHermitianImageFilter_h 00125