diaGlobWrapper Help
Assembly: DiaGlobWrapper (in DiaGlobWrapper.dll) Version: 0.0.0.0
Records voice on a channel.
Namespace:
InkostarAssembly: DiaGlobWrapper (in DiaGlobWrapper.dll) Version: 0.0.0.0
Syntax
| C# |
|---|
public void Record( Channel CurrentChannel, string RecordingFile, int RecordingDurationSecs, DiaGlobWrapperCommon..::.VoiceFormat RecordingVoiceFormat, DiaGlobWrapperCommon..::.FileFormat RecordingFileFormat, DiaGlobWrapperCommon..::.SamplingRate RecordingSamplingRate, DiaGlobWrapperCommon..::.BitsPerSample RecordingBitsPerSample, bool InterruptRecordingOnDigit ) |
| Visual Basic (Declaration) |
|---|
Public Sub Record ( _ CurrentChannel As Channel, _ RecordingFile As String, _ RecordingDurationSecs As Integer, _ RecordingVoiceFormat As DiaGlobWrapperCommon..::.VoiceFormat, _ RecordingFileFormat As DiaGlobWrapperCommon..::.FileFormat, _ RecordingSamplingRate As DiaGlobWrapperCommon..::.SamplingRate, _ RecordingBitsPerSample As DiaGlobWrapperCommon..::.BitsPerSample, _ InterruptRecordingOnDigit As Boolean _ ) |
| Visual C++ |
|---|
public: void Record( Channel^ CurrentChannel, String^ RecordingFile, int RecordingDurationSecs, DiaGlobWrapperCommon..::.VoiceFormat RecordingVoiceFormat, DiaGlobWrapperCommon..::.FileFormat RecordingFileFormat, DiaGlobWrapperCommon..::.SamplingRate RecordingSamplingRate, DiaGlobWrapperCommon..::.BitsPerSample RecordingBitsPerSample, bool InterruptRecordingOnDigit ) |
Parameters
- CurrentChannel
- Type: Inkostar..::.Channel
The Channel on the Dialogic board on which the function is to be executed.
- RecordingFile
- Type: System..::.String
The fully qualified path of the recording file.
- RecordingDurationSecs
- Type: System..::.Int32
The recording duration in seconds. Recording will be stopped when the time limit has been reached.
- RecordingVoiceFormat
- Type: Inkostar..::.DiaGlobWrapperCommon..::.VoiceFormat
An enumerated constant to indicate if the file format of the recorded voice is WAV or VOX.
- RecordingFileFormat
- Type: Inkostar..::.DiaGlobWrapperCommon..::.FileFormat
An enumerated constant to indicate the underlying encoding format, for example DIALOGIC_ADPCM (Dialogic native format) or WAV_MICROSOFT (Microsoft native format). See FileFormat enum for a complete list.
- RecordingSamplingRate
- Type: Inkostar..::.DiaGlobWrapperCommon..::.SamplingRate
An enumerated constant to indicate the sampling rate: RATE_6KHZ (6Khz), RATE_8KHZ (8Khz) or RATE_11KHZ (11 Khz).
- RecordingBitsPerSample
- Type: Inkostar..::.DiaGlobWrapperCommon..::.BitsPerSample
An enumerated constant to indicate the bits per sample value: BPS_8 (8bps) or BPS_4 (4bps).
- InterruptRecordingOnDigit
- Type: System..::.Boolean
A boolean value if set to True will cause the recording to be interrupted when any digit is pressed.
Remarks
This function can only be invoked when the channel has been opened.
Compatibility: All
On failure this function will generate an exception of type DiaGlobWrapperLibException
Compatibility: All
On failure this function will generate an exception of type DiaGlobWrapperLibException
Examples
To record the voice from the oubound channel to 'c:\recorded.wav', for a duration of 1 minute and using a format of WAV and encoding of WAV_MICROSOFT at a sampling rate of 8khz. Recording will stop when a digit is pressed.
C#: objDevice.Record(ChannelOutbound, @"c:\recorded.wav", 60, Inkostar.DiaGlobWrapperCommon.VoiceFormat.WAV, Inkostar.DiaGlobWrapperCommon.FileFormat.WAV_MICROSOFT, Inkostar.DiaGlobWrapperCommon.SamplingRate.RATE_11KHZ, Inkostar.DiaGlobWrapperCommon.BitsPerSample.BPS_4, Inkostar.DiaGlobWrapperCommon.SyncMode.Asynchronous, true);
VB.NET: objDevice.Record(ChannelOutbound, "c:\recorded.wav", 60, Inkostar.DiaGlobWrapperCommon.VoiceFormat.WAV, Inkostar.DiaGlobWrapperCommon.FileFormat.WAV_MICROSOFT, Inkostar.DiaGlobWrapperCommon.SamplingRate.RATE_11KHZ, Inkostar.DiaGlobWrapperCommon.BitsPerSample.BPS_4, Inkostar.DiaGlobWrapperCommon.SyncMode.Asynchronous, True)
C#: objDevice.Record(ChannelOutbound, @"c:\recorded.wav", 60, Inkostar.DiaGlobWrapperCommon.VoiceFormat.WAV, Inkostar.DiaGlobWrapperCommon.FileFormat.WAV_MICROSOFT, Inkostar.DiaGlobWrapperCommon.SamplingRate.RATE_11KHZ, Inkostar.DiaGlobWrapperCommon.BitsPerSample.BPS_4, Inkostar.DiaGlobWrapperCommon.SyncMode.Asynchronous, true);
VB.NET: objDevice.Record(ChannelOutbound, "c:\recorded.wav", 60, Inkostar.DiaGlobWrapperCommon.VoiceFormat.WAV, Inkostar.DiaGlobWrapperCommon.FileFormat.WAV_MICROSOFT, Inkostar.DiaGlobWrapperCommon.SamplingRate.RATE_11KHZ, Inkostar.DiaGlobWrapperCommon.BitsPerSample.BPS_4, Inkostar.DiaGlobWrapperCommon.SyncMode.Asynchronous, True)