ICF 3.0.5.47
Technical documentation of ICF Libraries
iipr::CConvolutionKernel2d Class Reference

Implementation of a general 2D convolution kernel. More...

#include <CConvolutionKernel2d.h>

Inheritance diagram for iipr::CConvolutionKernel2d:
Collaboration diagram for iipr::CConvolutionKernel2d:

Public Types

typedef imath::CSampledFunction2d BaseClass
 
- Public Types inherited from imath::TISampledFunction< ArgumentDimensions, ResultDimensions >
typedef imath::TIMathFunction< istd::TIndex< ArgumentDimensions >, imath::TVector< ResultDimensions > > BaseClass
 
typedef BaseClass::ArgumentType ArgumentType
 
- Public Types inherited from imath::TIMathFunction< istd::TIndex< ArgumentDimensions >, TVector< ResultDimensions > >
typedef istd::TIndex< ArgumentDimensions > ArgumentType
 
typedef TVector< ResultDimensions > ResultType
 
- Public Types inherited from istd::IChangeable
enum  ChangeFlags {
  CF_ICF_INTERNAL = 0 , CF_ALL_DATA , CF_ANY , CF_DESTROYING ,
  CF_DELEGATED , CF_NO_UNDO
}
 Data model change notification flags. More...
 
enum  SupportedOperations {
  SO_NONE = 0 , SO_OBSERVE = 1 << 0 , SO_COPY = 1 << 1 , SO_CLONE = 1 << 2 ,
  SO_COMPARE = 1 << 3 , SO_RESET = 1 << 4 , SO_CHANGE_LOCK = 1 << 5
}
 Flags for supported operations. More...
 
enum  CompatibilityMode { CM_STRICT , CM_WITHOUT_REFS , CM_WITH_REFS , CM_CONVERT }
 Control how relationship betweeen objects are interpreted. More...
 
- Public Types inherited from iipr::IConvolutionKernel2d
enum  SeparationType { ST_AUTO , ST_HOR_VERT }
 

Public Member Functions

 CConvolutionKernel2d ()
 
 CConvolutionKernel2d (const CConvolutionKernel2d &kernel)
 
 CConvolutionKernel2d (const imath::ISampledFunction2d &function2d)
 
 CConvolutionKernel2d (const istd::CIndex2d &kernelSize, double value=0)
 
double GetKernelDistance (const IConvolutionKernel2d &kernel) const
 
virtual istd::CIndex2d GetKernelSize () const
 Get size of this kernel.
 
virtual void SetKernelSize (const istd::CIndex2d &kernelSize, double value=0.0)
 Set size of this kernel.
 
virtual double GetKernelElement (const istd::CIndex2d &index) const
 Get kernel element value at the given position index.
 
virtual bool SetKernelElement (const istd::CIndex2d &index, double value)
 Set kernel element value at the given position index.
 
virtual double GetOffsetValue () const
 Get offset value will be added to convolution result.
 
virtual bool SetOffsetValue (double offset)
 Set offset value will be added to convolution result.
 
virtual bool GetCombinedKernel (const IConvolutionKernel2d &kernel, IConvolutionKernel2d &result) const
 Get some kernel beeing combination of this and some other kernel.
 
virtual bool TrySeparateKernels (IConvolutionKernel2d &result1, IConvolutionKernel2d &result2, int separationType=ST_AUTO, double tolerance=I_BIG_EPSILON) const
 Try separate this kernel into two separated kernels.
 
virtual bool Serialize (iser::IArchive &archive)
 Load or store state of this object as a archive stream.
 
- Public Member Functions inherited from imath::CSampledFunction2d
 CSampledFunction2d ()
 
 CSampledFunction2d (const CSampledFunction2d &function2d)
 
 CSampledFunction2d (const imath::ISampledFunction2d &function2d)
 
 CSampledFunction2d (const istd::CIndex2d &size, double defaultValue=0)
 
void Reset ()
 
bool CreateGrid2d (const istd::CIndex2d &size, double defaultValue=0)
 
istd::CIndex2d GetGridSize2d () const
 
double GetSampleValue (const istd::CIndex2d &index) const
 
void SetSampleValue (const istd::CIndex2d &index, double value)
 
virtual bool CreateFunction (double *dataPtr, const ArgumentType &sizes)
 Create function from input data.
 
virtual int GetTotalSamplesCount () const
 Get number of samples stored in this container.
 
virtual int GetGridSize (int dimensionIndex) const
 Get number of samples for specified dimension.
 
virtual istd::CRange GetLogicalRange (int dimensionIndex) const
 Get logical grid position range for specified dimension.
 
virtual istd::CRange GetResultValueRange (int dimensionIndex, int resultDimension=-1) const
 Get range of result value for the given axis.
 
virtual bool GetValueAt (const ArgumentType &argument, ResultType &result) const
 
virtual ResultType GetValueAt (const ArgumentType &argument) const
 
- Public Member Functions inherited from imath::TISampledFunction< ArgumentDimensions, ResultDimensions >
virtual int GetArgumentDimensionality () const
 Get the number of argument components.
 
virtual int GetResultDimensionality () const
 Get the number of result components.
 
- Public Member Functions inherited from imath::TIMathFunction< istd::TIndex< ArgumentDimensions >, TVector< ResultDimensions > >
virtual bool GetValueAt (const istd::TIndex< ArgumentDimensions > &argument, TVector< ResultDimensions > &result) const=0
 Get function value for specified argument value.
 
virtual TVector< ResultDimensions > GetValueAt (const istd::TIndex< ArgumentDimensions > &argument) const=0
 Get function value for specified argument value.
 
