IP camera: open source software for recording H.264

35,529

Solution 1

What about giving a try to open source openh264 backed by Cisco? It supports Long Term Reference (LTR) frames which might help you with motion detection.

Solution 2

I use the linux Motion software combined with the command line version of VLC for my IP cameras. (2 are MJPG streams, one is RTSP with H264). The motion software triggers a script to have VLC record lossless in the cameras native format. My setup does not however support pre-recording. It actually results in missing the frame that initially triggered the motion which is fine for my use since the first frames of motion are not where I'd see the faces or license plates.

Solution 3

I've found Motion to be a great program for motion detection and cataloging.

It seems to work with remote cameras, although the docs are a bit sketchy. It's probably worth a try.

Solution 4

Your camera streams H.264 over RTP controlled by RTSP. You need a RTP client to connect to the camera in order to get to the streams. http://www.live555.com provides a RTSP client library with a variety of sample code. First I would try http://www.live555.com/openRTSP/ from the command line. I have successfully used live555 to record a variety of IP cameras.

You could also use the FFMPEG library: Receiving RTSP stream using FFMPEG library

FFMPEG also takes care of muxing (creating a container file) or decoding.

Share:
35,529
Martin Vegter
Author by

Martin Vegter

Updated on July 20, 2022

Comments

  • Martin Vegter
    Martin Vegter almost 2 years

    I have an IP camera (Axis M1054) and I would like to record video stream. I would probably start with continuous recording, but then I would like to switch to clips triggered by motion detection (with pre-rec of couple seconds before the trigger occured), recording being encoded in MPEG4 (H.264), not in MJPEG.

    Is there a free open source Linux software that can do it? I did not find anything by searching the Internet. Can you recommend something that works and you successfully use? Or am I stuck with commercial software?

    I have no problem replacing the camera if different model would work better with Linux.