Copyright © 2008-2019 MultiMedia Soft

SoundComposer.ItemSoundFileDurationStretch method

Previous pageReturn to chapter overviewNext page

Remarks

 

Stretches the duration of the sound file by modifying its tempo and without changing the original pitch. After the time stretch, the updated duration can be obtained through the SoundComposer.ItemSoundFileDurationGet method.

 

The tempo change algorithm is always applied to the full sound file: a call to this method will return an error if the loading range should have been modified through the SoundComposer.ItemSoundFileLoadRangeSet method.

 

This setting is ignored when more than one loop is requested through the SoundComposer.ItemSoundFileLoopSet method.

 

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

 

 

Syntax

 

[Visual Basic]

control.SoundComposer.ItemSoundFileDurationStretch (

nUniqueId as Long,

nDurationMs as Long

) as enumErrorCodes


 

[C++]

short control.SoundComposer.ItemSoundFileDurationStretch (

long nUniqueId,

long nDurationMs

);


 

Parameter

Description

 

 

nUniqueId

The unique identifier of the sound file item previously returned by the call to one of the following methods: SoundComposer.ItemSoundFileAdd, SoundComposer.ItemSoundFileMemoryAdd, SoundComposer.ItemSoundFileRawAdd, SoundComposer.ItemSoundFileMemoryRawAdd, SoundComposer.ItemSoundFileFromEditorAdd,or SoundComposer.ItemSoundFileFromRecorderAdd.

nDurationMs

The modified duration expressed in milliseconds

 

 

Return value

 

Value

Meaning

 

 

Negative value

An error occurred, check the LastError property value in order to get the error code

enumErrorCodes.ERR_NOERROR (0)

The method call was successful