# Could not display for remote producers

**URL:** <https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785>\
**Category:** mediasoup-demo\
**Created:** [December 25, 2022, 12:36am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785 "2022-12-25T00:36:56Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![onknight05](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/onknight05/32/1885_2.png) [@onknight05](https://mediasoup.discourse.group/u/onknight05)\
**Post date:** [December 25, 2022, 12:36am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/1 "2022-12-25T00:36:56Z")

</div>

![image](https://global.discourse-cdn.com/free1/uploads/mediasoup/original/2X/6/6d0282953974c734c0536ad0f95864133664b4b2.png)  
Hi,  
I’m trying to implement follow the mediasoup demo. Everything looks good, but when I test on 2 peers, I could not get the video on the second peer. The first one does screen sharing, and the video can bind to the local video srcObject as well, but something is wrong with the second peer.

---

<div class="post-metadata">

**Author:** ![zaidiqbal](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/zaidiqbal/32/1498_2.png) [@zaidiqbal](https://mediasoup.discourse.group/u/zaidiqbal)\
**Post date:** [December 25, 2022, 7:22am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/2 "2022-12-25T07:22:03Z")

</div>

You will have to see chrome://webrtc-internals to debug the peer connections, or share screenshot here.

There can be many reasons for this type of issue, like not using proper public ip address on server after deployment or if you are testing on local then something like not resuming consumer after consuming the transport or simply not rendering the streams properly etc. You can console log the track received to see whether it is paused or not.

---

<div class="post-metadata">

**Author:** ![onknight05](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/onknight05/32/1885_2.png) [@onknight05](https://mediasoup.discourse.group/u/onknight05)\
**Post date:** [December 27, 2022, 2:02am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/3 "2022-12-27T02:02:17Z")

</div>

Thanks for your reply,  
I use the same server for my client and mediasoup-demo client, the mediasoup-demo client is working well with my server so i think it’s not related to server’s public ip.  
I also try “pause: true” when consumerTransport consume on the server and then resume when connectionstatechange to connected, but it still work well with mediasoup-demo, not with my client code. My client code still receives the consumer track, but could not render it. When I log the consumer track, it seems the same result as when I log on mediasoup-demo.  
I implement mediasoup-client on nextjs framework, so I’m wondering that is there any diff with implementing mediasoup-client in the demo?  
Let me know if you have any ideas, thank u!

---

<div class="post-metadata">

**Author:** ![zaidiqbal](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/zaidiqbal/32/1498_2.png) [@zaidiqbal](https://mediasoup.discourse.group/u/zaidiqbal)\
**Post date:** [December 27, 2022, 6:51am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/4 "2022-12-27T06:51:48Z")

</div>

Nextjs will not make any difference, at the end it is going to be javascript. First thing you need to do is to check the things with the peer connection that will tell you all the story, go to chrome://webrtc-internals and it will show you all the details about all peer connections (transports) you have opened.

Share the screenshot here, I will be able to tell you then.

---

<div class="post-metadata">

**Author:** ![onknight05](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/onknight05/32/1885_2.png) [@onknight05](https://mediasoup.discourse.group/u/onknight05)\
**Post date:** [December 27, 2022, 7:26pm UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/5 "2022-12-27T19:26:13Z")

</div>

Server 192.168.3.101  
Client: 192.168.3.102  
2 Peers run on the same client, Peer 1 does screen sharing

 ![image](https://global.discourse-cdn.com/free1/uploads/mediasoup/original/2X/4/4fdb61828994727ba6eadc45b227271a7ab766d5.png)

---

<div class="post-metadata">

**Author:** ![onknight05](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/onknight05/32/1885_2.png) [@onknight05](https://mediasoup.discourse.group/u/onknight05)\
**Post date:** [December 27, 2022, 7:27pm UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/6 "2022-12-27T19:27:13Z")

</div>

For stats graphs detail

 ![image](https://global.discourse-cdn.com/free1/uploads/mediasoup/original/2X/c/c57a15a185cf573be5e64a67f94f42ee7074df82.jpeg)

---

<div class="post-metadata">

**Author:** ![zaidiqbal](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/zaidiqbal/32/1498_2.png) [@zaidiqbal](https://mediasoup.discourse.group/u/zaidiqbal)\
**Post date:** [December 27, 2022, 7:33pm UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/7 "2022-12-27T19:33:01Z")

</div>

Everything is normal, data is being sent and received properly. The only issue that can be imagined based upon this is that you are not displaying the video properly، to make sure about that kindly enable controls on video player and play it manually may be there is some autoplay issue, also console log the srcObject for video element

---

<div class="post-metadata">

**Author:** ![onknight05](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/onknight05/32/1885_2.png) [@onknight05](https://mediasoup.discourse.group/u/onknight05)\
**Post date:** [December 28, 2022, 8:54am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/8 "2022-12-28T08:54:28Z")

</div>

You are right, it seems the root cause of this issue is related to video player.  
Thank you for your support!

---

<div class="post-metadata">

**Author:** ![zaidiqbal](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/zaidiqbal/32/1498_2.png) [@zaidiqbal](https://mediasoup.discourse.group/u/zaidiqbal)\
**Post date:** [December 28, 2022, 9:05am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/9 "2022-12-28T09:05:47Z")

</div>

You were able to play the video manually hi hitting the play button?

---

<div class="post-metadata">

**Author:** ![onknight05](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/onknight05/32/1885_2.png) [@onknight05](https://mediasoup.discourse.group/u/onknight05)\
**Post date:** [December 28, 2022, 9:19am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/10 "2022-12-28T09:19:15Z")

</div>

Yes, play manually is OK, but autoPlay not working.

---

<div class="post-metadata">

**Author:** ![onknight05](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/onknight05/32/1885_2.png) [@onknight05](https://mediasoup.discourse.group/u/onknight05)\
**Post date:** [December 28, 2022, 9:22am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/11 "2022-12-28T09:22:04Z")

</div>

I found a solution on StackOverflow by, adding autoplay along with muted. It worked for me.

> <https://stackoverflow.com/questions/17994666/video-auto-play-is-not-working-in-safari-and-chrome-desktop-browser>

---

<div class="post-metadata">

**Author:** ![zaidiqbal](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/zaidiqbal/32/1498_2.png) [@zaidiqbal](https://mediasoup.discourse.group/u/zaidiqbal)\
**Post date:** [December 28, 2022, 9:38am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/12 "2022-12-28T09:38:54Z")

</div>

Great check out my recent topic to enable audio autoplay on ios:

> [@Audio auto-play issues, IOS, safari](https://mediasoup.discourse.group/t/audio-auto-play-issues-ios-safari/4782):
>
> Safari on IOS blocks audio to be played without user interaction. So to tackle that I added a popup with button saying “Join with system audio”, just like zoom, to get the user interaction and after that I call play() on audio element. This works well for the first audio element but the audio elements which are added after that still throw the same autoplay permission error causing audio to not play. The other solution which comes to my mind is to use AudioContext and have only one audio player…

---

<div class="post-metadata">

**Author:** ![onknight05](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/onknight05/32/1885_2.png) [@onknight05](https://mediasoup.discourse.group/u/onknight05)\
**Post date:** [December 28, 2022, 9:59am UTC](https://mediasoup.discourse.group/t/could-not-display-for-remote-producers/4785/13 "2022-12-28T09:59:02Z")

</div>

Thank you so much!
