<< audio_saveSnapshot Scilab Audio Module audio_startCapture >>

Scilab Audio Module >> Scilab Audio Module > audio_snapshot

audio_snapshot

Obtain a snapshot of the audio data

Syntax

audio_snapshot(line)
audio_snapshot(line,x,secByte)

Parameters

line :

Java object. Audio line.

x :

Double. The number of seconds or the number of bytes.

secByte :

Boolean. True for seconds, false for bytes.

Description

This function obtains a snapshot of the latest audio data stored in the buffer. This data can then be played, stored as a variable or saved into a file. The snapshot duration is based on the parameters set when creating the audio line. You can also specify the amount of data in the snapshot in either seconds or bytes.

Examples

// Requires a microphone
line = audio_getLine(16000,16,1,%t,%t,2,10);
audio_startCapture(line)
messagebox("Please say something and then click OK to continue","modal");
audio_snapshot(line)
audio_playSnapshot(line)
audio_stopCapture(line)

See also

Authors


Report an issue
<< audio_saveSnapshot Scilab Audio Module audio_startCapture >>