I need a way to scan through hours and hours of recorded video (mp4, mov, avi, doesn't matter, I can fix that) to search for motion. The videos consist of many, many hours of dull nature scenes like bird nests or a feeding site where very little happens for long stretches punctuated by short bursts of action like parents switching, feeding, etc.

I can't use a cctv monitoring program because those monitor a live stream and only record when there's action. These videos are recorded way off the grid where any form of internet connection is a distant dream.

I've looked at Zoneminder and Motion, but these don't allow me to switch the input from a live feed to a file. Ideally, I'd like it to scan a whole lot faster than real-time.

Any ideas?

  • I'm having the same problem. I tried the VLC filter, didn't work out for me. Did you find a solution? – user580266 Aug 10 '16 at 10:40
  • Sorry, no, I didn't. – Marc Aug 11 '16 at 2:06
  • I am currently working on a windows based software to do this. I will update here once the beta is released in case anyone else needs to do this. – user2924019 Sep 29 '16 at 10:28
  • hello, I have exactly same task. Is there a hope to see a release? – Nikita Kipriyanov Feb 3 '17 at 20:03


DVR-Scan is a cross-platform command-line (CLI) application that automatically detects motion events in video files (e.g. security camera footage). In addition to locating both the time and duration of each motion event, DVR-Scan will save the footage of each motion event to a new, separate video clip. Not only is DVR-Scan free and open-source software (FOSS), written in Python, and based on Numpy and OpenCV, it was built to be extendable and hackable.


dvr-scan -i some_video.mp4 -o some_video_motion_only.avi
  • 1
    Works very well, but it's very slow, too. Analysis takes about 20 min for a 1h video, using a quad core i5-7400. That may be fine in a desktop computer, but in a low resource server (like a Raspberry Pi), analysis can perfectly take more time than the actual video. – jesjimher Jun 19 '20 at 9:22
  • 1
    @jesjimher, try the new CNT option. Also try reducing the data using scale and skip options. – Bahram Ardalan Jul 18 at 1:39


VLC has a motion detection filter that you can try by accessing: Tools -> Effects and Filters -> Video Effects -> Advanced -> Motion Detect.


You might have more tweaks available running it from the command line with the --video-filter=motiondetect flag; check out this example.

  • I'm not understanding what this is supposed to do - I do not see any change in my video playback when I select this option. – Michael Jun 27 '20 at 22:11
  • restart vlc after change setting – gdbdable Aug 18 '20 at 8:00
  • This highlights changes in the video by overlaying white boxes. This may be helpful, but you still have to watch the video. – Christian Jan 9 at 12:58

Not the answer you're looking for? Browse other questions tagged or ask your own question.