Our new developer documentation is now available. Please check it out!
OdinClient
On this page
export class OdinClient
Class providing static methods to handle ODIN client connections.
Properties
Name | Type | Description |
---|---|---|
config | IOdinClientSettings | Global settings for ODIN connections. |
connectionState | OdinConnectionState | The current state of the main stream connection. |
rooms | OdinRoom[] | An array of available OdinRoom instances. |
Public Methods
Name | Type | Description |
---|---|---|
addEventListener | void | Registers to client events from IOdinClientEvents . |
disconnect | void | Disconnects from all rooms and stops all audio handling. |
initRoom | Promise<OdinRoom> | Authenticates against the ODIN server and returns an OdinRoom instance for the first room set in the specified token. This function accepts an optional AudioContext parameter for audio capture. The AudioContext interface is a part of the Web Audio API that represents an audio-processing graph, which can be used to control and manipulate audio signals in web applications. If the AudioContext is not provided or explicitly set to undefined , we will try to create one internally. |
initRooms | Promise<OdinRoom[]> | Authenticates against the ODIN server and returns OdinRoom instances for all rooms set in the specified token. This function accepts an optional AudioContext parameter for audio capture. The AudioContext interface is a part of the Web Audio API that represents an audio-processing graph, which can be used to control and manipulate audio signals in web applications. If the AudioContext is not provided or explicitly set to undefined , we will try to create one internally. |