No Video showing, Uncaught TypeError: Failed to execute 'createObjectURL' on 'URL':

171 views
Skip to first unread message

Paul Azad

unread,
Jan 20, 2019, 3:17:07 AM1/20/19
to PeerJS
Hi

I have been looking at PeerJS for video calling. I got the server side working. And using the demo client html files at https://github.com/peers/peerjs/tree/master/examples , i have been able to test text chatting without any issues.

But trying any video calls using the html file located in the videochat folder, i dont get any video. 

When i look at the Google Chrome console, i see the following error message:

Uncaught TypeError: Failed to execute 'createObjectURL' on 'URL': No function was found that matched the signature provided.

Looking around, i believe the issue is related to Google removing support for createObjectURL, and its located in the html file:

      // Wait for stream on the call, then set peer video display
      call.on('stream', function(stream){
        $('#their-video').prop('src', URL.createObjectURL(stream));
      });


I see in https://developer.mozilla.org/en-US/docs/Web/API/URL/createObjectURL that the suggest changing to srcObject,  but i have no idea what needs to be done. I dont expect i am the only one that is having the issue, can anyone suggest what needs to be changed, or a sample html file?

Thanks


jairo caro-accino viciana

unread,
Jan 21, 2019, 3:39:26 AM1/21/19
to Paul Azad, PeerJS
Here you have a working example:
https://github.com/jmcker/Peer-to-Peer-Cue-System

Unfortunately, due to not having free time, examples on the repository
are obsolete.

Thanks,
Jairo Caro-Accino Viciana.

Paul Azad

unread,
Jan 21, 2019, 5:31:04 AM1/21/19
to PeerJS
Hi
Thanks, i had come across this page  before, but it only does text messaging. I am after video.
Reply all
Reply to author
Forward
0 new messages