18 #ifndef __itkAreaOpeningImageFilter_h
19 #define __itkAreaOpeningImageFilter_h
60 template<
class TInputImage,
class TOutputImage,
class TAttribute =
typename TInputImage::SpacingType::ValueType >
63 std::greater< typename TInputImage::PixelType > >
69 std::greater< typename TInputImage::PixelType > >
85 typedef typename TInputImage::SizeType
SizeType;
88 itkStaticConstMacro(ImageDimension,
unsigned int,
89 TOutputImage::ImageDimension);
101 itkSetMacro(UseImageSpacing,
bool);
102 itkGetConstReferenceMacro(UseImageSpacing,
bool);
103 itkBooleanMacro(UseImageSpacing);
109 m_UseImageSpacing =
true;
116 this->m_AttributeValuePerPixel = 1;
117 if ( m_UseImageSpacing )
121 for (
unsigned i = 0; i < ImageDimension; i++ )
123 psize *= this->GetInput()->GetSpacing()[i];
125 this->m_AttributeValuePerPixel =
static_cast< AttributeType >( psize );
130 Superclass::GenerateData();
133 void PrintSelf(std::ostream & os,
Indent indent)
const
135 Superclass::PrintSelf(os, indent);
136 os << indent <<
"UseImageSpacing: " << m_UseImageSpacing << std::endl;
142 void operator=(
const Self &);