Live streaming H.264 in DirectShow

gln picture gln · Jun 23, 2011 · Viewed 15.9k times · Source

Does anyone know which filters in DirectShow I have to use in order to stream H.264 LIVE stream over http? (especially what kind of source filter I have to use)

Any code suggestion will be helpful.

Thanks!

Answer

Ralf picture Ralf · Jun 23, 2011

Do you mean HTTP tunneling or the chunk-based methods of apple (MPEG-TS) and MicroSoft (MP4) ?

If you are looking for a tunneling solution, the following might be helpful:

One (typical) option is to use an RTSP source filter. However there is no stock RTSP source filter in windows. You can write your own or try to use one of the following: http://rtpstream.com/downloads.shtml I have never used it so can't say how well it works, I do remember seeing the HTTP tunneling option though.

I have also made an example one available at sourceforge if you are looking for one with source code. It uses the live555 library for RTSP/RTP/RTCP. It was aimed at streaming some audio formats and I only recently started playing around with adding H.264 support to it. I managed to stream the example H.264 files available from live555. Perhaps it could be helpful in getting started. Live555 does support HTTP tunneling, but you would have to modify the filter source code to get it right.