You end a stream by closing all of its tracks:
stream.getTracks().forEach(function(track) { track.stop(); })
More Related Contents:
- How to record webcam and audio using webRTC and a server-based Peer connection
- Stop/Close webcam stream which is opened by navigator.mediaDevices.getUserMedia [closed]
- WebRTC firefox constraints
- How to send a UDP Packet with Web RTC – Javascript?
- Video streaming over websockets using JavaScript
- how to make getUserMedia() work on all browsers
- Can someone comprehensively explain the WebRTC stats API?
- WebRTC video is not displaying
- How to use WebRTC to stream video to RTMP?
- WebRTC – scalable live stream broadcasting / multicasting
- reprompt for permissions with getUserMedia() after initial denial
- Sending a MediaStream to host Server with WebRTC after it is captured by getUserMedia
- WebRTC with 3 users connection
- iOS 11 getUserMedia not working?
- Chrome won’t play WebAudio getUserMedia via WebRTC/Peer.js
- How can select specific text value from <select> <option…? [closed]
- How can I run different scripts based on time? [closed]
- How to get word that is after indexOf(“@”) and add it to array
- How to check if a string “StartsWith” another string?
- Using Node.js require vs. ES6 import/export
- Check if a value is an object in JavaScript
- JS Client-Side Exif Orientation: Rotate and Mirror JPEG Images
- Making custom right-click context menus for my web-app
- Get time difference between two dates in seconds
- Amazon S3 direct file upload from client browser – private key disclosure
- Replace all spaces in a string with ‘+’ [duplicate]
- Get query string parameters url values with jQuery / Javascript (querystring)
- Is there ‘element rendered’ event?
- combine dynamic and static classes through css binding, knockout.js
- How do I listen for triple clicks in JavaScript?