title: WebRtc,onaddstream,receive,stream,no show?
body: <p>I met with difficulties.</p>
  
  <pre><code>var onaddstream = function(event){
      var video = $("#chat_dialogForOne video[name='remote']")[0];
      var remoteStream = event.stream;
      video.srcObject = remoteStream;
      video.onloadedmetadata = function(e) {
          video.play();
      };
  }
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/up845.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/up845.png" alt="enter image description here"></a></p>
  
  <pre><code>$("#chat_dialogForOne button[name='openVideo']").on("click",function(){
      $(this).toggleClass("active");
      $(this).data("use",$(this).data("use") ? false : true);
      if($(this).data("use")){//开启视频语音聊天
          rtc.openVideoAudioLocal(function(localStream){//创建本地视频流,绑定到控件上
              var video = $("#chat_dialogForOne video[name='video']")[0]; //获取到展现视频的标签
              video.srcObject=localStream;
              video.onloadedmetadata = function(e) {
                  video.play();
              };
              rtc.openVideoAudioLocal(function(remoteStream){
                  rtc.sendAddStream(remoteStream);
              },true,true);
          },true,false);//为了防止自己能听到自己发出的声音,只启动视频,不启动音频
          $(this).find(" &gt; span").html("结束视频");
          $("#chat_dialogForOne button[name='openAudio']").hide();
      }else{//关闭视频语音聊天
          // closeRemoteChannelStream([oneWebRtc]);
          // closeLocalStream();
          // resetVideoButton();
      }
  });
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/TjnHc.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/TjnHc.png" alt="enter image description here"></a></p>
  
  <p>images 2,Successful display of local</p>
  
  <p>images 1,Failure Display Remote</p>
  
  <p>onaddstream,Received the remote stream, it does not show.to video</p>
  
  <p>I need your help.</p>