Skip to main content
Version: 0.11.x

Interface: OdinAudioDataReceivedEventPayload

The payload for the AudioDataReceived event.

Properties​

mediaId​

mediaId: number

The ID of the media that sent the audio data.

Defined in​

odin.room.d.ts:385


peerId​

peerId: number

The ID of the peer that sent the audio data.

Defined in​

odin.room.d.ts:380


samples16​

samples16: Uint8Array

The audio data received from the peer as 16-bit PCM samples ranging from -32768 to 32767 as a byte array. Use const samplesArray = new Int16Array(samples16.buffer) to get an actual array

Defined in​

odin.room.d.ts:391


samples32​

samples32: Uint8Array

The audio data received from the peer as 32-bit PCM samples ranging from -1 to 1. Use const floats = new Float32Array(samples32.buffer) to get an actual array

Defined in​

odin.room.d.ts:397