Hi,
There are several free for commercial use, published RTSP DirectShow Source Filters, with full source code in C++. i must admit that it took a LOT of searching to find them!
I will tell you about one that I think is the best. Look at the source code for VLC (VideoLAN) and pull out the files:
access.c
real.c
rtsp.c
rtsp.h
That's all you need.
Look at the sample Microsoft has for a source filter for DirectShow and add these files and compile and VIOLA! you have a DirectShow Source Filter that will play any RTSP stream !!!
It's easy to compile this in Visual Studio 6.0--it will compile in later versions of VisualStudio but you have to know what you are doing and you have to tweek the code.
This makes it easy to use DirectShow to play RTSP streams from ip cameras.
I am amazed that nobody has posted this code before.
Enjoy
There are several free for commercial use, published RTSP DirectShow Source Filters, with full source code in C++. i must admit that it took a LOT of searching to find them!
I will tell you about one that I think is the best. Look at the source code for VLC (VideoLAN) and pull out the files:
access.c
real.c
rtsp.c
rtsp.h
That's all you need.
Look at the sample Microsoft has for a source filter for DirectShow and add these files and compile and VIOLA! you have a DirectShow Source Filter that will play any RTSP stream !!!
It's easy to compile this in Visual Studio 6.0--it will compile in later versions of VisualStudio but you have to know what you are doing and you have to tweek the code.
This makes it easy to use DirectShow to play RTSP streams from ip cameras.
I am amazed that nobody has posted this code before.
Enjoy