Streaming from Panasonic IP camera using RTSP

Topics: Question
Dec 14, 2015 at 8:05 AM
I want to receive a RTSP stream from a panasonic camera (Model WV-SPN531) and display the live video in my C# Form application.
If I use VLC and connect to "rtsp://IP_ADDRESS/MediaInput/h264/stream_1" the streaming works fine. Codec: H264 - MPEG-4 AVC (part10) (h264) Resolution: 1920x1080 (15 FPS)

Can you help me?

Thank you.
Dec 14, 2015 at 9:14 PM
You may want to check out this discussion Here.

It outlines how to use the RFC6184Media class and furthermore it talks about how people have actually displayed the image.

If you can use WPF / Media Foundation there is also an example Here.

You basically need to take the RtpPackets, process them for the Nal's within and feed the result to a decoder, there is code to do that in the RFC6184Media class, the process is called depacketization or depayloading.

Let me know if you need anything else.
Marked as answer by juliusfriedman on 12/14/2015 at 1:14 PM
Dec 22, 2015 at 1:49 PM
In the last days i have tried other libs but i haven't found one that works correctly.
Temporally I grab from camera using MJPEG stream, but it wastes about 40Mbit/s on the network.
In the case that the cameras ar more than 2, the 100Mbit ehternet connection dies.

Do you think that the "H264- MPEG-4 AVC (part 10)" decoder will be available soon?

Thank you very much.
Dec 22, 2015 at 7:53 PM
Edited Dec 22, 2015 at 8:03 PM
It's not likely it will be available very soon or even ever simply because it has limited use cases.

In your case it seems that even if you had a decoder you wouldn't be able to actually provide the decoded images simply because of a bandwidth consumption problem.

If you can use AForge then you are really using Ffmpeg.

Why don't you use the RtspServer to do the aggregation from the two cameras and then use Ffmpeg from another process to pull frames from the RtspServer at the localhost and Queue them for display.

Then when you want to show an image you just read it from the Queue of decoded images.

That will save you a lot of bandwidth in from the camera and out to the end users.

Please remember that bandwidth is going to be needed to consume the decoded images too so you will probably eventually need to upgrade your switch also if you plan on serving the decoded images to many users.

If you really need the codec in managed code and soon then I suggest you check out Jcodec and the IKLVM projects. You probably aren't going to get anything much more than 15 FPS with that setup but it's better than nothing.
Marked as answer by juliusfriedman on 12/22/2015 at 11:53 AM
Jan 28, 2016 at 3:25 PM
Any news about H.264 decoder?
Thank you.
Marked as answer by juliusfriedman on 1/28/2016 at 1:30 PM
Jan 28, 2016 at 9:31 PM
Not yet, sorry!
Marked as answer by juliusfriedman on 1/28/2016 at 1:31 PM