Copyright © 2001-2019 MultiMedia Soft

PeakDetectionOnPlayer method

Previous pageReturn to chapter overviewNext page

Remarks

 

Gets the highest peak of the sound currently loaded inside the given player.

The returned value can be used with the Effects.NormalizationPeakSet method to speed up a later loading of a sound file when normalization has been enabled through the Effects.NormalizationEnable method.

 

Differently from the PeakDetectionOnPlayerRequest method, the value of the highest peak is immediately available when this method returns to the caller.

 

See the How to apply special effects to a playing sound section for further details.

 

 

Syntax

 

[Visual Basic]

control.PeakDetectionOnPlayer (

nPlayer as Integer,

fPeak as Single

) as enumErrorCodes


 

[C++]

short control.PeakDetectionOnPlayer (

short nPlayer,

float *fPeak

);


 

 

Parameter

Description

 

 

nPlayer

Number representing the zero-based index of the involved player

fPeak

Reference that, on return from the method call, will contain a floating point value representing the highest peak value.

The value can be in the range from 0.0 to 1.0

 

 

Return value

 

Value

Meaning

 

 

Negative value

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

enumErrorCodes.NOERROR (0)

The method call was successful