ITK  4.1.0
Insight Segmentation and Registration Toolkit
itkUnconstrainedRegionBasedLevelSetFunctionSharedData.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 __itkUnconstrainedRegionBasedLevelSetFunctionSharedData_h
00019 #define __itkUnconstrainedRegionBasedLevelSetFunctionSharedData_h
00020 
00021 #include "itkRegionBasedLevelSetFunctionSharedData.h"
00022 
00023 namespace itk
00024 {
00060 template< class TInputImage, class TFeatureImage, class TSingleData >
00061 class UnconstrainedRegionBasedLevelSetFunctionSharedData:
00062   public RegionBasedLevelSetFunctionSharedData< TInputImage, TFeatureImage, TSingleData >
00063 {
00064 public:
00065 
00066   typedef UnconstrainedRegionBasedLevelSetFunctionSharedData Self;
00067   typedef RegionBasedLevelSetFunctionSharedData< TInputImage, TFeatureImage, TSingleData >
00068   Superclass;
00069   typedef SmartPointer< Self >       Pointer;
00070   typedef SmartPointer< const Self > ConstPointer;
00071 
00072   itkStaticConstMacro(ImageDimension, unsigned int, TFeatureImage::ImageDimension);
00073 
00075   itkNewMacro(Self);
00076 
00077   itkTypeMacro(UnconstrainedRegionBasedLevelSetFunctionSharedData, RegionBasedLevelSetFunctionSharedData);
00078 
00079   typedef TInputImage                                 InputImageType;
00080   typedef typename Superclass::InputImagePointer      InputImagePointer;
00081   typedef typename Superclass::InputImageConstPointer InputImageConstPointer;
00082   typedef typename Superclass::InputPixelType         InputPixelType;
00083   typedef typename Superclass::InputRegionType        InputRegionType;
00084   typedef typename Superclass::InputSizeType          InputSizeType;
00085   typedef typename Superclass::InputSizeValueType     InputSizeValueType;
00086   typedef typename Superclass::InputSpacingType       InputSpacingType;
00087   typedef typename Superclass::InputIndexType         InputIndexType;
00088   typedef typename Superclass::InputIndexValueType    InputIndexValueType;
00089   typedef typename Superclass::InputPointType         InputPointType;
00090 
00091   typedef TFeatureImage                                 FeatureImageType;
00092   typedef typename Superclass::FeatureImagePointer      FeatureImagePointer;
00093   typedef typename Superclass::FeatureImageConstPointer FeatureImageConstPointer;
00094   typedef typename Superclass::FeaturePixelType         FeaturePixelType;
00095   typedef typename Superclass::FeatureRegionType        FeatureRegionType;
00096   typedef typename Superclass::FeatureSizeType          FeatureSizeType;
00097   typedef typename Superclass::FeatureSizeValueType     FeatureSizeValueType;
00098   typedef typename Superclass::FeatureSpacingType       FeatureSpacingType;
00099   typedef typename Superclass::FeatureIndexType         FeatureIndexType;
00100   typedef typename Superclass::FeaturePointType         FeaturePointType;
00101 
00102   typedef typename Superclass::ListPixelType         ListPixelType;
00103   typedef typename Superclass::ListImageType         ListImageType;
00104   typedef typename Superclass::ListImagePointer      ListImagePointer;
00105   typedef typename Superclass::ListImageConstPointer ListImageConstPointer;
00106   typedef typename Superclass::ListRegionType        ListRegionType;
00107   typedef typename Superclass::ListSizeType          ListSizeType;
00108   typedef typename Superclass::ListSizeValueType     ListSizeValueType;
00109   typedef typename Superclass::ListSpacingType       ListSpacingType;
00110   typedef typename Superclass::ListIndexType         ListIndexType;
00111   typedef typename Superclass::ListIndexValueType    ListIndexValueType;
00112   typedef typename Superclass::ListPointType         ListPointType;
00113   typedef typename Superclass::ListIteratorType      ListIteratorType;
00114 
00115   typedef typename Superclass::CentroidVectorType CentroidVectorType;
00116   typedef typename Superclass::SampleType         SampleType;
00117   typedef typename Superclass::TreeGeneratorType  TreeGeneratorType;
00118   typedef typename Superclass::TreePointer        TreePointer;
00119   typedef typename Superclass::TreeType           TreeType;
00120   typedef typename Superclass::KdTreePointer      KdTreePointer;
00121 
00122   typedef TSingleData                                            LevelSetDataType;
00123   typedef typename Superclass::LevelSetDataPointer               LevelSetDataPointer;
00124   typedef typename Superclass::LevelSetDataPointerVector         LevelSetDataPointerVector;
00125   typedef typename Superclass::LevelSetDataPointerVectorIterator LevelSetDataPointerVectorIterator;
00126 
00127   void PopulateListImage()
00128   {
00129     ListPixelType L;
00130 
00131     for ( unsigned int i = 0; i < this->m_FunctionCount; i++ )
00132       {
00133       L.push_back(i);
00134       }
00135     this->m_NearestNeighborListImage->FillBuffer(L);
00136   }
00137 
00138 protected:
00139   UnconstrainedRegionBasedLevelSetFunctionSharedData():Superclass(){}
00140   ~UnconstrainedRegionBasedLevelSetFunctionSharedData(){}
00141 private:
00142   UnconstrainedRegionBasedLevelSetFunctionSharedData(const Self &); //purposely
00143                                                                     // not
00144                                                                     // implemented
00145   void operator=(const Self &);                                     //purposely
00146                                                                     // not
00147                                                                     // implemented
00148 };
00149 } //end namespace itk
00150 
00151 #endif
00152