licode icon indicating copy to clipboard operation
licode copied to clipboard

What if I just want to subscribe to a stream

Open bugcook opened this issue 12 years ago • 2 comments

I come across with this situation:

  1. I want to subscribe the remote stream
  2. I don't want to share my local video or audio
  3. I want to chat with others in the room

When coding, I find if I want to send message, I must enabled my local video or stream or screen, if not, I will get the message Failed to send data. This Stream object has not that channel enabled

I currently solve this problem by just not show the local stream, but I still need to allow my browser to use my camera or mic.

So can I send out message even I deny the browser use my camera or mic?

bugcook avatar Feb 27 '14 08:02 bugcook

1+2) You can just subscribe to streams without setting up a localStream, take a look in https://github.com/ging/licode/blob/master/extras/basic_example/public/script.js

Just don't create a localStream: localStream = Erizo.Stream({audio: true, video: true, ...});

Try this, i hope the cam/mic message doesn't come up. localStream = Erizo.Stream({audio: FALSE, video: FALSE, ...}); localStream.sendData({...}); // Emit your data to all subscribers

For these type of questions you can use the community mailing list: http://lynckia.com/licode/community.html

peili avatar Feb 27 '14 09:02 peili

Moved to https://groups.google.com/forum/#!searchin/lynckia/What$20if$20I$20just$20want$20to$20subscribe$20to$20a$20stream/lynckia/R5xZL5DOyRI/h9Me1mAQ5ggJ

Thank you!

aalonsog avatar Feb 27 '14 10:02 aalonsog