VideoEdit Gold ActiveX Control

Save2Wave Method

Description

Export wave file from media file and save to specific number of channel, sample rate, bit per sample.

 

Syntax

Public Function Save2Wave ( _
   ByVal strOutputFile as string, _
   ByVal iChannels as integer , _
   ByVal iSamplesPerSec as long, _
   ByVal iBitsPerSample as integer
) As Boolean

 

Parameters

strOutputFile
    the output wave file name

iChannels
    number of channels in the waveform-audio data. 1 -mono ,2-stereo

iSamplesPerSec
    sample rate, in samples per second (hertz), e.g. 11025 -11.025 kHz

iBitsPerSample
    bits per sample , 1 - 8 bit , 2- 16 bit
 

Return Value

Return true - successful
Return false - Failed
 

Example

[Visual Basic Syntax]
VideoEdit1.InitControl
result = VideoEdit1.AddAudio(txtAudio1, txtAudioStart1, txtAudioStop1)
result =VideoEdit1.Save2Wave(CommonDialog2.FileName, 2, 11025, 1)              ' stereo ,11025 khz, 8 bit sample