Our new developer documentation is now available. Please check it out!
Room
public class Room : IDisposable
Main Room
Properties
Name | Type | Description |
---|---|---|
ConnectionRetry | Int32 | The count of ConnectionState OdinRoomConnectionState retry for reconnects. Reset on Connected |
Config | RoomConfig | Room configuration |
IsJoined | Boolean | true on successful Join or false |
Self | Peer | Client Peer |
RoomUserData | UserData | |
RemotePeers | PeerCollection | Conatiner of room peers |
PlaybackMedias | IEnumerable<MediaCollection> | Get all medias of room peers |
MicrophoneMedia | MicrophoneStream | Current room microphone data route |
Static Properties
Name | Type | Description |
---|---|---|
ConnectionState | KeyValuePair<OdinRoomConnectionState,OdinRoomConnectionStateChangeReason> | ConnectionState of the Room that is set by ODIN |
Public Methods
Name | Description |
---|---|
GetRoomId | Retrieves the room ID (e.g. the name of the room) |
GetRoomCustomer | Retrieves the identifier of the customer the room |
GetRoomPeerId | Retrieves your own peer ID |
SetApmConfig | Set rooms new Apm config |
Join | Join the room via Odin gateway |
CreateMicrophoneMedia | Try to add a MicrophoneMedia |
UpdatePeerUserData | Updates the user data for our own peer. The server will populate this data to all other visible peers in the same room. |
UpdatePeerUserDataAsync | Updates the user data for our own peer. The server will populate this data to all other visible peers in the same room. |
UpdateRoomUserData | Updates the user data for the current room. |
UpdateRoomUserDataAsync | Updates the user data for the current room. |
SendMessage | Sends arbitrary data to a array of target peerIds. |
SendMessageAsync | Sends arbitrary data to a array of target peerIds. |
BroadcastMessage | Sends arbitrary data to a all remote peers in this room. |
BroadcastMessageAsync | Sends arbitrary data to a all remote peers in this room. |
GetRemotePeersIds | Get a copy of all PeerIds in this room |
GetRemotePeersMediaStreamIds | All ids of Media from remote peers in this room |
SetMicrophoneMute | Will set the room MicrophoneMedia to mute |
SetPositionScale | Configures the allowed 'view' distance for proximity calculation of peers in the room |
UpdatePosition | Updates the two-dimensional position of our own peer in the room |
ToString | Debug |
Leave | Leave a room and free all remote peers and associated medias |
Dispose | On dispose will free the room and token generator |