public MJpegServer(int port, VideoSource source, QualityDefinition qualityDefinition) { this._server = new ThreadedServer(port, System.Net.IPAddress.Parse("127.0.0.1"), 100); this._server.ClientDataReceived += new ThreadedServer.ClientDataReceivedEventHandler(this.OnClientDataReceived); this._server.SocketError += new ThreadedServer.SocketErrorEventHandler(this.OnSocketError); this._streamer = new MJPEGStreamer(source, qualityDefinition); }
/*//test encoding phase, every x seconds * IEnumerator SendPhase(bool value){ * yield return new WaitForSeconds(TCP_Config.numSecondsBeforeAlignment); * while(true){ * myServer.SendStateEvent(GameClock.SystemTime_Milliseconds, "ENCODING", value); * yield return new WaitForSeconds(10.0f); * } * }*/ void RunServer() { UnityEngine.Debug.Log("creating threaded server"); myServer = new ThreadedServer(); //SetupClient(); myServer.Start(); }
public SimpleServer(int port, VideoSource source, QualityDefinition qualityDefinition) { _server = new ThreadedServer(port); _server.ClientDataReceived += OnClientDataReceived; _server.SocketError += OnSocketError; _streamer = new MJPEGStreamer(source, qualityDefinition); }
void Start() { myServer = new ThreadedServer(); UnityEngine.Debug.Log("starting"); myServer.Start(); }
void RunServer() { myServer = new ThreadedServer(); myServer.Start(); }