public ServerListenThread(ServerSession server, List<ConnectedClient> clients, Socket socket) { this.server = server; this.settings = server.Settings; this.clients = clients; this.socket = socket; socket.Bind(new IPEndPoint(settings.IPAddress, settings.Port)); socket.Listen(20); }
/// <summary> /// Starts the recording and server. /// </summary> public bool StartServer() { sessionDialog.addressBox.Text = "0.0.0.0"; sessionDialog.portBox.Text = "9999"; sessionDialog.finishButton.Text = "Begin Recording"; switch (sessionDialog.ShowDialog()) { case DialogResult.OK: break; default: return false; } if (videoCapture == null) { videoCapture = new VideoCapture(areaDialog.Width, areaDialog.Height); videoCapture.SetPosition(areaDialog.Left, areaDialog.Top); } videoScreen.SetVideoSize(videoCapture.Width, videoCapture.Height); serverSettings.Address = sessionDialog.addressBox.Text; serverSettings.PortString = sessionDialog.portBox.Text; serverSession = new ServerSession(FFmpeg, videoCapture, serverSettings); //serverSession.TargetWindow = areaDialog.TargetWindow; serverSession.Preview = videoScreen; serverSession.StartServer(); statusLabel.Text = "Recording..."; return true; }
public ServerWriteThread(ServerSession server, BufferPool outputBuffers, List<ConnectedClient> clients, List<ConnectedClient> killList) { this.server = server; this.outputBuffers = outputBuffers; this.clients = clients; this.killList = killList; }
public ServerReadThread(ServerSession server) { this.server = server; }