To start the recording you need to set up a few things.
In the actual game you can change the resolution of the captured frames by changing the resolution in the options menu, or using the commands
We need to set two variables:
r_height N
r_width M
N stands for the frame height and M for the frame width in pixels. The game will automatically switch to the next possible size if the size entered is not available.
Define the amount of frames per second you need. A NTSC standard video is approximately 30 frames per seconds, which is a good compromise between quality and file size. A high quality video can have up to 60 frames per second – the difference in quality of higher values is barely noticeable, but will still take up a lot of file space. Motion will not look smooth with less than 24 fps (cinema standard).
Fixed_time_step N
Where N specifies time step, which is calculated as follows:
time step = 1 second / amount of frames
Example: 1 second / 30 frames = 0.033333333
0.0166666667 would be 60 frames per second. If you want to record a standard PAL speed video (25 fps), use a value of 0.04.
Use the console command
Capture_file_format N
Where N should be replaced with either jpg, bmp, tga or hdr.
Capture_folder N
Where N should be replaced with the name of your folder (e.g. scene12_take1 )
Be aware that when you start a recording, the captured frames will be placed in the currently defined folder, overwriting any existing files with the same name! For each new recording you should either create a new folder or move the existing files to another folder to avoid losing any work.
Capture_frames N
Set N to 1 to start recording, and 0 to stop.
First of all, decide if you need the audio in stereo or 5.1 surround. You will need to change your audio settings in the Windows control panel. Go to “Sounds and Audio Devices” select the Volume tab, click the button “Advanced” and select your choice of output device.
#Sound.DeactivateAudioDevice()
Now, the sound output will be redirected to root folder and saved as a wav file. The sound will not be running in realtime but linked precisely to the set time step. You won’t hear anything after activating the sound again, as long as you record it.
To write the sound use the command
s_OutputConfig N
N should be set to 3 to activate the non-realtime writing of the wav file or 0 to switch it back to the default setting (autodetection). The other settings of this command are not relevant and will be explained in another tutorial.
#Sound.ActivateAudioDevice()
Now a wav file will be created in the root folder of the game. The file will continue recording until the writing is deactivated with the following combination of commands:
#Sound.DeactivateAudioDevice()
s_OutputConfig 0
#Sound.ActivateAudioDevice()
Note: Although the whole sound system is reset using the above commands, some sounds won’t restart until they are correctly triggered again. This especially applies for looped sounds. To get the correct sounds to play, it is recommended to start the recording of video and sound first, and then enter any area that triggers your looped sounds for your recording.
To capture several recordings with the same setting, it may be convenient to set up a configuration file containing the parameters required for recording, to ensure all captured files are of the same format.
A setting config file could look like this:
sys_spec = 4
Fixed_time_step 0.0333333333
Capture_file_format jpg
Capture_folder myrecording
r_width 1280 r_height 800
The command sys_spec = 4 sets the game graphic settings to very high to get the bet look possible.
To speed up the process to start and stop the recording it’s convenient to create two configuration files, one to start and one to stop the video.
To start recording, you need a config file that looks something like this:
#Sound.DeactivateAudioDevice()
s_OutputConfig 3
#Sound.ActivateAudioDevice()
Capture_frames 1
To stop recording, you need a config file that looks something like this:
Capture_frames 0
#Sound.DeactivateAudioDevice()
s_OutputConfig 0
#Sound.ActivateAudioDevice()
To activate the config file open the console and type
Exec N
while N is the name of the config file.