Python/OpenCV script that detect motion on webcam and allow record it to a file.
Compare video frames, checking how many pixels changed.
Detect moving objects and calculate their surface area.
- usually takes about 5 seconds to start up
- initRecorder: you can switch the output video format here
- somethingHasMoved: pixel comparison
- processImage: the fun stuff!