Can't connect to the server with VLC

Topics: Question
Jan 24, 2017 at 2:55 PM
Hi there !
First of all congratulations, you made a very nice work here.

The problem is the following :

I would like to build an RTSP server for H264 movies, so i wrote this little test program to see if i can read the RTSP stream with VLC (At the moment only one frame is sent in a loop but later frames will comes from some cameras.) :
        static void Main(string[] args)
            Bitmap srcBmp = (Bitmap)Image.FromFile(@"C:\Users\********\Desktop\test.jpg", true);
            RtspServer server = new RtspServer(System.Net.IPAddress.Any, 554)
                Logger = new Media.Rtsp.Server.RtspServerConsoleLogger()

            RFC6184Media media = new RFC6184Media(640, 480, "test");

            while (true)
                Bitmap bmp32 = new Bitmap(640, 480, PixelFormat.Format32bppArgb);
                using (Graphics g = Graphics.FromImage(bmp32))
                    g.DrawImage(srcBmp, 0, 0);
So this program is running, I launch VLC and try to connect to rtsp://myIP:554/live/test, it seems to work but after just 10 to 20 seconds the server disconnect me because of an exception, i think ? (there is a link of the screenshot below).

I noticed one thing, when i analyzed packets with wireshark, after the client send the PLAY command, the server answer with 200 and just after it re-answer a 401, I don't know if it's the wanted behavior. The link of the wireshark is below.

Do you have any idea ?

Thanks for your time,