public async Task SystemStartup() { Console.WriteLine("SystemStartup task"); if (!Source.Enabled) { Source = await Camera.CreateAsync(SystemConfiguration.VideoDeviceSettings); } SignalingMechanism = new WebSocketSignaling(this, SystemConfiguration.SignalingURL, SystemConfiguration.WebSocketTokens); Connection = await WebRTCPeerCreator.InitializePeerConnection(); WebRTCPeerCreator.AddVideoTransceiver(Connection, Source); ClientCell = new UserCell(this); Connection = WebRTCPeerCreator.BindPeerWithController(Connection, this); }
public void SignalingClosed(object sender, string message) { SignalingMechanism?.Dispose(); SignalingMechanism = new WebSocketSignaling(this, SystemConfiguration.SignalingURL, SystemConfiguration.WebSocketTokens); }