Copyright © 2011-2019 MultiMedia Soft

Effects.DeClickFilterApply method

Previous pageReturn to chapter overviewNext page

Remarks

 

Applies the DeClick filter to the given portion of sound under editing.

 

During the execution of the editing session the CallbackEditPerc delegate is invoked in order to notify about the percentage of advancement.

 

For further details about callback delegates see the How to synchronize the container application with the API tutorial.

For further details about noise removal refer to the How to perform noise removal tutorial.

For further details about methods related to the use of special effects refer to the EffectsMan class.

 

 

Syntax

 

[Visual Basic]

Public Function DeClickFilterApply (

nStartPosition as Int32,

nEndPosition as Int32,

nSensitivity as Int32,

nGroupSensitivity as Int32,

bSavePitch as Boolean

) as enumErrorCodes


 

[C#]

public enumErrorCodes DeClickFilterApply (

Int32 nStartPosition,

Int32 nEndPosition,

Int32 nSensitivity,

Int32 nGroupSensitivity,

bool bSavePitch

);


 

[C++]

public: enumErrorCodes DeClickFilterApply (

Int32 nStartPosition,

Int32 nEndPosition,

Int32 nSensitivity,

Int32 nGroupSensitivity,

bool bSavePitch

);


 

 

Parameter

Description

 

 

nStartPosition

Start position, expressed in milliseconds, of the sound range where the filter will be applied

nEndPosition

End position, expressed in milliseconds, of the sound range where the filter will be applied

nSensitivity

This parameter, which can range from 0 to 100, determines many filter’s inner values like window size, threshold etc. Here threshold (value of threshold decreases as sensitivity increases) is internally used parameter; it means the absolute audio level above which signal is suspected as a click or pop. If sensitivity is set to zero then filter is disabled, thus output will not be affected by this filter. Higher values of sensitivity obviously make filter more sensitive giving better results. Also higher sensitivity values make filter more complex thus runs relatively slower. Table 1 lists internal parameters affected by sensitivity and resulting filter performance.

 

The table below summarizes effects on internal parameters when sensitivity value is increased:

Affected Internal Parameter

Effect

Result

Window Size

Increases

Filter searches more audio samples to detect clicks/pops. Detect decision is more accurate.

Threshold

Decreases

Due to decreased threshold small spikes can be detected easily

Search Factor

Decreases

Filter decided a portion of audio as click/pop from small number of spikes.

nGroupSensitivity

This is second parameter, which can range from 0 to 100, affecting the detection of clicks/pops. You can consider detection process a

two stage search. In the first stage filter search for individual clicks and/or too close clicks. In the second stage it groups the clicks which are not too far and may be removed in single step. This results a relatively larger audio portion to be restored (interpolated). Benefit of this grouping is lesser number of interpolators are required to restore/interpolate audio thus giving better output. Different audio types will require different settings for this parameter.

 

A value of 0 for this parameter will disable grouping process. If input audio contains many clicks near each other and you have disabled grouping, it is possible that interpolation process will use previously self interpolated signal. This may cause discontinuities in output.

Value of 100 will try to group as much clicks as possible. For input audio containing relatively far clicks and few clicks, a value of 100 may result in grouping of too far clicks, thus causing valuable portion of input audio to be replaced by interpolated one.

 

Work of this parameter largely depends on the nature of input audio and clicks/pops in it.

bSavePitch

Boolean value that specifies if filter will try to recover damaged pitch in the process of interpolation. Please note that it is not necessary that pitch is always damaged in interpolation.

 

Supported values are the following:

Mnemonic constant

Meaning

false

The filter will not try to recover damaged pitch

true

The filter will try to recover damaged pitch in the process of interpolation

 

 

Return value

 

Value

Meaning

 

 

Negative value

An error occurred (see the LastError property for further error details)

enumErrorCodes.ERR_NOERROR (0)

The method call was successful.