ofxGstRTP for receiving H.264 video streams?

i’m looking for a solution for getting video streams from an HD H.264 IP Camera (Foscam FI9826P) into open frameworks. here is an example stream:

i’ve come across the ofxGstRTP and ofxGStreamer addons; does someone know if either of these addons can help me get videostreams in?

thank you,

What platform are you targeting? I have had pretty good results with https://github.com/jnakanojp/ofxVLCVideoPlayer playing RTSP streams on Windows. The best results were with using VLC 2.0.8 (newer versions may need some work to get to compile with the addon)

Note that the example in your link actually embeds streaming MJPEG over HTTP, not H.264 over RTP.

ofxGStreamer should work, you can use a normal video player passing a gstreamer implementation as demoed in the example. then just load the movie as you would normally do with a file but pass the url instead

thank you @fieldOfView, thank you @arturo.

@fieldOfView: thank you for the hint; i will try that addon; i have noticed however that the rtsp stream from these cameras has a 1-2second delay, compared to what one gets in a browser; i was able to use VLC on os x to catch the stream. are you aware of any ways to tweak this buffering?

as for the live-demo: i think you are right, it’s an mpeg stream; they are using the “snapPicture” cgi command to get a still image; i also notice that there is a counter in the source url that is constantly increasing, frame by frame.

@arturo: excellent; i got the OfxGStreamer example working with ofx 0.8.4 from the downloads page, and xcode 6.3.1; i’m using this URL:


and the OfxGStreamer example is able to get me one frame from the camera (yay!). However, it looks like i need to have a constantly increasing counter to get the next image; and it also seems that i’m not actually using the H.264 stream at all but rather an mpeg stream; how can i do that with the GSTreamer example, since the URL is only provided at loadtime, not during update?

i also have a feeling that the cgi/snapPicture method for getting a stream from my camera will lead to lower framerates and higher network badwidth. i don’t understanding compressed video streams enough to know whether it’s possible to get any other kind of stream out of this camera or not. i do notice that when you install their browser plugin and view the video in a browser, it is much faster (compared to RTSP); do H.264 streams also just have a URL like an MPEG stream, that i should be able to provide for GSStreamer?

this cameras usually have a specific url to get a video feed, in the manual you should have the specific url you need to use to get video instead of a jpeg. there’s also pages with the most common urls like:


once you get the url for the h264 stream it should work ok.

this seems to be the correct one for your camera: rtsp://admin:powerful@etcam-02.art.cmu.edu:88/videoMain

To add to Arturo, here’s a bit more info on switching between MJPEG and H264:

i tried putting this url in the gstreamer examples player.loadMovie line but i get no video frames,
and i get this warning in xcode:

[warning] ofGstVideoUtils: update(): ofGstVideoUtils not loaded

i found this posting about a similar error in a different context:


does this mean i have to install codecs? and if so, how to do that on os x?

update: i get this warning without the rtsp:// url also. but still unable to get video from said h.264 stream