ImageGaussianNoiseModel Class Reference

#include <GaussianNoiseModel.hh>

Inherits GaussianNoiseModel.

Public Types

enum  NoiseType { NONE, CUSTOM, GAUSSIAN }
 Which noise types we support. More...
 

Public Member Functions

 ImageGaussianNoiseModel ()
 Constructor. More...
 
virtual ~ImageGaussianNoiseModel ()
 Destructor. More...
 
double Apply (double _in, double _dt=0.0)
 Apply noise to input data value. More...
 
double ApplyImpl (double _in, double _dt)
 Apply noise to input data value. More...
 
virtual void Fini ()
 Finalize the noise model. More...
 
double GetBias () const
 Accessor for bias. More...
 
double GetDynamicBiasCorrelationTime () const
 Accessor for dynamic bias process correlation time (seconds). More...
 
double GetDynamicBiasStdDev () const
 Accessor for dynamic bias process standard deviation. More...
 
double GetMean () const
 Accessor for mean. More...
 
NoiseType GetNoiseType () const
 Accessor for NoiseType. More...
 
double GetStdDev () const
 Accessor for stddev. More...
 
virtual void Load (sdf::ElementPtr _sdf)
 Load noise parameters from sdf. More...
 
virtual void Print (std::ostream &_out) const
 Documentation inherited. More...
 
virtual void SetCamera (rendering::CameraPtr _camera)
 Set camera needed to create image noise. More...
 
virtual void SetCustomNoiseCallback (boost::function< double(double)> _cb)
 Register a custom noise callback. More...
 
virtual void SetCustomNoiseCallbackTime (boost::function< double(double, double)> _cb)
 Register a custom noise callback, with time. More...
 
void SetDynamicBiasCorrelationTime (const double _stddev)
 Set correlation time of dynamic bias process, in seconds. More...
 
void SetDynamicBiasStdDev (const double _stddev)
 Set standard deviation of dynamic bias process. More...
 
void SetMean (const double _mean)
 Set mean. More...
 
void SetStdDev (const double _stddev)
 Set stddev. More...
 

Public Attributes

boost::shared_ptr< GaussianNoiseCompositorListener > gaussianNoiseCompositorListener
 Gaussian noise compositor listener. More...
 
Ogre::CompositorInstance * gaussianNoiseInstance
 Gaussian noise compositor. More...
 

Protected Attributes

double bias
 If type starts with GAUSSIAN, the bias we'll add. More...
 
double mean
 If type starts with GAUSSIAN, the mean of the distribution from which we sample when adding noise. More...
 
double precision
 If type==GAUSSIAN_QUANTIZED, the precision to which the output signal is rounded. More...
 
bool quantized
 True if the type is GAUSSIAN_QUANTIZED. More...
 
double stdDev
 If type starts with GAUSSIAN, the standard deviation of the distribution from which we sample when adding noise. More...
 

Member Enumeration Documentation

◆ NoiseType

enum NoiseType
inherited

Which noise types we support.

Enumerator
NONE 
CUSTOM 
GAUSSIAN 

Constructor & Destructor Documentation

◆ ImageGaussianNoiseModel()

Constructor.

◆ ~ImageGaussianNoiseModel()

virtual ~ImageGaussianNoiseModel ( )
virtual

Destructor.

Member Function Documentation

◆ Apply()

double Apply ( double  _in,
double  _dt = 0.0 
)
inherited

Apply noise to input data value.

Parameters
[in]_inInput data value.
Returns
Data with noise applied.

◆ ApplyImpl()

double ApplyImpl ( double  _in,
double  _dt 
)
virtualinherited

Apply noise to input data value.

This gets overriden by derived classes, and called by Apply.

Parameters
[in]_inInput data value.
Returns
Data with noise applied.

Reimplemented from Noise.

◆ Fini()

virtual void Fini ( )
virtual

Finalize the noise model.

Reimplemented from GaussianNoiseModel.

◆ GetBias()

double GetBias ( ) const
inherited

Accessor for bias.

Returns
Bias on output.

◆ GetDynamicBiasCorrelationTime()

