This project is used to analyze videos from security cameras and shows short clips from the videos which contain detected motions. It uses C# programming language, .NET Framework 4.6 and Accord.NET libraries
- The algorithm reads first frames of every half-second (e.g. if a video has framerate of 30 the algorithm retrieves 1st frame, 15th, 30th, 45th and so on)
- Images are converted to Grayscale
- Images' pixels are compared to each other
- Highlights regions with an area of changed pixels 35x35 or more
- Creates video segments metadata based on "moving" frames
- Segments with the distance between is less than 5 seconds are combined
- Segments with the duration less than 3 seconds are deleted
- Segments data is recorded to ".data" file with JSON structure
- K-Lite Codec Pack - used for video playback. The program will crash without this codec. Other codecs might do well but I've not checked.
- DirectX Playback library - used for playback as well as codec
- Install K-Lite Codec Pack (Any edition will do)
- Launch Visual Studio 2017 or later
- Go to "View -> Team explorer"
- In the Team explorer click "Manage connections button" and click "Clone" button
- Insert Git URL from repository GitHub page and clone repository to your PC
- Open MotionDecoder solution
- Go to "Solution Explorer -> MotionDecoder -> References" and check if all dependencies are loaded
- If DirectX libraries are missing add them through "References -> (double-click) -> Add Reference -> Browse" (Libraries are situated in "{Repository root}/Dependencies")
- Build and debug solution
©2020 Michael "XFox" Gordeev