RTCRtpTransceiver.stop()

The stop() method in the RTCRtpTransceiver interface permanently stops the transceiver by stopping both the associated RTCRtpSender and RTCRtpReceiver. Once stopped, the transceiver's stopped property will return true.

This method does nothing if the transceiver is already stopped.

Note: Stopping the transceiver causes a negotiationneeded event to be sent to the transceiver's RTCPeerConnection, so the connection can adapt to the change.

Syntax

RTCRtpTransceiver.stop()

Paramters

None.

Return value

undefined

Exceptions

InvalidStateError
The RTCPeerConnection of which the transceiver is a member is closed.

Usage notes

When you call stop() on a transceiver, the sender immediately stops sending media and each of its RTP streams are closed using the RTCP "BYE" message. The receiver then stops receiving media; the receiver's track is stopped, and the transceiver's stopped property is set to true.

At that point, currentDirection is set to null and a negotiationneeded event is scheduled to be sent to the RTCPeerConnection.

Specifications

Specification Status Comment
WebRTC 1.0: Real-time Communication Between Browsers
The definition of 'RTCRtpTransceiver.stop()' in that specification.
Candidate Recommendation  

Browser compatibility

Update compatibility data on GitHub
DesktopMobile
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidEdge MobileFirefox for AndroidOpera for AndroidiOS SafariSamsung Internet
Basic supportChrome No support NoEdge ? Firefox Full support 59IE No support NoOpera No support NoSafari ? WebView Android No support NoChrome Android No support NoEdge Mobile ? Firefox Android Full support 59Opera Android No support NoSafari iOS ? Samsung Internet Android No support No

Legend

Full support  
Full support
No support  
No support
Compatibility unknown  
Compatibility unknown

See also

Document Tags and Contributors

Contributors to this page: Sheppy, fscholz
Last updated by: Sheppy,