-
Notifications
You must be signed in to change notification settings - Fork 108
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
video: add "framedump" mode; use async readback for screenshots;
The framedump mode captures every frame and saves it as a .png image. This can be useful for rendering videos. To activate, set the `TAISEI_FRAMEDUMP` environment variable to a prefix. A 8-digit frame number followed by ".png" will be appended to this string to form the filename of each frame. Example: $ mkdir /var/tmp/taisei $ export TAISEI_FRAMEDUMP="/var/tmp/taisei/frame-" $ taisei -f1 -r /foo/some-replay.tsr $ ls /var/tmp/taisei frame-00000000.png frame-00000001.png frame-00000002.png ... `TAISEI_FRAMEDUMP_SOURCE` can be set to either "screen" or "viewport". The default is "screen", which records the whole game screen as it appears (minus the letterboxing borders). "viewport" makes it record the stage viewport only. The image is taken directly from the viewport framebuffer, so elements that are drawn over the viewport will be missing, such as the dialogue or the pause menu. `TAISEI_FRAMEDUMP_COMPRESSION` can be set to change the quality of zlib compression of the png images, ranging from 0 to 9. The default is 1. Additionally, it's now possible to take screenshots of the game viewport by pressing Alt+P (by default). This works on the same principle as `TAISEI_FRAMEDUMP_SOURCE=viewport`, so the same caveats apply. This can be used to take a clean screenshot of the viewport while the game is paused.
- Loading branch information
Showing
3 changed files
with
129 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters