Go to the documentation of this file.
18 #ifndef sitkSaltAndPepperNoiseImageFilter_h
19 #define sitkSaltAndPepperNoiseImageFilter_h
75 SITK_RETURN_SELF_TYPE_HEADER
SetProbability (
double Probability ) { this->m_Probability = Probability;
return *
this; }
84 SITK_RETURN_SELF_TYPE_HEADER
SetSeed ( uint32_t Seed ) { this->m_Seed = Seed;
return *
this; }
88 uint32_t
GetSeed()
const {
return this->m_Seed; }
91 std::string
GetName()
const {
return std::string (
"SaltAndPepperNoiseImageFilter"); }
94 std::string ToString()
const;
108 template <
class TImageType>
Image ExecuteInternal (
const Image& image1 );
110 template <
class TImageType>
Image ExecuteInternalVectorImage (
const Image& image );
117 double m_Probability{0.01};
122 bool m_InPlace{
false};
The Image class for SimpleITK.
Image SaltAndPepperNoise(Image &&image1, double probability=0.01, uint32_t seed=(uint32_t) itk::simple::sitkWallClock)
Alter an image with fixed value impulse noise, often called salt and pepper noise.
typelist2::typelist< BasicPixelID< int8_t >, BasicPixelID< uint8_t >, BasicPixelID< int16_t >, BasicPixelID< uint16_t >, BasicPixelID< int32_t >, BasicPixelID< uint32_t >, BasicPixelID< float >, BasicPixelID< double > > BasicPixelIDTypeList
Image(Self::*)(const Image &image1) MemberFunctionType
BasicPixelIDTypeList PixelIDTypeList
std::string GetName() const
Alter an image with fixed value impulse noise, often called salt and pepper noise.
Self & SetSeed(uint32_t Seed)
#define SITKBasicFilters_EXPORT
Self & SetProbability(double Probability)
The base interface for SimpleITK filters that take one input image.
double GetProbability() const
std::unique_ptr< detail::MemberFunctionFactory< MemberFunctionType > > m_MemberFactory