4500+
Great Links

VirtualDub and AviSynth FAQs

Related Links

Click for links about:

Version 0.11
Copyright © 2008-2009 by Zack Smith.
All rights reserved.

Q: What is a decent free video editor for Windows?

VirtualDub is a useful but inadequate tool for doing simple edits of videos. Many people pair it with AviSynth, which is a scripting language and tool that permits more complex operations.

It's available at VirtualDub.org.

Q: What does VirtualDub allow?

It is a basic tool that lets you open a video for editing, append another video to it, cut and paste segments of video, apply various filters, change the frame rate, compress the video, overlay sound, and so on.

Many filters are built-in to VirtualDub, for instance one that converts a color video to B&W; another that lets you change brightness and contrast. Others are free and available for download.

Q: What does VirtualDub not allow?

A couple of limitations come to mind:
  • VirtualDub does not do transitions on its own. For those you will need to use AviSynth. An example is fading from one scene to the next.
  • VirtualDub does not read or write MPEG files-- although there is a variant of VirtualDub that supposedly does.

Q: What is Avisynth for?

Available from AviSynth.org

It's another tool that expands what you can do with VirtualDub. It lets you use .avs scripts that you've created, which can accomplish a range of tasks. These scripts are created using a text editor. Some things you can do with .avs scripts:

  • Convert many photos into a time lapse movie.
  • Pull together large numbers of segments into an entire film effectively using an .avs script as the "makefile".
  • Do simple transitions between video segments e.g. like dissolve.
  • Put two videos side-by-side.
  • Add padding on the sides of a video.
They are a little tricky to create, but in the end they make life easier.

Q: How do I remove shaking & jittering from video using VirtualDub?

Setting up:

  1. Download the VirtualDub zip file.
  2. Use Windows to extract its files to the desktop.
  3. Open the folder containing VirtualDub. Right click on the VirtualDub application and create a shortcut for it. Drag the shortcut onto the desktop.
  4. Download Deshaker.
  5. Use Windows to extract the file Deshaker.vdf to the desktop.
  6. Move that file into VirtualDub plugins directory.

Using it:

  1. Double-click on your VirtualDub shortcut that is on the desktop.
  2. Open a video file in VirtualDub.
  3. Click on the pulldown menu Video; then Filters.
  4. Add the filter called Deshaker.
  5. A window will come up allowing you to alter settings. If you have Vista you will need to change the log file location to the desktop. Then close that.
  6. Click on the File pulldown menu. Then Save As AVI.
  7. Select a name and save the video. This will do some processing called pass 1 to determine how shaky the video is.
  8. When this has completed click on the pulldown menu Video; then Filters. Double click on Deshaker.
  9. The window for configuring Deshaker will come up.
  10. Click on pass 2.
  11. Select "Extrapolate colors to border".
  12. For "Edge compensation" select None.
  13. Click OK.
  14. Click on the File pulldown menu; then Save As AVI.
Note that you can also select to compress the resulting video. For that you will need to select File, then Compression, then choose a codec from the available choices. The best compressor is not included with Windows and is called Xvid (see below).

Results of using Deshaker

Here's a link to a YouTube video that someone produced showing a side-by-side before and after deshaking a video: Youtube deshaker demonstration.

Q: Which video format compresses the best and retains decent video quality?

Xvid. It compresses by a factor of 10. You can download that from Doom9 or from xvid.org .

Q: Which video format compresses but does not have any loss of video quality?

HuffYUV, available from HuffyUV page formerly at Berkeley. It compresses by a factor of 2.

Q: How can read in an Xvid or Divx video? I am getting an error that says I need a Video For Windows (VFW) compatible codec.

This occurs with older versions of Windows. Try ffdshow from Sourceforge.net. Or, ZoomPlayer includes ffdshow so installing that may help VirtualDub. You should also download the Divx codec.

Q: How can I use VirtualDub to create a video effect of zooming in?

There is a Zoom plugin filter.

Q: How can I use VirtualDub to create a video effect of panning?

There is a Pan plugin filter.

Q: How can I use VirtualDub to create a video of many frames from one still photograph?

You'll need to create a tiny AviSynth file for this. To show by example, if you want to generate a movie of 240 frames using VirtualDub, first create an Avisynth AVS file that contains this:
ImageSource("MyImage.jpg", end=240)

Q: How can I create a dissolve transition between 2 or more clips?

Create an .avs script like this:
c1 = AviSource("clip1.avi")
c2 = AviSource("clip2.avi")
c3 = AviSource("clip3.avi")
return Dissolve(c1, c2, c3, 30)
The above does dissolves at the junctions of c1 & c2, and c2 & c3, and the duration of the dissolve is 30 frames.

Q: How can I create a video from many photographs e.g. a timelapse film?

Let's say you have 100 image files, numbered 0001.jpg throug 0100.jpg. To generate a four-second, 25 fps movie from these, create an AVS file that contains this:
ImageSource("%04d.jpg", 1, 100, 25)
Lanczos4Resize(720,480)
Note, the resize is typically required since most people shoot higher-resolution photos than they would need for a video.

Q: How can I add an audio soundtrack to my video?

If the audio is in WAV format, it's easy.
a1 = WavSource("myfile1.wav")
a2 = WavSource("myfile2.wav")
a3 = WavSource("myfile3.wav")
soundtrack = a1 + a2 + a3

final_video = AudioDub(vid, soundtrack)
There is a way to use MP3 files, however I've found that it crashes. It is better to simply convert your audio to WAV.

Q: How can I convert audio to WAV?

Use BeSweet and BeLight. You can download them from Doom9.net . First extract BeLight and then extract BeSweet into BeLight's directory. You actually run BeLight, which is the front-end.

Q: How can I convert from one video format to another?

Using VirtualDub

You can use VirtualDub to read in a video that's in one format, then set the video compression to something else, then use "Save As AVI" to write it out in another.

Using FFMPEG

If you need to create a VOB file, you can download the utility FFMPEG. I personally use this under Linux, not Windows. Under Windows you should download the GUI version of FFMPEG, called WinFF. However, using this tool you can convert:
  • AVI to M2V
  • AVI to VOB
For instance:
ffmpeg -sameq -i input.avi output.vob

Q: I am getting a strange audio codec tag error

If you don't have the right audio codec installed you will get an error. The codecs are as follows:

  • Tag 2000 = AC3
  • Tag 674f = Ogg Vorbis
  • Tag 161 = Divx
  • Tag 55 = MP3

You can obtain the AC3 decompressor here.

Links

Valid HTML 4.01 Transitional

eXTReMe Tracker

Google ads on this webpage now use Google's interest-based advertising.