WebRTC video track

Hi, I have a working signaling server with two PC’s, the offer/answer works, the datachannel works, the add tracks works as to that it does the callbacks and I see UDP datagrams flow between the two PC’s but I do not get the receive texture to display/update. Any guidance welcome. Not sure if I must send the ice candiate updates via the WS when they happen, what I do see is the updates create new offers/answers when I add tracks.

First the signaling server, this is just for lab/testing and it works

Now the PC1 initiating the call and capturing the video stream

Next PC2, where the call is received.

I’ve left out a lot of the code that is generic, but this works, I can make a call, sendMessage via datachannel etc. just the video does not render on the receiveImage.

pc2Ontrack = e => {receiveStream.addTrack(e.Track); };
pc2Ontrack = e => { OnTrack(_pc2, e); };

overwriting the first line?

@gtk2k Thank you, I moved the receiveStream.addTrack(e.Track); into the Ontrack function and impletmented the WebRTC.Update() Coroutine, everything is working now.

I am having the same problem. , What is OnTrack(_pc2,e) Method?

OnTrack () is an event handler.
The original OnTrack method takes one argument.
I think OnTrack (_pc2, e) is due to WayneVenter’s own implementation

@gtk2k and @hyeongwooman this is correct, my OnTrack is a self made function to handle the e.Track, here is the example:
pc2Ontrack = e => { OnTrack(_pc2, e); };

private void OnTrack(RTCPeerConnection pc, RTCTrackEvent e)
{
receiveStream.AddTrack(e.Track);
//pc2Senders.Add(pc.AddTrack(e.Track, videoStream));
Debug.Log("{pc} receives remote track:\r\n"); Debug.Log(“Track kind: {e.Track.Kind}\r\n”);
Debug.Log($“Track id: {e.Track.Id}\r\n”);
if (!videoUpdateStarted)
{
StartCoroutine(WebRTC.Update());
videoUpdateStarted = true;
}
}