5

I am using html5 getUserMedia to attain the user's webcam stream and is stored into an object namely stream now i want to send it to the server using socket.io. When I use follwing code i get an array

    navigator.getUserMedia  = navigator.getUserMedia || navigator.webkitGetUserMedia || navigator.mozGetUserMedia || navigator.msGetUserMedia;
var video=document.querySelector("#outputview");
if( navigator.getUserMedia ) 
{
    navigator.getUserMedia( {video: true, audio: true},successcallback,errorcallback);
    function successcallback( stream ) 
    {
        video.src = window.URL.createObjectURL(stream);
        var socket = io('http://192.168.1.102:8000');
        socket.emit('data',stream);`

How to convert this into a data stream so that i could send this stream to view in another page?

1
  • 1
    I'd love to know as well. Commented Dec 30, 2014 at 21:46

1 Answer 1

1

you may get some help from this demo https://github.com/LingyuCoder/SkyRTC-demo

Sign up to request clarification or add additional context in comments.

2 Comments

I tried that but I can't convert the blob into binary packets.
Did you find a solution for it? If so, could you please provide that?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.