Copyright © 2001-2019 MultiMedia Soft

SoundComposer.ItemAmplitudeSet method

Previous pageReturn to chapter overviewNext page

Remarks

 

Modifies the volume amplitude of the given item. The current amplitude can be obtained through the SoundComposer.ItemAmplitudeGet method.

 

For further details about sound composing see the the SoundComposer object and the How to compose a sound tutorial.

 

 

Syntax

 

[Visual Basic]

control.SoundGenerator.ItemAmplitudeSet (

nPlayer as Integer,

nUniqueId as Long,

fAmplitude as Single

) as enumErrorCodes


 

[C++]

short control.SoundGenerator.ItemAmplitudeSet (

short nPlayer,

long nUniqueId,

float fAmplitude

);


 

Parameter

Description

 

 

nPlayer

Number representing the zero-based index of the player that owns the sound composer session

nUniqueId

The unique identifier of the element previously returned by the call to one of the following methods:

- SoundComposer.ItemSoundFileAdd, SoundComposer.ItemSoundFileMemoryAdd, SoundComposer.ItemSoundFileRawAdd, SoundComposer.ItemSoundFileMemoryRawAdd for sound file items.

- SoundComposer.ItemSpeechFromStringAdd and SoundComposer.ItemSpeechFromFileAdd for text to speech items.

fAmplitude

The item's volume amplitude.

- value 0.0 means that sound volume is muted

- values higher than 0.0 and smaller than 1.0 attenuate the sound volume

- value 1.0 sets the sound at full volume

- values higher than 1.0 amplify the sound volume

 

 

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.