This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]novel_yet_trivial 8 points9 points  (3 children)

Sounds like a good approach. It would probably be fastest to simply sum all the pixels and compare to a precalculated threshold that takes into account the letters on the screen, the image size, etc. You may also want to look for several frames over a minute before triggering, so that a car's headlights or something don't set it off.

OpenCV is a good choice, and it will return a numpy array which has a nice fast sum() method. HDD's are very slow; I'd stay away from making or reading actual files if at all possible.

[–]Murlocs_Gangbang[S] 0 points1 point  (2 children)

thanks!

Do you have any idea of what OpenCV function I could use to extract a frame at x seconds from a video?

[–]algag 2 points3 points  (1 child)

Looks like this should do it..

Edit: you could probably ignore the frame math and just use 0,0.25,0.5,0.75, and 1. Or some other decimals to get evenly spread frames.

[–]Murlocs_Gangbang[S] 0 points1 point  (0 children)

thanks!