Forum

Converting DEM to AVI

Discuss anything not covered by any of the other categories.

Moderator: InsideQC Admins

Converting DEM to AVI

Postby Orion » Wed Dec 12, 2007 11:21 pm

Hi, is there a program that converts Quake demos to .avi?
Thanks!
User avatar
Orion
 
Posts: 476
Joined: Fri Jan 12, 2007 6:32 pm
Location: Brazil

Postby frag.machine » Thu Dec 13, 2007 12:55 am

Darkplaces ?
I know FrikaC made a cgi-bin version of the quakec interpreter once and wrote part of his website in QuakeC :) (LordHavoc)
User avatar
frag.machine
 
Posts: 2090
Joined: Sat Nov 25, 2006 1:49 pm

Postby Orion » Thu Dec 13, 2007 1:18 am

Oh yeah, could be...
Does DP record as avi? I didn't know. How?
User avatar
Orion
 
Posts: 476
Joined: Fri Jan 12, 2007 6:32 pm
Location: Brazil

Postby Electro » Thu Dec 13, 2007 1:21 am

bind f4 "toggle cl_capturevideo"


Keep in mind the filesizes will be HUGE, and you don't want to do this while playing, it'll thrash your hdd.

I usually then re-encode the video using VirtualDub. Not sure about audio though I haven't bothered fussing around with that.
Benjamin Darling
http://www.bendarling.net/

Reflex - In development competitive arena fps combining modern tech with the speed, precision and freedom of 90's shooters.
http://www.reflexfps.net/
Electro
 
Posts: 312
Joined: Wed Dec 29, 2004 11:25 pm
Location: Brisbane, Australia

Postby Urre » Thu Dec 13, 2007 8:33 am

I've seen avi's from DP with audio, so it should be entirely possible.
I was once a Quake modder
User avatar
Urre
 
Posts: 1109
Joined: Fri Nov 05, 2004 2:36 am
Location: Moon

Postby Spirit » Thu Dec 13, 2007 10:10 am

disconnect
cl_capturevideo 1
playdemo <demoname>


Or use another engine with video recording support like rabbit run.
Improve Quaddicted, send me a pull request: https://github.com/SpiritQuaddicted/Quaddicted-reviews
Spirit
 
Posts: 1031
Joined: Sat Nov 20, 2004 9:00 pm

Postby Sajt » Thu Dec 13, 2007 3:25 pm

You can also use Fraps for OpenGL, or DOSbox if you don't mind software.
F. A. Špork, an enlightened nobleman and a great patron of art, had a stately Baroque spa complex built on the banks of the River Labe.
Sajt
 
Posts: 1215
Joined: Sat Oct 16, 2004 3:39 am

Postby Orion » Thu Dec 13, 2007 4:39 pm

Just tried.

The size is really huge, I played for about 3 minutes and I got TWO GIGABYTES of size!!!

MAN THAT'S A SIZE OF A DVD!!!! :shock: :shock: :shock:

But thise Fraps converts a regular dem?
User avatar
Orion
 
Posts: 476
Joined: Fri Jan 12, 2007 6:32 pm
Location: Brazil

Postby leileilol » Thu Dec 13, 2007 5:05 pm

it's called re-encoding the video

welcome to the world of video editing. Most of my raw recordings eat up 10gb+ average
i should not be here
leileilol
 
Posts: 2783
Joined: Fri Oct 15, 2004 3:23 am

Postby Orion » Thu Dec 13, 2007 5:15 pm

But the problem is that there's only 5gb left here.
Is there a free version of Fraps?
I got a shareware, and it can only record for 30 seconds, and the file was 200+ mb.

Recording from DP was a bit problematic, the image was too dark and the framerate were too high (fast motion).

I use VirtualDub to compress the video down.

EDIT: My PC configuration is terrible to run modern DP engines too.

What's a nice config to run DP perfectly? Here it runs a bit slow...

These are my configs:

AMD Duron 1.8ghz
768mb RAM
Master HD 36gb w/ 2 partitions
Slave HD 30gb (not working)
Nvidia GeForce FX 5200 128mb RAM
User avatar
Orion
 
Posts: 476
Joined: Fri Jan 12, 2007 6:32 pm
Location: Brazil

Postby frag.machine » Thu Dec 13, 2007 11:40 pm

Orion wrote:Just tried.

The size is really huge, I played for about 3 minutes and I got TWO GIGABYTES of size!!!

MAN THAT'S A SIZE OF A DVD!!!! :shock: :shock: :shock:

But thise Fraps converts a regular dem?


Don't know exactly about Darkplaces, but any Quake engine that uses the AVI recording code from the QdQ team can easily configure the output codec so you can record directly in DivX or XViD, as long you have the appropriated codecs installed in the machine. From the top of my mind this is the case of JoeQuake [pimp]and, of course, Q2K4. :P[/pimp]

from Q2K4 readme:
Code: Select all
.: AVI capture :.
   
   Pretty much the same thing as in JoeQuake, except that Q2K4 creates
   a "capture" folder under the current game folder (id1 by default).
   The same cvars are valid:
   
   - capture_codec
   Contains the fourcc code of video codec's, 0 by default (no compression).
   For example divx or xvid, etc. (You will need to install the desired
   codec first, of course). I strongly recommend: DO NOT USE "0" or Q2K4
   will eat all your hard drive quickly.

   - capture_fps
   Sets on how many frames/sec you wish the video to be captured.
   It's 30.0 by default.
   NOTE: this variable changes host_framerate's value during recording.

   Also, the following commands works in Q2K4 too:
   
   - capture_start <filename>
   Starts capturing an .avi file.

   - capture_stop
   Stops capturing.   

   - capturedemo <filename>
   Starts playing a demo and starts capturing it also with the same name.
   
   As noted in JoeQuake's readme file, it's always a good idea first to
   record a demo and after record the AVI file using capturedemo. And
   lower screen resolutions are better if you don't have a really good
   video card and/or CPU.
I know FrikaC made a cgi-bin version of the quakec interpreter once and wrote part of his website in QuakeC :) (LordHavoc)
User avatar
frag.machine
 
Posts: 2090
Joined: Sat Nov 25, 2006 1:49 pm

Postby Orion » Fri Dec 14, 2007 12:19 am

Ok, how do I know the video codec number? I have several here.
If I use capture_codec 0 it'll be huge.
I tried 1 and other values but I got an error.

And when I record in-game it causes a dramatical slowdown, and in a demo the image freezes every 1 second.

And when I watch the video it simply doesn't run, or run with the slowdowns.
User avatar
Orion
 
Posts: 476
Joined: Fri Jan 12, 2007 6:32 pm
Location: Brazil

Postby frag.machine » Fri Dec 14, 2007 1:02 am

Orion wrote:Ok, how do I know the video codec number? I have several here.
If I use capture_codec 0 it'll be huge.
I tried 1 and other values but I got an error.

And when I record in-game it causes a dramatical slowdown, and in a demo the image freezes every 1 second.

And when I watch the video it simply doesn't run, or run with the slowdowns.


There's no codec number. You place the 4-letter code, and "0" simply means "use no codec, eat all my hard disk!".

For example, assuming you already have installed the correct DivX codecs, you can bring the console down and set the cvars like:

capture_codec "divx"
capture_fps "15" (you can try "20" or even "30" if you have a powerful enough machine)

As stated in the readme, the AVI compression can be really slow (blame the DivX codec, this really hogs any CPU you have). That's why I advice in the readme to use lower framerates (15 fps runs fine in my 4-year old Pentium IV laptop) and lower resolution (640x480 is a good start point). You'll need to fiddle with these values to find a good compromise in your system.

Also, something that's not in the readme: if you bring down the console during AVI capture, it won't work. It's a silly bug I discovered some time ago but never released a fix.
I know FrikaC made a cgi-bin version of the quakec interpreter once and wrote part of his website in QuakeC :) (LordHavoc)
User avatar
frag.machine
 
Posts: 2090
Joined: Sat Nov 25, 2006 1:49 pm

Postby Spirit » Fri Dec 14, 2007 8:58 am

I would highly recommend using Darkplaces for the capture and NOT use an engine's inbuilt encoder (or whatever triggering the external encoder). Don't use a resolution higher than 640x480.
Encode with a program like avidemux or VirtualDub (I highly recommend avidemux). Use a codec like Xvid or x264. Use 2 Pass encoding, then you can specify a desired resulting filesize. If the image is too dark you can fix that with a filter (I also always need to apply "Swap U and V"). For sound use MP3 with ABR/VBR of ~128-192 or Ogg Vorbis.

If you do it right (like I posted above) it does not matter if Darkplaces runs slow, it does not capture in realtime but waits for the frames to be written to the harddisk.

How long is the demo that it is so huge? Or did you not think about lowering the resolution? ;)
Improve Quaddicted, send me a pull request: https://github.com/SpiritQuaddicted/Quaddicted-reviews
Spirit
 
Posts: 1031
Joined: Sat Nov 20, 2004 9:00 pm

Postby Urre » Fri Dec 14, 2007 11:01 am

Listen to Spirit. The whole point of DP's video capture feature is that it makes the game run slower, so that it can capture the framerate you specified. I've made movies with it containing tons of rtlights, takes a couple of seconds to render a frame, but the results are really cool.
I was once a Quake modder
User avatar
Urre
 
Posts: 1109
Joined: Fri Nov 05, 2004 2:36 am
Location: Moon


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 1 guest