Screen Recording
Nov 12, 2013In order to be able to show off how good you are in front of your friends, or to show the world something interesting, or to just record yourself playing for fun, you need to record the screen output rendered by Sauerbraten. To do this, there are different methods; here they are explained:
Recording
The built-in /movie
command
Sauerbraten has a built-in command to record the frames it renders and write them to a file: /movie
. It is however of little use: it generates huge .avi files containing all the individual frames, without any compression at all. Nevertheless, some people might want this, and big files might not be a problem, so here is some explanation on how to use /movie
.
Before you start recording, you should set a few things up:
/moviesound 1|0
specifies wether sound will be included in the recorded .avi file/moview 1920
sets the width of the recording in pixels, replace 1920 with e.g. 1280 for 720p recording/movieh 1080
sets the height of the recording in pixels, again, replace 1080 with 720 to record in 720p/moviefps 30
sets the frame rate at which recording will take place; 30 will suffice if you do not intend to make slow-motion clips (if you do, read on, it’s explained further down)
If you have set up all that, start a recording with /movie asdf
, with asdf
being the name of the file the recorded frames are saved to (asdf.avi in this case). To stop recording, just type /movie
.
External screen recording software
Since the /movie
command produces big files and is kind of clumsy, it makes sense to use an external screen recording software. For Windows, there is FRAPS, a widely-used and well-known program. There is probably a lot of information out there on how to record games with it already, so Google can probably help you. For Linux, Simple Screen Recorder works well using the OpenGL recording feature (experimental at the time of writing, but known to work with Sauer). However, due to the way Sauerbraten is launched, you need to know a few things. Here’s a short guide:
- Tick the “Record OpenGL” option
- Click on “OpenGL settings”
- As command, use
/path/to/sauerbraten/bin_unix/linux_64_client -q~/.sauerbraten -k/path/to/sauerbraten
(with the correct path to your Sauerbraten folder of course) - Set “Frame rate” to 30 (or higher if you want)
- Unselect “Scale video”
- Tick “Record cursor”
- Click “Continue”
- Next, select file name and codecs (MP4 as container, H.264 as video codec, AAC as audio codec is fine)
- Before clicking “Continue”, start Sauerbraten
- Set the desired resolution, and set
/maxfps 30
(or whatever you used in SSR). Maybe use windowed mode to be able to easily switch between Sauer and SSR - Close Sauerbraten using the menu, so it can save your settings
- In SSR, click “Continue”
- When you are ready to record, click “Start recording” in SSR
Demo playback
In case you do not want to record yourself playing live, you can use Sauerbraten’s demo file functionality. You can get demo files from most online servers, either using the /listdemos
and /getdemo
commands, or by downloading them from the website advertised on the server.
Here are some useful commands for demo playback:
/demo <file.dmo>
: starts demo playback/gamespeed 10..1000
: controls gamespeed; sounds stay the same however (chain gun sound playback rate is adjusted of course); 100 is default (think of it as percent)/pausegame 1|0
: pauses/resumes game/thirdperson 0..2
: 0 means first person view, 1 is fixed third person view (you see your character from behind), 2 is a freely rotating third person view (you can’t aim with your mouse anymore)
A smart way to use the /gamespeed
command is to do /gamespeed 50
(or something like that), then after recording speeding up video by 2 times, except for scenes you want to be slow-mo. Using this method you don’t have a problem with low frame rates in slowed down scenes, but on the other hand sounds will need fixing probably.
The Wahn/Wonder Client offers an easy way of jumping to a certain time in a demo: /jumpto <mm:[ss]>
will jump to mm
minutes (and ss
seconds) left to play (note: you can’t jump backwards in demos).
If you are using a vanilla client, it might be a good idea to make binds for changing the game speed to allow fast-forwarding, for example gamespeed 1000
on RIGHT
, gamespeed 50
on LEFT
, gamespeed 100
on UP
, or to do something like /bind RIGHT [gamespeed 1000; onrelease gamespeed 100]
.
You can find more about demos on ogros.org.