Copyright © 2006-2019 MultiMedia Soft

SwitchOutputFileEx method

Previous pageReturn to chapter overviewNext page

Remarks

 

During a recording session, whose output is being sent to an output file, switches to a different output file without stopping the recording session itself: in this way no sound data will be lost.

 

This method will return an error for memory-based recording sessions or for recording sessions whose recording mode, set through the SetRecordingMode method, is different from REC_MODE_NEW.

 

This method can only work when the recording session is started through one of the following methods: StartFromDirectSoundDevice, StartFromAsioDevice, StartFromWasapiCaptureDevice, StartFromWasapiLoopbackDevice and StartFromDjStudioMixer.

 

Each time an output file is switched, the RecordingOutputFileSwitch event is fired.

 

For further details about output files switching see the How to perform a recording session tutorial.

 

 

Syntax

 

[Visual Basic]

control.SwitchOutputFileEx (

strOutputPath as string,

bResetEncoderCmdLine as enumBoolean

) as enumErrorCodes


 

[C++]

short control.SwitchOutputFileEx (

LPCTSTR strOutputPath,

short bResetEncoderCmdLine

);


 

 

Parameter

Description

 

 

strOutputPath

String representing the absolute pathname of the output file that will contain the recorded data. If this pathname should contain invalid characters, they would be automatically changed into an underscore '_' character..

bResetEncoderCmdLine

Boolean value that, when recording through an external encoder (MP3, Ogg Vorbis and AAC/MP4) determines if the command line of the external encoder needs to be reset allowing to apply different encoding settings updated through the EncodeFormats object or different tags updated through the TagInfoAddToRecSession method..

 

.Supported values are the following:

Mnemonic constant

Value

Meaning

BOOL_FALSE

0

Doesn't reset the command line and continue using the original one

BOOL_TRUE

1

Resets the command line

 

 

 

Return value

 

Value

Meaning

 

 

Negative value

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

enumErrorCodes.ERR_NOERROR (0)

The method call was successful.