How to save every frame to a file?

Good day,
I need to create a video of my 3D scene for a next exhibition of my firm.
But my PC is too slowly an when I try to render the scene with all the lightings and shadows I receive 0,5 FPS. I think the simplest way is to make my game world slowly

allVelocities*=1f/120f;
cameraVelocity*=1f/120f;

and save every frame in a single file and after that using an another software I can glue together this single frames in a large spectacular video.
How can I save the screen image in a file?

I have not understood how to write single image files using this class. The constructor

VideoRecorderAppState(float quality, int framerate)

can not apply float-framerate (I have only 0.5 FPS).

Is the screenshot app state an option to take a screenshot every frame then stitch them together later (at a different FPS than really happened)

I think the video recorder app state will run as slow as it needs to to achieve the requested quality and frame rate.

It won’t store individual images but will stitch them together for you into a video… which sounds like what you were going to do with the images anyway.

Else you could trigger the screen shot app state every frame like richtea suggests… but give yourself lots of time because that’s going to take a looooong time. Given that you are already getting 0.5 frames per second (2 seconds per frame), maybe double or triple that.

Note: there may also be easy ways to improve the framerate while maintaining visual quality. We’d have to know more about your scene, though.

It’s correct. I used it for the 360 video project, and it takes an immense amount of time to render 360 videos at a decent size, but they end up with all the visual quality you might expect. I’ve also used it for other ‘product’ showcases.

Unless you have specific requirements, I’d recommend planning ahead the shots you want to take and do simple panning / zooming shots by slowing down the flyCam. Do one run of the app per shot. Then take the best shots and edit.

Files end up large, so have some space prepared.

Yes, there is no compression. If there is a bigger need, one might want to fork the VideoRecorderAppState, use ffmpeg or similar to encode the video to safe up some space.

One tip also, if you have NVIDIA hardware. Shadowplay is very good. But in this case if you struggle to get FPS without any recording, that might not work either.

Thanks!

Thanks to everyone! I have used ScreenshotAppState to save every frame and received 5 Gb of pictures.
After that I used Shotcut to create a video for the exhibition. One of the frames is below:

5 Likes