Operates WebRTC functionality
Methods
ConnectToPeer
Connects to peer
Syntax
void ConnectToPeer( string _bsPeerID )
Parameters
_bsPeerID - peer ID
DisconnectPeer
Disconnects from peer
Syntax
void DisconnectPeer( string _bsPeerID )
Parameters
_bsPeerID - peer ID
GetPeerByIndex
Gets peer by its index
Syntax
void GetPeerByIndex( int _nIndex, out string _pbsAccessName, out string _pbsPeerID )
Parameters
_nIndex - peer index
_pbsAccessName - access name of the peer
_pbsPeerID - peer ID
GetPeerProps
Gets properties of a peer
Syntax
void GetPeerProps( string _bsPeerID, out int _pnIndex, out string _pbsAccessName, out string _pbsPeerPropsList )
Parameters
_bsPeerID - peer ID
_pnIndex - peer's index
_pbsAccessName - peer's access name
_pbsPeerPropsList - peer's properties
GetPeersCount
Gets the total amount of peers
Syntax
void GetPeersCount( out int _pnCount )
Parameters
_pnCount - number of peers connected
Login
Log in to a signaling server
Syntax
void Login( string _bsSigServerURL, string _bsAccessNameOrPropsList, out string _pbsPeerID )
Parameters
_bsSigServerURL - signaling server address
_bsAccessNameOrPropsList - access name of a peer or properties list
_pbsPeerID - peer ID
Logout
Logout from a signaling server
Syntax
void Logout()
ObjectCallbackSet
Sets callback for events usage (see IMCallback interface)
Syntax
void ObjectCallbackSet( IMCallback _pCallback, long _llCallbackUserData )
Parameters
_pCallback - callback function
_llCallbackUserData - callback user data
ObjectCallbackSetFunc
Sets callback function
Syntax
void ObjectCallbackSetFunc( long _lpPFOnEvent, long _lpPFOnFrame, long _llCallbackUserData )
Parameters
_lpPFOnEvent - pointer to OnEvent event
_lpPFOnFrame - pointer to OnFrame event
_llCallbackUserData - callback user data
SendMessageToPeer
Sends a message to a peer
Syntax
void SendMessageToPeer( string _bsPeerID, string _bsMessage )
Parameters
_bsPeerID - peer ID
_bsMessage - message body