double GetDynamicBiasCorrelationTime ( ) const
inherited

Accessor for dynamic bias process correlation time (seconds).

Returns
Correlation time of Gaussian noise process driving bias walk

◆ GetDynamicBiasStdDev()

double GetDynamicBiasStdDev ( ) const
inherited

Accessor for dynamic bias process standard deviation.

Returns
Standard deviation of Gaussian noise driving bias walk

◆ GetMean()

double GetMean ( ) const
inherited

Accessor for mean.

Returns
Mean of Gaussian noise.

◆ GetNoiseType()

NoiseType GetNoiseType ( ) const
inherited

Accessor for NoiseType.

Returns
Type of noise currently in use.

◆ GetStdDev()

double GetStdDev ( ) const
inherited

Accessor for stddev.

Returns
Standard deviation of Gaussian noise.

◆ Load()

virtual void Load ( sdf::ElementPtr  _sdf)
virtual

Load noise parameters from sdf.

Parameters
[in]_sdfSDF parameters.
[in]_sensorType of sensor.

Reimplemented from GaussianNoiseModel.

◆ Print()

virtual void Print ( std::ostream &  _out) const
virtual

Documentation inherited.

Reimplemented from GaussianNoiseModel.

◆ SetCamera()

virtual void SetCamera ( rendering::CameraPtr  _camera)
virtual

Set camera needed to create image noise.

This is only needed for image sensors, i.e. camera/multicamera/depth sensors, which use shaders for more efficient noise generation.

Parameters
[in]_cameraCamera associated to an image sensor

Reimplemented from Noise.

◆ SetCustomNoiseCallback()

virtual void SetCustomNoiseCallback ( boost::function< double(double)>  _cb)
virtualinherited

Register a custom noise callback.

If both a function that takes time and one that doesn't are set, the one without time will be ignored.

Parameters
[in]_cbCallback function for applying a custom noise model. This is useful if users want to use their own noise model from a sensor plugin.

◆ SetCustomNoiseCallbackTime()

virtual void SetCustomNoiseCallbackTime ( boost::function< double(double, double)>  _cb)
virtualinherited

Register a custom noise callback, with time.

If both a function that takes time and one that doesn't are set, the one without time will be ignored.

Parameters
[in]_cbCallback function for applying a custom noise model. This is useful if users want to use their own noise model from a sensor plugin.

◆ SetDynamicBiasCorrelationTime()

void SetDynamicBiasCorrelationTime ( const double  _stddev)
inherited

Set correlation time of dynamic bias process, in seconds.

Parameters
[in]_stddevStandard deviation of bias noise process.

◆ SetDynamicBiasStdDev()

void SetDynamicBiasStdDev ( const double  _stddev)
inherited

Set standard deviation of dynamic bias process.

Parameters
[in]_stddevStandard deviation of bias noise process.

◆ SetMean()

void SetMean ( const double  _mean)
inherited

Set mean.

Parameters
[in]_meanMean of Gaussian noise.

◆ SetStdDev()

void SetStdDev ( const double  _stddev)
inherited

Set stddev.

Parameters
[in]_stddevStandard deviation of Gaussian noise.

Member Data Documentation

◆ bias

double bias
protectedinherited

If type starts with GAUSSIAN, the bias we'll add.

◆ gaussianNoiseCompositorListener

boost::shared_ptr<GaussianNoiseCompositorListener> gaussianNoiseCompositorListener

Gaussian noise compositor listener.

◆ gaussianNoiseInstance

Ogre::CompositorInstance* gaussianNoiseInstance

Gaussian noise compositor.

◆ mean

double mean
protectedinherited

If type starts with GAUSSIAN, the mean of the distribution from which we sample when adding noise.

◆ precision

double precision
protectedinherited

If type==GAUSSIAN_QUANTIZED, the precision to which the output signal is rounded.

◆ quantized

bool quantized
protectedinherited

True if the type is GAUSSIAN_QUANTIZED.

◆ stdDev

double stdDev
protectedinherited

If type starts with GAUSSIAN, the standard deviation of the distribution from which we sample when adding noise.


The documentation for this class was generated from the following file: