AudioOutputConfigImpl class

Extends

Constructors

AudioOutputConfigImpl(IAudioDestination)

Creates and initializes an instance of this class.

Properties

format

Methods

close()
fromAudioFileOutput(PathLike)

Creates an AudioConfig object representing a specified output audio file

fromDefaultMicrophoneInput()

Creates an AudioConfig object representing the default microphone on the system.

fromDefaultSpeakerOutput()

Creates an AudioConfig object representing the default speaker.

fromMicrophoneInput(string)

Creates an AudioConfig object representing a microphone with the specified device ID.

fromSpeakerOutput(IPlayer)

Creates an AudioConfig object representing the custom IPlayer object. You can use the IPlayer object to control pause, resume, etc.

fromStreamInput(AudioInputStream | PullAudioInputStreamCallback | MediaStream)

Creates an AudioConfig object representing the specified stream.

fromStreamOutput(AudioOutputStream | PushAudioOutputStreamCallback)

Creates an AudioConfig object representing a specified audio output stream

fromWavFileInput(File | Buffer, string)

Creates an AudioConfig object representing the specified file.

getProperty(string, string)
id()
setProperty(string, string)
write(ArrayBuffer)

Constructor Details

AudioOutputConfigImpl(IAudioDestination)

Creates and initializes an instance of this class.

new AudioOutputConfigImpl(destination: IAudioDestination)

Parameters

destination
IAudioDestination

An audio destination.

Property Details

format

any format

Property Value

any

Method Details

close()

function close()

fromAudioFileOutput(PathLike)

Creates an AudioConfig object representing a specified output audio file

static function fromAudioFileOutput(filename: PathLike)

Parameters

filename

PathLike

the filename of the output audio file

Returns

The audio output configuration being created. Added in version 1.11.0

fromDefaultMicrophoneInput()

Creates an AudioConfig object representing the default microphone on the system.

static function fromDefaultMicrophoneInput()

Returns

The audio input configuration being created.

fromDefaultSpeakerOutput()

Creates an AudioConfig object representing the default speaker.

static function fromDefaultSpeakerOutput()

Returns

The audio output configuration being created. Added in version 1.11.0

fromMicrophoneInput(string)

Creates an AudioConfig object representing a microphone with the specified device ID.

static function fromMicrophoneInput(deviceId?: string)

Parameters

deviceId

string

Specifies the device ID of the microphone to be used. Default microphone is used the value is omitted.

Returns

The audio input configuration being created.

fromSpeakerOutput(IPlayer)

Creates an AudioConfig object representing the custom IPlayer object. You can use the IPlayer object to control pause, resume, etc.

static function fromSpeakerOutput(player?: IPlayer)

Parameters

player
IPlayer

the IPlayer object for playback.

Returns

The audio output configuration being created. Added in version 1.12.0

fromStreamInput(AudioInputStream | PullAudioInputStreamCallback | MediaStream)

Creates an AudioConfig object representing the specified stream.

static function fromStreamInput(audioStream: AudioInputStream | PullAudioInputStreamCallback | MediaStream)

Parameters

audioStream

AudioInputStream | PullAudioInputStreamCallback | MediaStream

Specifies the custom audio input stream. Currently, only WAV / PCM is supported.

Returns

The audio input configuration being created.

fromStreamOutput(AudioOutputStream | PushAudioOutputStreamCallback)

Creates an AudioConfig object representing a specified audio output stream

static function fromStreamOutput(audioStream: AudioOutputStream | PushAudioOutputStreamCallback)

Parameters

audioStream

AudioOutputStream | PushAudioOutputStreamCallback

Specifies the custom audio output stream.

Returns

The audio output configuration being created. Added in version 1.11.0

fromWavFileInput(File | Buffer, string)

Creates an AudioConfig object representing the specified file.

static function fromWavFileInput(file: File | Buffer, name?: string)

Parameters

file

File | Buffer

name

string

Returns

The audio input configuration being created.

getProperty(string, string)

function getProperty(name: string, def?: string)

Parameters

name

string

def

string

Returns

string

id()

function id()

Returns

string

setProperty(string, string)

function setProperty(name: string, value: string)

Parameters

name

string

value

string

write(ArrayBuffer)

function write(buffer: ArrayBuffer)

Parameters

buffer

ArrayBuffer