Ejemplo n.º 1
0
        static void Main(string[] args)
        {
            int    port     = 8554;
            string username = "******";                  // or use NUL if there is no username
            string password = "******";              // or use NUL if there is no password

            RtspServer s = new RtspServer(port, username, password);

            s.StartListen();

            // Wait for user to terminate programme
            String msg = "Connect RTSP client to Port=" + port;

            if (username != null && password != null)
            {
                msg += " Username="******" Password="******"Press ENTER to exit");
            String readline = null;

            while (readline == null)
            {
                readline = Console.ReadLine();

                // Avoid maxing out CPU on systems that instantly return null for ReadLine
                if (readline == null)
                {
                    Thread.Sleep(500);
                }
            }

            s.StopListen();
        }
Ejemplo n.º 2
0
        static void Main(string[] args)
        {
            RtspServer s = new RtspServer(8554);

            s.StartListen();

            // Wait for user to terminate programme
            Console.WriteLine("Press ENTER to exit");
            String dummy = Console.ReadLine();

            s.StopListen();
        }
Ejemplo n.º 3
0
        static void Main(string[] args)
        {
            RtspServer s = new RtspServer(8554);

            s.StartListen();

            // Wait for user to terminate programme
            Console.WriteLine("Press ENTER to exit");
            String readline = null;

            while (readline == null)
            {
                readline = Console.ReadLine();

                // Avoid maxing out CPU on systems that instantly return null for ReadLine
                if (readline == null)
                {
                    Thread.Sleep(500);
                }
            }

            s.StopListen();
        }