WebRTC - Avoid renegotiation when adding track by replacing empty one

Viewed 125

I'm writing a WebRTC webapp that allows users to start on a voice call and add video while on an active call.

when adding/removing tracks a negotiation proccess is needed, but not on replacing an exsiting track.

I'm trying to avoid the need of negotiation by using the the replaceTrack function, but for that to work I need a "fake" video track, I tried this but no constructor like this is exist:

const fakeTrack=new MediaStreamTrack()

I wondered if there is a solution that will avoid the need of the WebRTC negotiation while adding tracks, maybe to pass it through a data channel..

0 Answers
Related