Windows Media 8 Encoding
Introduction to Frameserving
The Windows Media 8 Encoding Utility (WM8EU) only accepts AVI files with uncompressed 16-bit audio as the input. It does not accept video from Avisynth or the standard VirtualDub frame server. Fortunately, you can use VFAPI to feed (frameserve) unsupported video to the WM8EU.
If your video consists of a single AVI file with uncompressed 16-bit audio, you may skip to the section entitled "Encoding with the Windows Media 8 Encoder GUI". If your video consists of multiple files (e.g. a segmented AVI), is being frameserved through Avisynth or VirtualDub, or is in another format not supported by the WM8EU, then you should continue reading and following the instructions to frameserve your video to the WM8EU through VFAPI.
To use VFAPI, you need to download and install Avisynth, VFAPI,
and the ReadAVS VFAPI plug-in. These programs are available at my Software
page. You need all that software because we are going to take your video through a
number of steps before it reaches the WM8EU. Specifically, the video will be served like this:
Source Video -> Avisynth -> VFAPI Virtual AVI ->
WM8EU
Frameserving Step #1: Avisynth
We'll begin by creating an Avisynth script, which you will eventually open in the VFAPI Reader Codec program. Using Avisynth is necessary because VFAPI cannot directly open an AVI.
What Avisynth does is use a special text file on your computer to represent a video. Instead of telling a program to open your source video file(s), you tell it to open the special text file (*.avs). Avisynth then intercepts the program that is trying to read the special text file and redirects it to your actual video file(s).
Click on the following link to download a special text file that I created for you to use with Avisynth:
Extract the contents of the .zip file to the folder containing your processed video file(s).
Now run Notepad, select File -> Open, and open the 'avisynth.avs' file. At the top of the file, I have included an explanation for configuring the avisynth.avs file. Follow these instructions, save the file, and exit notepad. For more information about Avisynth, see my Avisynth page.
Frameserving Step #2: VFAPI
You will now convert the Avisynth (AVS) file to a virtual AVI that can be fed to the WM8EU.
1) Run the VFAPI Reader Codec program (VFAPIConv-EN.exe). It's located in the "Reader" subdirectory in the place where you unzipped the files for VFAPI.
2) Click on the "Add Job" button, navigate to the folder containing your Avisynth script file (*.avs), and Open the project file. (If the file won't open, make sure you've properly installed the ReadAVS VFAPI plug-in.)
3) A window should appear that looks like the following:

The default settings with everything checked is what you want, so just press OK.
4) Now that you are back at the main VFAPI window, press the Convert button. A percentage should appear in the Options column. The percentage will increase towards 100% as VFAPI goes through your video.
5) When the conversion is finished, you should have a newly created VFAPI AVI on your hard drive. Be sure to click the Exit button to close the VFAPI Reader Codec program before continuing.
Encoding with the Windows Media 8 Encoder GUI
To simplify the encoding process, we will be using the Windows Media 8 Encoder GUI, which can be downloaded from my Software page.
1) Run the Encoder GUI (WM8EGUI.exe) and click on File -> Open Source. Browse to the folder containing your source AVI or VFAPI AVI (if you made one) and open that AVI.
2) Click on File -> Select Output, choose a name and location for the output video, and press the Save button.
3) Now click on the button labeled "More Options" to access all the settings for Windows Media 8. The screen then should look something like this:

4) The first thing we'll configure is the Encoding mode. For the highest quality, you'll want to choose one of the VBR options. One-pass VBR allows you to select a quality level, and the encoder will automatically use the bitrate necessary to maintain the chosen quality level. Two-pass VBR lets you select a specific bitrate, and the encoder will try to maintain constant quality throughout the video while using the chosen bitrate as the average bitrate for the entire video. Personally, I prefer one-pass VBR because it encodes twice as fast as two-pass VBR and you don't have to worry about picking a specific bitrate to get the quality you want.
If you want to encode with one-pass VBR, set the Encoding mode to "VBR, one pass". Then you have to choose a Quality level from 1 to 100. Please note that certain groups of adjacent numbers will all produce the same output quality. This means that you may have to increase/decrease the Quality slider by more than one number if you want to affect the output quality. To assist you in choosing a suitable quality level, I have made the following table, which contains my subjective opinion:
| Quality range | My opinion of the video quality |
| 75-78 | |
| 79-82 | |
| 83-85 | Even lower |
| 86-89 | A little low |
| 90-92 | Decent |
| 93-94 | Good |
| 95-96 | Even better |
| 97-99 | |
| 100 |
If you want to encode with two-pass VBR, set the Encoding mode to "VBR, two pass". Then you have to select a bitrate for the encoded video. Based on the quality of the source video, the resolution of the source video, and your desired output quality, the bitrate you should choose will vary greatly. Some suggested values are 300000-550000 bps for a 320x240 video, 550000-850000 bps for a 512x384 video, and 850000-1300000 bps for a 640x480 video.
5) Next you should set the Keyframe distance, which sets the time in seconds between keyframes. Decreasing the Keyframe distance can improve the seek time when playing your video, but it can also increase the file size and CPU utilization. I recommend sticking with the default of 10 seconds.
6) In most cases, you shouldn't have to alter any other settings on the Video tab. If you wanted to crop, preprocess, or alter the frame rate of your video, you'd be better off doing this in VirtualDub. Also, make sure you don't touch the Presets option because it will override your custom encoding settings.
7) Now click on the Audio tab, where we will choose the audio settings for your video. Everyone's ears are different, so your choice for the audio mode is highly subjective. Here are some tables that provide my opinion of the audio quality at different settings:
| Audio mode | My opinion of the audio quality |
| 32_44_1 | Fairly low |
| 48_44_1 | A little low |
| 64_44_2 | Good |
| 80_44_2 | Very Good |
| Audio mode | My opinion of the audio quality |
| 40_32_2 | Very low |
| 48_32_2, 48_44_2 |
A little low |
| 64_44_2 | Fairly good |
| 80_44_2 | Very Good |
If you don't want your video to have an audio track, select the option at the bottom of the list, which is labeled "0= 0 (video-only)".
8) The Selection tab enables you to encode a specific portion of your source video. However, you should usually do this kind of editing with VirtualDub or another program before encoding. Therefore, you shouldn't need to do anything on the Selection tab.
9) Next, click on Tools -> Options and go to the Content Description tab. There you can enter the Title, Author, Description, etc. of your video clip.
10) While still in the Options window, go to the Advanced Encoding tab. There you can select which version of the Windows Media Video (WMV) codec you want to use. In general, using the WMV 8 codec will provide a slightly higher quality than the WMV 7 codec at identical bitrates. However, there are a few situations in which you might want to use the WMV 7 codec:
When you have chosen your desired WMV codec, you can press the OK button to exit the Options window.
11) Now everything should be properly configured. You can hit the big button labeled "Encode" to launch the WM8EU and begin the encoding process. A series of dots will slowly appear as the encoding progresses towards 100%. If you're encoding with two-pass VBR, a separate progress indicator for the second pass will appear after the first pass is complete.
12) When your video is finished encoding, be sure to test it out with Windows Media Player. If you're not satisfied with the results, you can go through this page again and make changes as necessary.
Congratulations, you've made it through my video guide! Be sure to let all your friends see the wonderful video you've created.
If you have further questions/comments/suggestions, please post them in my Message Boards.