Guide Recording in Dota 2, now How do I record films in DOTA?
You can find similar to this explanation on how to record in source games(including Dota2) here:
http://tf2wiki.net/wiki/Help:Recording_demos
and here:
https://developer.valvesoftware.com/wiki/Demo_Recording_Tools
Content:
-Intro and a little explanation
-Enabling the console
-Finding the replay
-The “startmovie” & “endmovie” commands
-Virtual Dub
-Optional things
(im sorry, but I am not able to upload it here, because it resizes it, please if a staff member could contact me to fix that, but for now, look at the pic above)
The picture above shows comparison of space taken and quality between h264 encoded video, uncompressed video and fraps video. Those are actual screenshots from the video, rather than from the game.
——————————————————
Hello, I’m ralje, aka evldmn. Shortly after seeing all those “how to fraps?” threads here in PD chat I just had to write a guide like this. You see, if you follow this guide you’re gonna produce results like the picture below:
A little explanation on the source engine(the engine Dota2 uses). The source engine is one of the few that has a “frame-by-frame rendering” option. What this means is that the engine itself handles recording frame by frame, enabling the production of high-quality frames, it’s almost real-time. To put it simply it’s like it screenshots every single frame of the video with full quality settings. This is the technique used in this video:
You surely understand that is not possible with today’s home pcs, right?
Anyway this is not something new, it’s available in goldsrc, which is used by games like Counter-Strike or Half-Life, so for people who have made videos for games like this it’s self-explanatory, even more the current source engine doesn’t render videos itself, they removed that option I don’t know when, but now it’s the same as in goldsrc.
Now, if you want to produce better quality videos in dota2, than you produce with fraps or ANY screencapturing program, please continue to read…
I’ll be explaining very deeply and with screenshots. It’s a step-by-step guide, so I guess if you follow the steps, you will succeed in getting the results.
Enabling the console
——————————————————
First you need to enable the console on your Dota2. Left click on your dota2 in Steam and click properties:
——————————————————
When you’ve opened the properties window click “SET LAUNCH OPTIONS” and write “-console” in the window that appears.
——————————————————
——————————————————
That’s it, we’re done with the enabling of the console, now open dota2 and when this option is enabled this window should pop everytime you start the game, this is the console:
——————————————————
You close and open the console with the tilde char on your keyboard ~ usually it’s found here:
Finding the replay
READ: Finding the replay does not work right now, seriously. I’ve tried, but cannot download any recent games. There is literally no download button. Also found out that you can record games with normal controls if you’re a spectator, gonna update the guide with it soon.
——————————————————
Now I’ll explain how to search your games and save the replays. So, what I like in dota2 are replays, they are getting hosted on the dota2 servers so you can find any replay, but you better save them just in case. Or for example if you want to find replays of famous players or your friends or some random guy etc. Ok, so now you’re in the lobby, click Watch, then click recent games, and then filter.
——————————————————
——————————————————
You can see there are different filters you can use to find the needed replay, I’m using the name now. I have played this game with the nickname of “evldmn”. So write whatever you need and click apply.
——————————————————
——————————————————
Look, it found our game, yay! Now click on details.
——————————————————
——————————————————
So, you’ll see that now we’re downloading it, and after that it should say watch. Like in the screen below. Now you may click it and watch the replay, which is needed for further instructions. But please first read the text below the picture.
——————————————————
Now this saves the replay in your “Steam/steamapps/common/dota 2 beta/dota/replays” folder. Nothing wrong with that, but I need to point out that there is a command that you can use so you could watch the replay, skipping all this watch and find things, just by writing a command in the console. The command is“playdemo x” without the apostrophes, where x is the replay’s name. Now you won’t be able to use the command with any replay if they are in your “replays” folder. If you want to be able to use the command for those replays or demos, you need to copy them from “…/dota/replays” to “…/dota”, meaning in the previous folder. Here’s how replays look after I downloaded this single replay:
——————————————————
Ok, let’s continue. So, until now we learned how to enable the console, how to find a replay and how to load it with “playdemo”, is that right? I think it is, so let’s continue.
The “startmovie” and “endmovie” commands
——————————————————
Now I’m gonna show you the basics of recording in source. First you need to type “host_framerate 30” without the apostrophes in the console. Open the console with ~ type it and press enter.
——————————————————
——————————————————
Ok now go 2 or 3 seconds before the scene you want to record, open the console and type “startmovie name” without the apostrophes, for “name” you can put whatever you heart desires, in this guide I used “test”. Right after you close the console it will start to record, you will notice of course that the fps suddenly dropped, but don’t worry, it’s only normal.
READ: You can bind this and the other command to a key, so you don’t have to write it in the console, but you can see that explained in the end in the section “Optional things”
Ok, now after you’ve recorded the needed time, ex: the scene you wanted of that epic team battle, open the console again and write “endmovie” without the apostrophes. After you close the console you’re done. But that’s not all.
——————————————————
——————————————————
“Where’s the movie?” you may ask. Well, we don’t really have a movie yet. Open your“Steam/steamapps/common/dota 2 beta/dota” and look what waits in there. Mindblown? Hundres of picture files are waiting for you to make them into a movie. Nice, huh? Whatever, so every single of those pictures represent a frame. As you can see on the picture below, 531 pictures are roughly 1.3gb and you’re gonna need to double this when we make the video, so that’s something like 2.6gb for 16 seconds of video, not very nice, but when you get to the result, you’ll see that it’s worth it.
——————————————————
Virtual Dub
——————————————————
So what do you do with those pictures? Well, you need some kind of a software to glue them into a movie file. I used VirtualDub, which is free.
VirtualDub.org
I’m gonna explain now how to make the video file using virtual dub.
First, download and open it. Then select all the pictures you have of your scene and drag and drop them into virtual dub.
——————————————————
——————————————————
After that click on Video>Frame rate.
——————————————————
When you open that, select the second option: “Change frame rate to” and type 30 in the box, that’s the framerate of our video. And it should be 30, don’t make it less or more, it will make the video different, than normal.
——————————————————
Next in the same menu click on compression and be sure to select uncompressed, that way, the video will be in full quality, thus making it roughly the same size as all the screenshots.
Ok, we’re done with the settings, now we’ll finally save the movie. Click on File>Save as AVI, write the name and save, then wait for the program to render it and watch it, that’s it, the final step, yay. Damn I’m tired, are you?
I’ll show you now how to compress(encode) videos with H264 which will drastically reduce the file-size to your liking. Quality differs with file-size but something like a Mb or two for a second is good. If you have saw the comparison posted in the begining you’d have seen that H264 produces 12 times smaller video compared to fraps and 64 times compared to uncompressed. Anyway, let’s begin, first you have to download the codec:
Now, I don’t know what x264 or H264 means, for me it’s a decoder/encoder that is a little better than xvid or any other and I just found it out when writing this guide, I found out about it when watching some ripped hd movie, it was encoded with this at a bitrate of 8378kbps, which translates to 8378 kilobites per second, or 1000 and something kilobytes, which we all use. Basically it’s something like ~1MB per second, which is perfect for 720p.
So after you downloaded it, you install it, and if you’ve had vdub opened, restart it. Now when you click on “Video>Compression” you should have x264vfw…. on the list, select it and click configure on the right:
Now another window should pop out, don’t worry that’s how it’s supposed to be. Look at carefully at the picture below and copy all the settings so they are like mine, the number 8378 is the bitrate we are using. If you want you can mess however you want with the settings, just remember to have “Output mode” on VFW and VirtualDub hack checked.
This image has been resized. Click this bar to view the full image. The original image is sized 654×578. |
Now save as avi and you’re done.