Screen Recording Lags

I’ve been using Processing for a couple of years now, and I’ve really enjoyed all the things I’ve learned along the way. Every now and then, I’ll want to show one of my projects to a friend or post about it online. I’ll open up OBS (Open Broadcasting Software), set it up to record my sketch, open the program, and… be faced with severe lag. No matter the size of the program, the frame rate will suffer greatly (About 10 FPS on average). I’ve tried other methods of screen capture with various programs and have gotten the same results. That being said, I’ve noticed something: If I record my whole screen, the sketch runs just fine. It’s only when I try to record the sketch window itself that things get messed up. I’m not well-versed in how PApplets, windows, etc. work, so I was wondering if there was a way I could boost the framerate when capturing the program? I usually use either P2D or P3D with very limited use of PGraphics (haven’t gotten around to learning that stuff yet… that’s a future endeavor!), so efficiency MAY be an issue, however, again: this will happen with even the smallest of sketches. Anyone know a possible solution?

Yes, the only solution is - use Hamoid’s Video Export Library. It requires an additional installation of FFMPEG which can be complicated but can be done using brew (on a mac that is). I had the same issue for a long time, but this library works, although I’ve had framedrops if I’m driving it hard but on a good day it acutally looks better than the “original” real-time java window.

That’s my experience.

Hello,

I use the Processing Movie Maker:

See the tools menu in the Processing PDE.

And make a movie (rendering) of sequential frames:

Make sure to add control to the saving of frames otherwise you are saving a lot of images every time you run the code.

A couple of references:

There are many more!

When I do screen capture I make sure to get past the “hiccups” before I capture my sketches:

Also make sure other things are not running in background that may impact frame rate if doing a screen capture.
Starting Chrome always impacts the frame rate for me as well as some other applications.

:)

1 Like

I think you can consider changing a monitor. Maybe you can try TFT LCD. I’ve used it before. It’s really an excellent monitor www.stoneitech.com