RTCPeerConnection
Overview
The RTCPeerConnection interface represents a WebRTC connection between the local computer and a remote peer. It provides methods to connect to a remote peer, maintain and monitor the connection, and close the connection once it's no longer needed.
Location
- Reference: Island.fx
- Namespace: RemObjects.Elements.WebAssembly.DOM
- Platforms: WebAssembly
addTrack
The RTCPeerConnection method addTrack() adds a new media track to the set of tracks which will be transmitted to the other peer.
method addTrack(partrack: dynamic; parstream: dynamic): dynamic
dynamic addTrack(dynamic partrack, dynamic parstream)
func addTrack(_ partrack: dynamic, _ parstream: dynamic) -> dynamic
dynamic addTrack(dynamic partrack, dynamic parstream)
Function addTrack(partrack As dynamic, parstream As dynamic) As dynamic
Parameters:
- partrack:
- parstream:
createOffer
The createOffer() method of the RTCPeerConnection interface initiates the creation of an SDP offer for the purpose of starting a new WebRTC connection to a remote peer.
method createOffer(paroptions: dynamic): dynamic
dynamic createOffer(dynamic paroptions)
func createOffer(_ paroptions: dynamic) -> dynamic
dynamic createOffer(dynamic paroptions)
Function createOffer(paroptions As dynamic) As dynamic
Parameters:
- paroptions:
currentLocalDescription
property currentLocalDescription: String read;
String currentLocalDescription { get; }
var currentLocalDescription: String { get{} }
String currentLocalDescription { __get; }
ReadOnly Property currentLocalDescription() As String
currentRemoteDescription
property currentRemoteDescription: String read;
String currentRemoteDescription { get; }
var currentRemoteDescription: String { get{} }
String currentRemoteDescription { __get; }
ReadOnly Property currentRemoteDescription() As String
generateCertificate
The generateCertificate() method of the RTCPeerConnection interface creates and stores an X.509 certificate and corresponding private key then returns an RTCCertificate, providing access to it.
method generateCertificate(parkeygenAlgorithm: dynamic): dynamic
dynamic generateCertificate(dynamic parkeygenAlgorithm)
func generateCertificate(_ parkeygenAlgorithm: dynamic) -> dynamic
dynamic generateCertificate(dynamic parkeygenAlgorithm)
Function generateCertificate(parkeygenAlgorithm As dynamic) As dynamic
Parameters:
- parkeygenAlgorithm:
getSenders
The RTCPeerConnection method getSenders() returns an array of RTCRtpSender objects, each of which represents the RTP sender responsible for transmitting one track's data.
method getSenders: array of RTCRtpSender
RTCRtpSender[] getSenders()
func getSenders() -> RTCRtpSender...
RTCRtpSender[] getSenders()
Function getSenders() As RTCRtpSender()
getStats
The RTCPeerConnection method getStats() returns a promise which resolves with data providing statistics about either the overall connection or about the specified MediaStreamTrack.
method getStats(parselector: dynamic): dynamic
dynamic getStats(dynamic parselector)
func getStats(_ parselector: dynamic) -> dynamic
dynamic getStats(dynamic parselector)
Function getStats(parselector As dynamic) As dynamic
Parameters:
- parselector:
getTransceivers
The RTCPeerConnection interface's getTransceivers() method returns a list of the RTCRtpTransceiver objects being used to send and receive data on the connection.
method getTransceivers: array of RTCRtpTransceiver
RTCRtpTransceiver[] getTransceivers()
func getTransceivers() -> RTCRtpTransceiver...
RTCRtpTransceiver[] getTransceivers()
Function getTransceivers() As RTCRtpTransceiver()
onconnectionstatechange
property onconnectionstatechange: EventListener read write;
EventListener onconnectionstatechange { get; set; }
var onconnectionstatechange: EventListener { get{} set{} }
EventListener onconnectionstatechange { __get; __set; }
Property onconnectionstatechange() As EventListener
onicecandidate
property onicecandidate: EventListener read write;
EventListener onicecandidate { get; set; }
var onicecandidate: EventListener { get{} set{} }
EventListener onicecandidate { __get; __set; }
Property onicecandidate() As EventListener
onsignalingstatechange
property onsignalingstatechange: EventListener read write;
EventListener onsignalingstatechange { get; set; }
var onsignalingstatechange: EventListener { get{} set{} }
EventListener onsignalingstatechange { __get; __set; }
Property onsignalingstatechange() As EventListener
peerIdentity
property peerIdentity: String read;
String peerIdentity { get; }
var peerIdentity: String { get{} }
String peerIdentity { __get; }
ReadOnly Property peerIdentity() As String
pendingLocalDescription
property pendingLocalDescription: String read;
String pendingLocalDescription { get; }
var pendingLocalDescription: String { get{} }
String pendingLocalDescription { __get; }
ReadOnly Property pendingLocalDescription() As String
pendingRemoteDescription
property pendingRemoteDescription: String read;
String pendingRemoteDescription { get; }
var pendingRemoteDescription: String { get{} }
String pendingRemoteDescription { __get; }
ReadOnly Property pendingRemoteDescription() As String
removeTrack
The RTCPeerConnection.removeTrack() method tells the local end of the connection to stop sending media from the specified track, without actually removing the corresponding RTCRtpSender from the list of senders as reported by RTCPeerConnection.getSenders().
method removeTrack(parsender: dynamic): dynamic
dynamic removeTrack(dynamic parsender)
func removeTrack(_ parsender: dynamic) -> dynamic
dynamic removeTrack(dynamic parsender)
Function removeTrack(parsender As dynamic) As dynamic
Parameters:
- parsender:
restartIce
The WebRTC API's RTCPeerConnection interface offers the restartIce() method to allow a web application to easily request that ICE candidate gathering be redone on both ends of the connection.
method restartIce: dynamic
dynamic restartIce()
func restartIce() -> dynamic
dynamic restartIce()
Function restartIce() As dynamic
setLocalDescription
The RTCPeerConnection method setLocalDescription() changes the local description associated with the connection. This description specifies the properties of the local end of the connection, including the media format.
method setLocalDescription(parsessionDescription: dynamic): String
String setLocalDescription(dynamic parsessionDescription)
func setLocalDescription(_ parsessionDescription: dynamic) -> String
String setLocalDescription(dynamic parsessionDescription)
Function setLocalDescription(parsessionDescription As dynamic) As String
Parameters:
- parsessionDescription:
setRemoteDescription
The RTCPeerConnection method setRemoteDescription() sets the specified session description as the remote peer's current offer or answer. The description specifies the properties of the remote end of the connection, including the media format.
method setRemoteDescription(parsessionDescription: dynamic): String
String setRemoteDescription(dynamic parsessionDescription)
func setRemoteDescription(_ parsessionDescription: dynamic) -> String
String setRemoteDescription(dynamic parsessionDescription)
Function setRemoteDescription(parsessionDescription As dynamic) As String
Parameters:
- parsessionDescription:
signalingState
currentLocalDescription
property currentLocalDescription: String read;
String currentLocalDescription { get; }
var currentLocalDescription: String { get{} }
String currentLocalDescription { __get; }
ReadOnly Property currentLocalDescription() As String
currentRemoteDescription
property currentRemoteDescription: String read;
String currentRemoteDescription { get; }
var currentRemoteDescription: String { get{} }
String currentRemoteDescription { __get; }
ReadOnly Property currentRemoteDescription() As String
onconnectionstatechange
property onconnectionstatechange: EventListener read write;
EventListener onconnectionstatechange { get; set; }
var onconnectionstatechange: EventListener { get{} set{} }
EventListener onconnectionstatechange { __get; __set; }
Property onconnectionstatechange() As EventListener
onicecandidate
property onicecandidate: EventListener read write;
EventListener onicecandidate { get; set; }
var onicecandidate: EventListener { get{} set{} }
EventListener onicecandidate { __get; __set; }
Property onicecandidate() As EventListener
onsignalingstatechange
property onsignalingstatechange: EventListener read write;
EventListener onsignalingstatechange { get; set; }
var onsignalingstatechange: EventListener { get{} set{} }
EventListener onsignalingstatechange { __get; __set; }
Property onsignalingstatechange() As EventListener
peerIdentity
property peerIdentity: String read;
String peerIdentity { get; }
var peerIdentity: String { get{} }
String peerIdentity { __get; }
ReadOnly Property peerIdentity() As String
pendingLocalDescription
property pendingLocalDescription: String read;
String pendingLocalDescription { get; }
var pendingLocalDescription: String { get{} }
String pendingLocalDescription { __get; }
ReadOnly Property pendingLocalDescription() As String
pendingRemoteDescription
property pendingRemoteDescription: String read;
String pendingRemoteDescription { get; }
var pendingRemoteDescription: String { get{} }
String pendingRemoteDescription { __get; }
ReadOnly Property pendingRemoteDescription() As String
signalingState
addTrack
The RTCPeerConnection method addTrack() adds a new media track to the set of tracks which will be transmitted to the other peer.
method addTrack(partrack: dynamic; parstream: dynamic): dynamic
dynamic addTrack(dynamic partrack, dynamic parstream)
func addTrack(_ partrack: dynamic, _ parstream: dynamic) -> dynamic
dynamic addTrack(dynamic partrack, dynamic parstream)
Function addTrack(partrack As dynamic, parstream As dynamic) As dynamic
Parameters:
- partrack:
- parstream:
createOffer
The createOffer() method of the RTCPeerConnection interface initiates the creation of an SDP offer for the purpose of starting a new WebRTC connection to a remote peer.
method createOffer(paroptions: dynamic): dynamic
dynamic createOffer(dynamic paroptions)
func createOffer(_ paroptions: dynamic) -> dynamic
dynamic createOffer(dynamic paroptions)
Function createOffer(paroptions As dynamic) As dynamic
Parameters:
- paroptions:
generateCertificate
The generateCertificate() method of the RTCPeerConnection interface creates and stores an X.509 certificate and corresponding private key then returns an RTCCertificate, providing access to it.
method generateCertificate(parkeygenAlgorithm: dynamic): dynamic
dynamic generateCertificate(dynamic parkeygenAlgorithm)
func generateCertificate(_ parkeygenAlgorithm: dynamic) -> dynamic
dynamic generateCertificate(dynamic parkeygenAlgorithm)
Function generateCertificate(parkeygenAlgorithm As dynamic) As dynamic
Parameters:
- parkeygenAlgorithm:
getSenders
The RTCPeerConnection method getSenders() returns an array of RTCRtpSender objects, each of which represents the RTP sender responsible for transmitting one track's data.
method getSenders: array of RTCRtpSender
RTCRtpSender[] getSenders()
func getSenders() -> RTCRtpSender...
RTCRtpSender[] getSenders()
Function getSenders() As RTCRtpSender()
getStats
The RTCPeerConnection method getStats() returns a promise which resolves with data providing statistics about either the overall connection or about the specified MediaStreamTrack.
method getStats(parselector: dynamic): dynamic
dynamic getStats(dynamic parselector)
func getStats(_ parselector: dynamic) -> dynamic
dynamic getStats(dynamic parselector)
Function getStats(parselector As dynamic) As dynamic
Parameters:
- parselector:
getTransceivers
The RTCPeerConnection interface's getTransceivers() method returns a list of the RTCRtpTransceiver objects being used to send and receive data on the connection.
method getTransceivers: array of RTCRtpTransceiver
RTCRtpTransceiver[] getTransceivers()
func getTransceivers() -> RTCRtpTransceiver...
RTCRtpTransceiver[] getTransceivers()
Function getTransceivers() As RTCRtpTransceiver()
removeTrack
The RTCPeerConnection.removeTrack() method tells the local end of the connection to stop sending media from the specified track, without actually removing the corresponding RTCRtpSender from the list of senders as reported by RTCPeerConnection.getSenders().
method removeTrack(parsender: dynamic): dynamic
dynamic removeTrack(dynamic parsender)
func removeTrack(_ parsender: dynamic) -> dynamic
dynamic removeTrack(dynamic parsender)
Function removeTrack(parsender As dynamic) As dynamic
Parameters:
- parsender:
restartIce
The WebRTC API's RTCPeerConnection interface offers the restartIce() method to allow a web application to easily request that ICE candidate gathering be redone on both ends of the connection.
method restartIce: dynamic
dynamic restartIce()
func restartIce() -> dynamic
dynamic restartIce()
Function restartIce() As dynamic
setLocalDescription
The RTCPeerConnection method setLocalDescription() changes the local description associated with the connection. This description specifies the properties of the local end of the connection, including the media format.
method setLocalDescription(parsessionDescription: dynamic): String
String setLocalDescription(dynamic parsessionDescription)
func setLocalDescription(_ parsessionDescription: dynamic) -> String
String setLocalDescription(dynamic parsessionDescription)
Function setLocalDescription(parsessionDescription As dynamic) As String
Parameters:
- parsessionDescription:
setRemoteDescription
The RTCPeerConnection method setRemoteDescription() sets the specified session description as the remote peer's current offer or answer. The description specifies the properties of the remote end of the connection, including the media format.
method setRemoteDescription(parsessionDescription: dynamic): String
String setRemoteDescription(dynamic parsessionDescription)
func setRemoteDescription(_ parsessionDescription: dynamic) -> String
String setRemoteDescription(dynamic parsessionDescription)
Function setRemoteDescription(parsessionDescription As dynamic) As String
Parameters:
- parsessionDescription: