the Rainbow Networks
+++eXy FFA
Map: q3dm2
Players: 2 / 24
The golden pot › RAINBOW NETWORKS › Defrag tricks & tutorials › How to: Making videos out of demos
How to: Making videos out of demos
New to Defrag? Pro? Super Pro? Super Defrag Movie Pro? come here... :D
Post new topic   This topic is locked: you cannot edit posts or make replies.   Printer Friendly Page     Forum IndexDefrag tricks & tutorials
View previous topic :: View next topic  
Author Message

Joined: Aug 15, 2007
Posts: 1302
Location: Here

PostPosted: Wed Jul 02, 2008 2:37 am    Post subject: How to: Making videos out of demos Reply with quote

[Original Author: TimeStar]

This guide will show you how to take a demo recorded in OpenArena and turn it into an AVI file suitable for uploading to YouTube or other video sharing website.

Required software

* OpenArena
* Some video editing or converting program, e.g. avidemux, ffmpeg, virtualdub, etc.
o As part of this you will need an MJPEG codec for your video editing software, AllegedlyDead suggested K-Lite Codec Pack, which I also recommend.

Getting started

You will first need to record a demo, as far as I know Defrag does this automatically when you load a map but here is how to do it manually:

/record "<demoname>" // Starts recording a demo to "<demoname>"
/stoprecord // Stop recording the demo

NOTE: Text after and including // is a comment and is not meant to be part of the command.

Playing back a demo

You can play back a demo using the /demo command like so:

/demo <demoname>

Creating an AVI from a demo

Setting up OpenArena for recording

Having a demo that you can watch in-game is nice and everything but to watch them you need to run OpenArena so we are going to turn them into AVI files that can be played in a video playing program.

To do this you will need to set some cvars (console variables):

/cl_aviMotionJpeg [1,0] // this cvar controls which format the AVI file is created in - set it to 0 for uncompressed video 
(uses insane amounts of hard drive space) or set it to 1 for Motion Jpeg which is more space efficient, but lower quality.
/cl_aviFrameRate // This is the frame rate that the AVI is created at, higher values make the video appear smoother when 
playing back but need more CPU power, the default of 25 should be fine for most people (Hollywood movies are recorded at 
24 FPS and TV is about 30 FPS)
/r_mode // This cvar controls your screen resolution (there is a list of which values correspond to which resolutions at 
the bottom of this page) set it to -1 to use the r_custom* settings
/r_customWidth // This will let you set a custom screen width in pixels
/r_customHeight // This will let you set a custom screen height in pixels
/vid_restart // This needs to be run to change the resolution set with r_mode or r_custom*.
/s_useOpenAL [1,0] // This controls whether OpenAL is used to play back sound, it needs to be 0 for sound to be recorded in the AVI
/s_restart // Run this after changing s_useOpenAL

For video sharing websites like YouTube you can probably use a resolution of 640x480 (r_mode 3) or even 320x240.

Creating the AVI

Now that you have set your settings above it's time to record the video. To do this run the following command:

/demo "<demoname>" ; video "<videoname>" // This will play back the demo called <demoname> and immediately
after the map loads will start recording an AVI to <videoname>

You can also use the /video and /stopvideo commands while playing back a demo to record sections of it but I personally prefer to have the whole thing which I can cut up in an editing program later.

Creating the AVI on a separate hard drive

1. In-game, find out what the value of the fs_homepath cvar is set to.
2. Quit the game and browse to the folder that fs_homepath was set to
3. Copy this folder to your other hard drive
4. Modify the OpenArena shortcut so that it has

+set fs_homepath "<your/new/harddrive>"

at the end of the command, replace <your/new/harddrive> with the location of the folder you copied over in step 3, e.g. if you copied it to L:\openarena\ then you would put this in the shortcut command

+set fs_homepath "L:/openarena/"

5. Run OpenArena using the modified shortcut and it will run from your other hard drive allowing you to save videos there instead of on your primary hard drive.

Note: if you are on GNU/Linux you could just use a symlink.

Compressing the AVI

While we have an AVI file from the game it is most likely too large to upload and, in the case of MJPEG video, might not play back properly. To solve this issue we are going to have to convert it to some more compressed format such as MPEG4 or Ogg/Theora. This is where your video encoding or editing program comes in and is also where you should do any editing you would like to do on the video (adding titles or cool effects). I'm going to use avidemux as an example because it's free, I have it installed and it comes with all the codecs you need. There are probably better guides for using avidemux and of course you are free to use whatever editing software you like, this is just an example.

1. Go to File -> Open and find your video file then open it (it will most likely be somewhere like "/home/your-name/.openarena/baseoa/video" on GNU/Linux or "C:\Documents and Settings\your-name\Application Data\OpenArena\baseoa\video" on Windows.
2. From the drop down box on the left under Video select "MPEG-4 ASP (lavc)".
3. From the drop down box under Audio select "MP3 (LAME)".
4. You can play around with the options under "Configure" for the Audio and Video sections but you probably want to use a low bitrate (< 300) if the video is going on YouTube.
5. Set the output format to AVI or MP4.
6. From the File menu select Save > Save Video then enter a location for the final AVI to be saved.
7. The video will now be encoded into the formats you selected. Once it's done you will probably want to watch it to make sure it looks OK and if so...
8. Upload it!

Video editing and codecs

If you open MJPEG video you recorded from OpenArena (ioquake3 engine) in editing software like Sony Vegas, Adobe Premiere or Virtual Dub, you may be not be able to use audio only. The reason for this is in the MJPEG format which is not suitable for video editing - you have to convert it to another format or capture video in uncompressed AVI (cl_aviMotionJpeg - see above). However, the amount free space needed for the AVI is huge (about 1GB per minute).

Suggested solutions are:

For video quality:

* Record in uncompressed AVI, and edit it.
* Record in uncompressed AVI, and and convert it to MPEG2 or DV (or any other prefered editing format), then edit.

For reasonable resources:

* Record in MJPEG, and convert it to MPEG2 or DV (or any other prefered editing format).


* MPEG2 supports non-linear editing for all formats of video, that is why is suitable.
* If you are to edit your videos, do not convert them to fomats like DivX or WMV.

r_mode List

r_mode Resolution
0 320x240
1 400x300
2 512x384
3 640x480
4 800x600
5 960x720
6 1024x768
7 1152x864
8 1280x1024
9 1600x1200
10 20481536
11 856x480

I hope you have found this guide useful, post any comments such as improvements in this forum thread.
Back to top
View user's profile
Display posts from previous:   
Post new topic   This topic is locked: you cannot edit posts or make replies.   Printer Friendly Page     Forum Index -> Defrag tricks & tutorials All times are GMT + 1 Hour
Page 1 of 1

Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum

Welcome Anonymous

Latest: kontol
New Today: 0
New Yesterday: 0
Overall: 355

People Online:
Members: 0
Visitors: 74
Total: 74
Who Is Where:
01: The golden pot
02: The golden pot
03: The golden pot
04: The golden pot
05: The golden pot
06: The golden pot
07: Home
08: Maps
09: The golden pot
10: Maps
11: Maps
12: The golden pot
13: The golden pot
14: The golden pot
15: The golden pot
16: The golden pot
17: The golden pot
18: The golden pot
19: The golden pot
20: Home
21: Home
22: The golden pot
23: The golden pot
24: Maps
25: The golden pot
26: Maps
27: The golden pot
28: Maps
29: Maps
30: The golden pot
31: Home
32: The golden pot
33: Maps
34: The golden pot
35: The golden pot
36: The golden pot
37: The golden pot
38: The golden pot
39: The golden pot
40: The golden pot
41: The golden pot
42: The golden pot
43: Rainbow Media
44: The golden pot
45: The golden pot
46: The golden pot
47: Rainbow Media
48: The golden pot
49: Rainbow Media
50: The golden pot
51: The golden pot
52: The golden pot
53: My Account
54: Rainbow Media
55: The golden pot
56: The golden pot
57: The golden pot
58: Home
59: The golden pot
60: The golden pot
61: Home
62: The golden pot
63: Maps
64: The golden pot
65: The golden pot
66: Home
67: Home
68: The golden pot
69: The golden pot
70: The golden pot
71: Maps
72: The golden pot
73: The golden pot
74: Rainbow Media

Staff Online:

No staff members are online!

The Rainbow Networks website is hosted by JockeTF and Soder on

The Rainbow Networks
Interactive software released under GNU GPL, Code Credits, Privacy Policy
Azul theme and related images designed by Jamin