Breakthrough / DVR-Scan

:vhs: Tool for extracting scenes with motion from videos (e.g. security camera or DVR footage). Written in Python, uses OpenCV.
http://www.dvr-scan.com/
Other
362 stars 47 forks source link

Report file name in report for globbed files #105

Closed millerthegorilla closed 1 year ago

millerthegorilla commented 1 year ago

Description of Problem & Solution When globbing input files, dvr-scan runs successfully and completes, and finally reports what it found. The list of motion events gives offsets into the one-from-appended-mp4s video. Whilst the report provides useful information in the case where dvr-scan is running on one mp4 only, with offsets to the motion, it doesn't convey any real detail when globbing. It would be more useful when globbing to provide the filename where the motion was detected.

Media Examples:

|   Event #    |  Start Time  |   Duration   |   End Time   |
-------------------------------------------------------------
|  Event    1  |  00:12:57.1  |  00:00:07.7  |  00:13:04.8  |
|  Event    2  |  00:13:15.3  |  00:00:10.9  |  00:13:26.2  |
|  Event    3  |  00:13:54.7  |  00:00:06.5  |  00:14:01.3  |
...

Proposed Implementation: when files are globbed...

-------------------------------------------------------------
|   Event #    |  Start Time  |   Duration   |   End Time   |   filepath |
-------------------------------------------------------------
|  Event    1  |  00:12:57.1  |  00:00:07.7  |  00:13:04.8  | ./bob.mp4 |
|  Event    2  |  00:13:15.3  |  00:00:10.9  |  00:13:26.2  | ../dir1/dave.mp4 |
|  Event    3  |  00:13:54.7  |  00:00:06.5  |  00:14:01.3  | ./mp4s_8_22/10456.mp4 |

Alternative Solutions: I could use bash/python/other to array the files and then loop through running dvr-scan per item, but this would defeat the point of using globbing...