webrtc - How i create peer-connection without localStream? -
i want achieve one client send mediasteam , another received mediasteam. receiver client needn't add localsteam.and code pc.addstream(null).but not work. how achieve webrtc?
don't call pc.addstream
null
. instead, don't call it.
- when receiver answerer, there it.
- when receiver offerer, need little work:
you need specify these rtcofferoptions createoffer
:
{ offertoreceivevideo: true, offertoreceiveaudio: true }
the reason default, offerer offers receive same kinds of streams sending. know, dumb default, gives offerer bit more control. on upside, there's no harm in specifying these options, if matches desired behavior.
Comments
Post a Comment