/*========================================================================= Program: Insight Segmentation & Registration Toolkit Module: $RCSfile: itkReconstructionLabelCollectionImageFilter.h,v $ Language: C++ Date: $Date: 2006/03/28 19:59:05 $ Version: $Revision: 1.6 $ Copyright (c) Insight Software Consortium. All rights reserved. See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details. This software is distributed WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the above copyright notices for more information. =========================================================================*/ #ifndef __itkReconstructionLabelCollectionImageFilter_h #define __itkReconstructionLabelCollectionImageFilter_h #include "itkInPlaceLabelCollectionImageFilter.h" namespace itk { /** \class ReconstructionLabelCollectionImageFilter * \brief * * \ingroup ImageEnhancement MathematicalMorphologyImageFilters */ template class ITK_EXPORT ReconstructionLabelCollectionImageFilter : public InPlaceLabelCollectionImageFilter { public: /** Standard class typedefs. */ typedef ReconstructionLabelCollectionImageFilter Self; typedef InPlaceLabelCollectionImageFilter Superclass; typedef SmartPointer Pointer; typedef SmartPointer ConstPointer; /** Some convenient typedefs. */ typedef TImage ImageType; typedef typename ImageType::Pointer ImagePointer; typedef typename ImageType::ConstPointer ImageConstPointer; typedef typename ImageType::PixelType PixelType; typedef typename ImageType::IndexType IndexType; typedef typename ImageType::LabelObjectType LabelObjectType; typedef TMarkerImage MarkerImageType; typedef typename MarkerImageType::Pointer MarkerImagePointer; typedef typename MarkerImageType::ConstPointer MarkerImageConstPointer; typedef typename MarkerImageType::PixelType MarkerImagePixelType; /** ImageDimension constants */ itkStaticConstMacro(ImageDimension, unsigned int, TImage::ImageDimension); /** Standard New method. */ itkNewMacro(Self); /** Runtime information support. */ itkTypeMacro(ReconstructionLabelCollectionImageFilter, InPlaceLabelCollectionImageFilter); #ifdef ITK_USE_CONCEPT_CHECKING /** Begin concept checking */ /* itkConceptMacro(InputEqualityComparableCheck, (Concept::EqualityComparable)); itkConceptMacro(IntConvertibleToInputCheck, (Concept::Convertible)); itkConceptMacro(InputOStreamWritableCheck, (Concept::OStreamWritable));*/ /** End concept checking */ #endif /** Set the marker image */ void SetMarkerImage(TMarkerImage *input) { // Process object is not const-correct so the const casting is required. this->SetNthInput( 1, const_cast(input) ); } /** Get the marker image */ MarkerImageType * GetMarkerImage() { return static_cast(const_cast(this->ProcessObject::GetInput(1))); } /** Set the input image */ void SetInput1(TImage *input) { this->SetInput( input ); } /** Set the marker image */ void SetInput2(TMarkerImage *input) { this->SetMarkerImage( input ); } /** * Set/Get the value used as "foreground" in the output image. * Defaults to NumericTraits::max(). */ itkSetMacro(ForegroundValue, PixelType); itkGetConstMacro(ForegroundValue, PixelType); protected: ReconstructionLabelCollectionImageFilter(); ~ReconstructionLabelCollectionImageFilter() {}; virtual void ThreadedGenerateData( LabelObjectType * labelObject ); void PrintSelf(std::ostream& os, Indent indent) const; private: ReconstructionLabelCollectionImageFilter(const Self&); //purposely not implemented void operator=(const Self&); //purposely not implemented MarkerImagePixelType m_ForegroundValue; } ; // end of class } // end namespace itk #ifndef ITK_MANUAL_INSTANTIATION #include "itkReconstructionLabelCollectionImageFilter.txx" #endif #endif