Ejemplo n.º 1
0
 public void Dispose()
 {
     try
     {
         // Unable to exit process until DataChannel is removed/disposed,
         // and this throws internally (at least in 2.0 version).
         PeerSession?.RemoveDataChannel(CaptureChannel);
     }
     catch { }
     PeerSession.Transceivers.RemoveAll(x => true);
     Disposer.TryDisposeAll(Transceiver?.LocalVideoTrack, VideoSource, PeerSession);
     GC.SuppressFinalize(this);
 }
Ejemplo n.º 2
0
 public void Dispose()
 {
     try
     {
         // Unable to exit process until DataChannel is removed/disposed,
         // and this throws internally (at least in 2.0 version).
         PeerSession?.RemoveDataChannel(CaptureChannel);
     }
     catch { }
     Disposer.TryDisposeAll(new IDisposable[]
     {
         PeerSession,
         Transceiver?.LocalVideoTrack,
         VideoSource
     });
 }
Ejemplo n.º 3
0
 public void Dispose()
 {
     try
     {
         Transceiver?.LocalVideoTrack?.Dispose();
         VideoSource?.Dispose();
         try
         {
             // Unable to exit process until DataChannel is removed/disposed,
             // and this throws internally (at least in 2.0 version).
             PeerSession?.RemoveDataChannel(CaptureChannel);
         }
         catch { }
         PeerSession?.Dispose();
     }
     catch { }
 }