Time-traveling video recording software?
January 15, 2011 5:30 AM   Subscribe

Is there any software that will take the input of a USB webcam, and (at a given signal like a mouse-click) save the previous 30 seconds/45 seconds/one minutes/two minutes of video/audio to the hard drive? Windows is required, F/OSS is preferred.

Basically I won't know until after (some event) occurs that it should have been recorded, so I need to be able to say after the fact "Yes, what just happened, save that!"
posted by Doofus Magoo to Technology (9 answers total) 2 users marked this as a favorite
It would have to be recording, and then just erasing everything else in order to work (unless your TIMEMACHINE tag is feasible).

I've got a PC-based security cam with software that captures all motion on a timeline (in little chunks of "here was some motion oh, and here was..." and then it wipes what I don't want. Only useful of course if you're willing to plunk down $300 and what you want to capture is motion of some kind.
posted by Gucky at 7:11 AM on January 15, 2011

You could probably acheive this with timeshifting software, the kind that is used in DVR packages like Mediaportal etc.

Though, I'm thinking that Fraps is exactly what you're looking for as long as the video is being displayed via directx (which most video is). Only caveat is the free version of fraps will leave branding on the captured video...the licensed version is cheap however, and has free updates for future major versions.
posted by samsara at 8:06 AM on January 15, 2011 [1 favorite]

I think Gucky is right- the way to do it is have the thing be constantly recording and then dumping unneeded stuff.

Because even if the software doesn't expose that function, that's the only way it can do that.

One alternate way of searching for a solution would be to look at computer based DVR software. Since that's pretty inherent in the "pause live TV" functionality, that search might lead you to a solution.

One solution would be to to it like streaming video. Have the Webcam stream audio/video via something like Windows Movie Maker. On the same, or better yet a different computer, have a script that opens up a media player, connects to the streaming source, and records for say 2 minutes, and then closes without saving. Have a cascade of these going, so that a new one fires off every 30 seconds. When your even occurs, just tell the oldest open window to save the video it has recorded.

Or have them auto-save, and have another script that runs every five minutes and deletes anything older than 5 minutes.

(By overlapping them, you don't get a situation where the event straddles a new file creation. If it is just one instance of recording, your event could be happening while the recorder is starting a new file. So if your target is to be able to always get the last 2 minutes in one file, and your players fire off every one minute, they need to record for three minutes.)

That's the only way I can think of to do this without custom software. If I was going to make custom software to do it, I would have it record the video in discrete chunks of say, 1 second. For small amounts of video like a couple of minutes, you could probably hold this in memory. Just create a FIFO queue that pops old data out when new data goes in. When The Button is pressed, a function fires off that goes back into that queue and sews the chunks back together into video and saves the file.
posted by gjc at 8:08 AM on January 15, 2011

(edit: dur, of course you need more than 30 seconds....the keyword you want to look for is "Loop Recording")
posted by samsara at 8:09 AM on January 15, 2011

I've been thinking about this for about twenty years, in the context of a portable device that would record everything I said and heard into a circular buffer and save the most recent part whenever I tapped its button. I've often wondered if memory and battery technology had made this possible yet and why there wasn't a product on the market. (If the answer is "no one else thought of it" I'm going to be mad at myself for not patenting it!)

But if you're not concerned with portability then I'd think there must be a tool that does this - maybe search for "circular buffer" or "ring buffer" and "video"? That's the key technology.
posted by nicwolff at 8:20 AM on January 15, 2011

Oh and look, FRAPS seems to do basically what I'm describing, except to disk rather than to memory and with a statically-sized buffer.
posted by nicwolff at 8:24 AM on January 15, 2011

Motion can do that for motion-detection events (that is, it can start recording N seconds before it detects motion); maybe it can be made to trigger on external events as well.

There are a couple of other Linux motion-detection / secuity camera programs which might be flexible in the same way (ZoneMinder, Gspy). I've only messed with Motion.
posted by hattifattener at 1:21 PM on January 15, 2011

(Duhh! I missed the "Windows required". I don't think any of those have Windows ports. Sorry.)
posted by hattifattener at 1:26 PM on January 15, 2011

Response by poster: Sorry I wasn't clearer, but yes, I know that this is going to have to involve some buffering/FIFO queue where there's an upper limit on how far back I can go.

To clarify, this won't involve motion capture -- I'll actually be watching the camera feed while this is going on.

FRAPS' buffered recording sounds like exactly what I was looking for -- does FRAPS work with webcams? Every reference I see in the (limited) documentation on the site indicates it's for video capture of e.g., a game being played.

Thanks for the responses so far!
posted by Doofus Magoo at 2:50 PM on January 15, 2011

« Older Giving Myself The Middle Finger Treatment   |   Outside unit not running in the winter Newer »
This thread is closed to new comments.