Suggestions for timelapse recording of desktop

This is an archive of a topic from NESdev BBS, taken in mid-October 2019 before a server upgrade.
View original topic
Suggestions for timelapse recording of desktop
by on (#178977)
Hello all,

I was wondering if any of you might have suggestions for timelapse recording software. I have been using chronolapse to take screenshots of my windows desktop at specified intervals and it's actually pretty awesome. I then take those screenshots and import them into Camtasia and create a video. It works well.

But chronolapse is missing one thing that I'd _really_ like - the ability to only take screenshots when there has been keyboard activity since the last screenshot that was taken. There are usually long periods of time when I'm not actually doing anything on my computer (e.g. reading physical datasheets or just away from my computer) and I don't want chronolapse to keep taking a bunch of screenshots when nothing on the screen has changed. This feature would be awesome because it would _drastically_ reduce the number of screenshots taken and the amount of space that they consume over any period of time.

Do you guys have any suggestions? My requirements are pretty basic:
- Ability to take screenshot of dual-monitor desktop (chronolapse ftw)
- Ability to take screenshot at specified time internal (chronolapse ftw)
- Ability to take screenshot only when there has actually been keyboard activity since the last screenshot (chronolapse fail)

The source code for chronolapse is actually available but it's written in Python and I've never written in python and would rather not learn a whole new language just for this one feature. Heh.

Thanks!
Re: Suggestions for timelapse recording of desktop
by on (#178978)
I don't have a suggestion for software, but if these are just discrete screen shots, maybe you could try finding/making a tool to scan for and delete duplicate files. But I suppose there's always the clock, you'd at least have one change per minute. If it's a lossless format, maybe you could compare files while ignoring a region of the screen. I suppose that would get more complex if they're JPEGs.
Re: Suggestions for timelapse recording of desktop
by on (#178981)
You should be able to ask the Windows screensaver API if there's been activity. Available to C++, .NET, etc.
Re: Suggestions for timelapse recording of desktop
by on (#178984)
Memblers wrote:
I don't have a suggestion for software, but if these are just discrete screen shots, maybe you could try finding/making a tool to scan for and delete duplicate files.

I considered that, but it might get hung up on a blinking insertion point.
Re: Suggestions for timelapse recording of desktop
by on (#178986)
tepples wrote:
I considered that, but it might get hung up on a blinking insertion point.
Then outsmart that problem! Compare the captured image against the last 2, or even 3 or 4 frames.

A completely different approach might be to try Camstudio and its lossless codec. From memory, it should compress repeated identical and near identical frames very well. Also, again from memory, you should be able to turn down the capture rate, if needed. This might turn out to be a more economical solution in the end.

I don't know your exact use case, however. Maybe you actually want to cut out those frames from the material, not only to save CPU and disk space (which may become a non-issue using Camstudio's codec) but also to spare your audience those parts.
Re: Suggestions for timelapse recording of desktop
by on (#179012)
Speaking strictly about codecs: the Lagarith codec was intentionally designed with screen capturing and similar things in mind (it's a lossless codec). Just passing that knowledge on, not wanting to de-rail the main focus of the thread (which is not about codecs).
Re: Suggestions for timelapse recording of desktop
by on (#179053)
Thanks all for the suggestions. To be clear, I'm not worried about the size of the post-processed video, that's never been an issue. What I want is chronolapse to never take the original screenshot in the first place unless there has been a keyboard press since the last screenshot was taken.

I went ahead and looked at the python code (https://github.com/collingreen/chronola ... se.py#L458). This is the obvious place to modify the code :
Code:
        # on countdown
        if self.countdown <= 0:
            self.capture()      # take screenshot and webcam capture
self.countdown = float(self.frequencytext.GetValue()) # reset timer

I did some quick googling and it seems like it might be possible that I could use the msvcrt.kbhit() to see if there has been a key press.

I have no idea if that would actually work since I haven't ever written python, but I'd first need to figure out how to compile the code. First problem is I can't figure out what version of python to build against, then it seems I also need a bunch of other libraries like wx, etc.. According to his makeexe.py I would also need either pyinstaller or cx_freeze.
Re: Suggestions for timelapse recording of desktop
by on (#179064)
Normally, you shouldn't need to compile anything. For normal use, it's probably sufficient to run whatever .py file starts the application using python.exe or pythonw.exe if you don't want the terminal. You may need to install packages using pypi, which should be documented, but compiling is just a convenience for zero footprint dostribution.
Re: Suggestions for timelapse recording of desktop
by on (#180446)
Success!! I was able to get in touch with the developer of Chronolapse and he added the feature! It's now available in Chronolapse 1.9.0 and 2.0.0 for anyone who is interested. And it works absolutely P-E-R-F-E-C-T-L-Y. No more 1000+ images of dead time consuming my harddrive space! I can get up, walk away, have myself a sammich, go to bed, etc, etc, and never have to worry about it taking unending pointless screenshots.

:D