コード例 #1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="track"></param>
        public override void SetChannel(string connectionId, RTCDataChannel channel)
        {
            sender         = new Sender();
            senderInput    = new InputRemoting(sender);
            senderDisposer = senderInput.Subscribe(new Observer(channel));
            senderInput.StartSending();

            base.SetChannel(connectionId, channel);
        }
コード例 #2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="track"></param>
        public override void SetChannel(string connectionId, RTCDataChannel channel)
        {
            receiver = new Receiver(channel);
            receiver.onDeviceChange += OnDeviceChange;
            receiverInput            = new InputRemoting(receiver);
            receiverDisposer         = receiverInput.Subscribe(receiverInput);
            receiverInput.StartSending();

            base.SetChannel(connectionId, channel);
        }
コード例 #3
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="track"></param>
 public override void SetChannel(string connectionId, RTCDataChannel channel)
 {
     if (channel == null)
     {
         Dispose();
     }
     else
     {
         sender            = new Sender();
         senderInput       = new InputRemoting(sender);
         suscriberDisposer = senderInput.Subscribe(new Observer(channel));
         channel.OnOpen   += OnOpen;
         channel.OnClose  += OnClose;
     }
     base.SetChannel(connectionId, channel);
 }
コード例 #4
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="track"></param>
 public override void SetChannel(string connectionId, RTCDataChannel channel)
 {
     if (channel == null)
     {
         receiverInput?.StopSending();
         receiverDisposer?.Dispose();
         receiver.RemoveAllDevices();
         receiver = null;
     }
     else
     {
         receiver = new Receiver(channel);
         receiver.onDeviceChange += onDeviceChange;
         receiverInput            = new InputRemoting(receiver);
         receiverDisposer         = receiverInput.Subscribe(receiverInput);
         receiverInput.StartSending();
     }
     base.SetChannel(connectionId, channel);
 }