- Public Member Functions inherited from istd::IChangeable
virtual int GetSupportedOperations () const
 Get set of flags for supported operations.
 
virtual bool CopyFrom (const IChangeable &object, CompatibilityMode mode=CM_WITHOUT_REFS)
 Copy this object from another one.
 
virtual bool IsEqual (const IChangeable &object) const
 Compare this object with another object.
 
virtual std::unique_ptr< IChangeableCloneMe (CompatibilityMode mode=CM_WITHOUT_REFS) const
 Make a copy of this object.
 
virtual bool ResetData (CompatibilityMode mode=CM_WITHOUT_REFS)
 Reset data to its default state.
 
virtual QMutex * GetChangesLock () const
 Get mutex beeing locked during changes, if available.
 
virtual void BeginChanges (const ChangeSet &changeSet)
 Starts the change transaction.
 
virtual void EndChanges (const ChangeSet &changeSet)
 Ends the change transaction.
 
virtual void BeginChangeGroup (const ChangeSet &changeSet)
 Starts group of changes.
 
virtual void EndChangeGroup (const ChangeSet &changeSet)
 Ends group of changes.
 
- Public Member Functions inherited from iipr::IConvolutionKernel2d
- Public Member Functions inherited from iser::ISerializable
virtual quint32 GetMinimalVersion (int versionId) const
 Get minimal needed version to correct storing of this data.
 

Additional Inherited Members

- Static Public Member Functions inherited from istd::IChangeable
static const ChangeSetGetNoChanges ()
 Get empty set of changes.
 
static const ChangeSetGetAnyChange ()
 Get anonymous change set.
 
static const ChangeSetGetAllChanges ()
 Get anonymous change set.
 
static const ChangeSetGetDelegatedChanges ()
 Get delegated change set.
 
- Protected Member Functions inherited from istd::IChangeable
virtual void OnBeginChanges ()
 Callback function for begin change event.
 
virtual void OnEndChanges (const ChangeSet &changeSet)
 Callback function for end change event.
 

Detailed Description

Implementation of a general 2D convolution kernel.

Internally the kernel is represented by an array of filter weights and offset positions for fast access to the corresponding bitmap values.

Definition at line 24 of file CConvolutionKernel2d.h.

Member Typedef Documentation

◆ BaseClass

Constructor & Destructor Documentation

◆ CConvolutionKernel2d() [1/4]

iipr::CConvolutionKernel2d::CConvolutionKernel2d ( )

◆ CConvolutionKernel2d() [2/4]

iipr::CConvolutionKernel2d::CConvolutionKernel2d ( const CConvolutionKernel2d & kernel)

◆ CConvolutionKernel2d() [3/4]

iipr::CConvolutionKernel2d::CConvolutionKernel2d ( const imath::ISampledFunction2d & function2d)
explicit

◆ CConvolutionKernel2d() [4/4]

iipr::CConvolutionKernel2d::CConvolutionKernel2d ( const istd::CIndex2d & kernelSize,
double value = 0 )
explicit

Member Function Documentation

◆ GetCombinedKernel()

virtual bool iipr::CConvolutionKernel2d::GetCombinedKernel ( const IConvolutionKernel2d & kernel,
IConvolutionKernel2d & result ) const
virtual

Get some kernel beeing combination of this and some other kernel.

Implements iipr::IConvolutionKernel2d.

◆ GetKernelDistance()

double iipr::CConvolutionKernel2d::GetKernelDistance ( const IConvolutionKernel2d & kernel) const

◆ GetKernelElement()

virtual double iipr::CConvolutionKernel2d::GetKernelElement ( const istd::CIndex2d & index) const
virtual

Get kernel element value at the given position index.

Implements iipr::IConvolutionKernel2d.

◆ GetKernelSize()

virtual istd::CIndex2d iipr::CConvolutionKernel2d::GetKernelSize ( ) const
virtual

Get size of this kernel.

Implements iipr::IConvolutionKernel2d.

◆ GetOffsetValue()

virtual double iipr::CConvolutionKernel2d::GetOffsetValue ( ) const
virtual

Get offset value will be added to convolution result.

Implements iipr::IConvolutionKernel2d.

◆ Serialize()

virtual bool iipr::CConvolutionKernel2d::Serialize ( iser::IArchive & archive)
virtual

Load or store state of this object as a archive stream.

Type of operation is depending on archive type.

See also
iser::IArchive

Implements iser::ISerializable.

◆ SetKernelElement()

virtual bool iipr::CConvolutionKernel2d::SetKernelElement ( const istd::CIndex2d & index,
double value )
virtual

Set kernel element value at the given position index.

The method returns true, if the value could be set and false otherwise.

Implements iipr::IConvolutionKernel2d.

◆ SetKernelSize()

virtual void iipr::CConvolutionKernel2d::SetKernelSize ( const istd::CIndex2d & kernelSize,
double value = 0.0 )
virtual

Set size of this kernel.

It initialize all values to defined value.

Implements iipr::IConvolutionKernel2d.

◆ SetOffsetValue()

virtual bool iipr::CConvolutionKernel2d::SetOffsetValue ( double offset)
virtual

Set offset value will be added to convolution result.

Implements iipr::IConvolutionKernel2d.

◆ TrySeparateKernels()

virtual bool iipr::CConvolutionKernel2d::TrySeparateKernels ( IConvolutionKernel2d & result1,
IConvolutionKernel2d & result2,
int separationType = ST_AUTO,
double tolerance = I_BIG_EPSILON ) const
virtual

Try separate this kernel into two separated kernels.

Implements iipr::IConvolutionKernel2d.


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

© Witold Gantzke and Kirill Lepskiy