Google
Web         Gaudiya Discussions
Gaudiya Discussions Archive » TECH ISSUES
PC problems, recommended software, tips and tricks, coding and so forth. Things that make your life in the cyberspace easier.

FAQ - Capturing and Editing Videos - Moving your videos to your PC



Madhava - Fri, 28 May 2004 02:20:04 +0530
Here's a simple tutorial I put together for a friend who wanted to transfer videos from his DV camera to his PC. The tutorial is equally applicable if you have a VHS tape and a video card with a TV-in, just select your video card's signal as the source instead of the the DV camera. The tutorial is written for VirtualDub, a free (open-source) and excellent basic video editing program.

= = = = = = = = = = = = = = = = = = = = = = = = = = =

CAPTURING VIDEOS WITH VIRTUAL DUB

This section deals with the process of capturing the video. If your input source is a DV camera and you're using FireWire as the source, please see the notes on the alternative method of capturing.

1. Download Virtual Dub from http://www.virtualdub.org/ and unzip the file.
2. Open the program by clicking on the VirtualDub.exe file. Activate the source of your video.
3. Select File > Capture AVI.
4. Hang on for a moment, a new view will open. Select File > Set Capture File, then select a name and a location for your file. It is a good idea to put this somewhere where you have plenty of space, as we are going to initially capture this as uncompressed video, which takes up a lot of space. (One minute of raw RGB video takes up ca. 400MB.)
5. From Video > Source > Capture Source, make sure that your desired video source selected as the source.
6. Under Audio > Windows Mixer, ensure that you have selected your source is selected as the audio source as well.
7. Click Video > Preview. You should see the image from your source on the screen.
8. Click Capture > Capture video to start capturing the video into the file you selected for the output. You will see on the screen whatever is being captured. Press play on your source (or otherwise get it going) to start the incoming video stream.
9. Once you've captured enough, click again on Capture to stop capturing the video. Your video has now been saved into the file you specified.
10. Click File > Exit capture mode.

You can find VirtualDub's documentation for capturing video here.


ALTERNATIVE METHOD FOR CAPTURING VIDEO

Since VirtualDub uses the VFW (Video for Windows) capture driver, and as most firewire devices do not have the required driver, we are going to use DVIO (Digital Video In & Out), an excellent and extremely simple utility that will capture your DV source as DV Type 2 AVI.

1. Open DVIO.exe
2. Click "File", set the target file to which you'll save the video.
3. Click "Capture Video from Camera".
4. Click play on your DV camera.
5. Stop capturing once the desired part of the video is captured.

One minute of video captured as DV Type 2 will take up a bit over 200 MB of space.

You can download DVIO from its home page, or otherwise from a post to which it is attached later on in this thread.


OPTIMIZING CAPTURED VIDEO

Having a 15 minute video take up 6GB of space is obviously not a good idea in the long run, so we need to trim it down.

1. File > Open video file, select the file you just captured.
2. Video > Compression, select XVid MPEG-4 Codec, click "Configure". Select 3000kbps for the bitrate, that should be well enough if the video needs to be further processed in the future.
3. Audio > Full processing mode. Audio > Compression, select Lame MP3, 44100Hz, 192kbps CBR, Stereo. Depending on the sampling rate of the source audio, you may need to convert it to 44100Hz before you can convert it to mp3. To do this, go to Audio > Convert and select the option there. There you can also select to convert stereo to mono if necessary.
4. File > Save as AVI. Now select the target file.
5. Wait for the video to be processed. This may take a good while. To make it a bit faster, you can turn off the display of both input and output video from the box that pops up once the saving begins.
6. You're basically now done with the video. If you need to clear up space on your hard drive and delete the original uncompressed video files, ensure that the new, smaller files you produced are what they are supposed to be. Files with the settings used above take up space as follows: (((3000kbps video + 192kbps audio) / 8) * 60 sec) / 1000 = 23.94MB per minute.
7. When you produce content for the internet, it is a good idea to decrease the quality to make the files smaller. Even settings between 500kbps and 1000kbps produce a decent quality, while the space consumption decreases substantially. For example, in a file with 750kbps video quality and 128kbps audio quality, one minute of content would take up only 6.6MB. In video content where only speech is recorded, the audio may be downgraded even further down to 64kbps in such files. More details on this later on.


EDITING VIDEOS

If you want to cut out parts of the video, or save only a small bit from the middle of the video into a separate file:

You can mark the beginning and the end of a passage using either the Home / End keys on your keyboard, or otherwise the black markers on the right edge of the buttons at the bottom of the screen. Mark whatever you wish, and if you wish to delete it, hit the Delete-button on your keyboard. If you wish to save a part of the video into a separate file, select the relevant part and select File > Save as Avi, that will only save the selected part.

You can also play around with the filters available under Video > Filters.

With them, you can for example adjust brightness, contrast, saturation and so forth, or crop the video files into different sizes. After selecting a filter, you can preview it by clicking on the third button on the left at the bottom of the screen. There are two play buttons there, the first one will play the original on the left side of the screen, the second one will preview the output. Remember, the output video may be showing slower than real time if you have complex filters selected.

It is a good idea to edit the video before you optimize it into a smaller size.


MAKING A VIDEO SMALLER

If you want to make the video smaller, there are two things you may want to do, namely (1) shrinking the physical dimensions of the video and (2) increase the compression. If you intend to compress the video very much (below 300-400kbps), it is a good idea to also shrink its physical dimensions if the original is big (say, 350px or more in width). Otherwise step one is unnecessary.

1. Shrink the physical dimensions of the video
a) Go to Video > Filters > Add.
b) Select Resize > OK.
c) Set the new width and height. For example, if your original video size is 640x480 and you want to make it twice smaller, you'd enter 320x240 there. The two common picture aspect ratios are 4:3 (regular PC view) and 16:9 (widescreen). To find out the original dimensions of the file (and lots of other handy information), see File > File information.
d) Click OK. The filter is now activated and will be applied next time you save the file.

2. Increase the video and audio compression
a) As described earlier in the tutorial, decrease the compression of the video. For example, if you have a 10 minute (600 seconds) video you'd like to have available in 20MB (20.000kiloBytes = 160.000 kilobits), you have 160.000 kilobits for 600 seconds, in other words 266.66 kbps. Set the audio compression to 64kbps and the video to 200kbps and you'll have approximately the size in MB you need.
b) Of course one setting doesn't fit all, and for example in audio-intensive content you may need to keep the audio at 128kbps, and if the video has lots of details you may need to have the video kbps set higher.
c) You may need to lower the sampling rate of the audio to make better compression possible. To do this, go to Audio > Convert, and select for example 22.050Hz. Now the Audio > Compression section should automatically display other, smaller options under the Lame MP3 section.
Madhava - Sat, 03 Jul 2004 03:42:16 +0530
You need the XVid-codec to compress the video according to the tutorial. Download and unzip the file. Click on the XviD_Install.exe to install the XviD-codec.
Attachment: XviD_Install.zip
Madhava - Sat, 03 Jul 2004 03:55:39 +0530
And here's the Lame ACM MP3 encoder. Download and unzip the file. Right click on the LameACM.inf file and select "Install".
Attachment: lame_acm.zip
Madhava - Fri, 09 Jul 2004 20:50:47 +0530
Here are some handy tools. (I will be adding more to this slot in the future.)

AviCodec
With this tool, you can check out the audio and video codecs of any media file, see the compressions and a number of other useful details on the video. It also shows whether you have the codecs necessary installed or not.
http://sourceforge.net/projects/mediainfo/
Madhava - Sat, 14 Aug 2004 04:52:22 +0530
Here's the file for DVIO (see: Capture / Alternative Method for Capturing Video).
Attachment: DVIO.zip
Madhava - Sun, 22 Aug 2004 05:22:57 +0530
Here's an excellent site with loads of (often free) tools for download, along with other varieties of helpful content:

http://www.videohelp.com/tools