addTrack Is not a function
See original GitHub issueI am using the react-native-webrtc ^1.84.1
but its throwing error addTrack
is not a function when I try to add track with the peer connection object.
My code is below
const connectionBuffer = new RTCPeerConnection(config);
stream.getTracks.forEach(track =>
connectionBuffer.addTrack(track, stream),
);
Complete code of the page can be found here https://github.com/jdmg94/react-native-webrtc-example/blob/master/App.js I am using this example
Expected behavior
Expected it to connect and start streaming
Observerd behavior
But its throwing error saying addTrack is not a function
Steps to reproduce the problem
https://github.com/jdmg94/react-native-webrtc-example/blob/master/App.js I am using this repo example as my base,
Platform information
- React Native version:0.63.2
- Plugin version:^1.84.1
- OS: Android
- OS version:
Issue Analytics
- State:
- Created 3 years ago
- Reactions:5
- Comments:11 (3 by maintainers)
Top Results From Across the Web
Uncaught TypeError: peerConnection.addstream is not a ...
I have tried to add the stream in the following way. function startPeerConnection(stream) { var configuration = { // Uncomment this code to...
Read more >RTCPeerConnection.addTrack() - Web APIs | MDN
The RTCPeerConnection method addTrack() adds a new media track to the set of ... Only tracks are sent from one peer to another,...
Read more >this._pc.addTrack is not a function simplepeer or simple-peer
addTrack is not a function simplepeer or simple-peer help, interview question, Android,Javascript, React, React Native, Php, Salesforce.
Read more >RTCPeerConnection addTrack missing in Chrome (version
addTrack is not a function (pc = RTCPeerConnection), does someone know any workaround? I'm using the adapter.js from -> https://github.com/ ...
Read more >Developers - addTrack Is not a function - - Bountysource
I am using the react-native-webrtc ^1.84.1 but its throwing error addTrack is not a function when I try to add track with the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
PeerConncetion…addTrack is not implemented.
@ajitdas123 @pdias94 As @saghul mentioned,
RTCPeerConnection.addTrack(..)
has not been implemented yet as can be seen in this file. You can however add a stream to the peer connection (usingRTCPeerConnection.addStream(..)
) and add the tracks to the stream (usingMediaStream.addTrack(..)
)@saghul am I correct in my interpretation?