webrtc use addTrack after connected(two device)invalid

210 views
Skip to first unread message

6467...@qq.com

unread,
Apr 23, 2019, 3:23:37 AM4/23/19
to discuss-webrtc
Hi everyone,

I use Android phone and web page build webrtc connection。
begin,android add video and audio track,and web page do not add any track。I want a button add and remove audio track after connected,
but when after connection established,I addtrack no effect,and Android device not receive onAddTrack。
how to do it?

getLocalStream(function (stream) {
   stream.getTracks().forEach(function (track) {
        console.log("--------------- addTrack stream:"+stream);
        return peer.addTrack(track, stream);
   });
});

I don't want open audio always and begin,so I want to add track after connection。 

Shashidhara K

unread,
Apr 24, 2019, 2:10:18 AM4/24/19
to discuss...@googlegroups.com
I didnt work on android webrtc. But when i see detail on this link, my we have to use addStream and onAddStream.

--

---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/87f3a2d4-1992-42db-b6a9-6c6b51ce51ee%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--


- Regards,
  Shashidhara
  Mangaluru.
Reply all
Reply to author
Forward
0 new messages