Wednesday

How To Save Any Video Into A Format For Use In Sony Vegas





Although I have tried many Video Editing programs, I always come back to Sony's Vegas video editing application. I own Sony Vegas Movie Studio HD 11 at the time of this post and have tried and worked with older versions including Pro, in the past. I always enjoy the flexibility of the Non-Linear Editing and the options that the program provides for all levels of users, despite it's learning curve. It is a powerful program and due to it's method of operation, it is made to handle certain types of formats better than others. This results in faster and easier processing and editing. It also results some slight strictness in formats that it can import (be read/input into Vegas).

One of the problems many people have with this program is when it comes to importing certain types of video. In Sony's Vegas video editing applications, clicking on such a problem file will not result in the program giving a preview or reading the file's attributes properly (the size and codecs within the video/audio file), it results in just the name of the file as it is, just below the built-in Explorer window pane. This post is how to take any format of video, from any source, and make it usable or available for import into Sony Vegas (Movie Studio/Pro) for editing.

There are many people that think they know what they are talking about, saying things like, "you can't use this-or-that format" or "that format is a distribution format" or "you can't import that into vegas" and other elitist and snobbish comments. These people are not being very helpful however and don't explain the issue fully - most likely because they do not understand it properly and only know how to do the one thing that they use Vegas for and have no experience with anything else.

There are formats that are indeed not listed in the Official Technical Specifications at the Sony Website for Sony Vegas. Here is the list that is given for Sony Vegas Pro 10:
Opens: AA3, AAF, AIF, ASF, AU, AVI, BMP, BWF, CDA, DIG, DLX, DPX, DV, EXR, FLAC, GIF, HDP, IVC, JPG, M2T, M2TS, MOV, Sony MXF, MP3, MP4, M4A, MPEG-1 and MPEG-2 video, OGG, OMA, PCA, PNG, PSD, QT, R3D, SFA, SND, SWF*, TIFF, TGA, VOX, W64, WAV, WDP, WMA, WMV
While many of the formats people ask about, such as FLV (Flash Video, from YouTube for example) are not listed, there are actually many "distribution formats" (compressors that are used in the final step before giving out a video to others to make it smaller) that people say 'will not work' in there, such as WMV (Windows Media Video, from Windows Movie Maker). Clearly, they can be used/imported into Vegas. There are many ways to do this, many outside the scope of this post, but I will explain some video concepts and why there are additional formats that can be imported into Vegas which are not listed.

Firstly, one issue that seems to confuse many people is the concept of Containers versus Codecs
 I will explain it here:

- A container, when talking about digital video, is merely a 'holder' of a video (and can hold audio and other things as well) inside a file. That file can have multiple file name endings (suffixes, such as FLV or WMV)
- A codec is a compressor/decompressor (the processing code) of a specific video format (type of file) that can be held within any container

What these mean, is that a container
(for example AVI (Audio Video Interleave) usually used in the Windows Operating System) 
can have many types of codecs
(for example AVI can hold inside it XviD, DivX, Mpeg-4 (MP4) and more)
inside of it. 


The file name ending (suffixes such as .wmv, .flv, .ogm) usually describes the type of file format (the codec used) inside the container. For instance, a file ending in ".wmv" (a Windows Media Video container) will usually have video inside that has been processed with the Windows Media Video codec inside. 

It does get more complicated somewhat, where you can rename certain containers into others (such as renaming DVD Video .VOB files into .MPG, as both containers can hold the MPEG-2 (Motion Picture Experts Group Part 2) codec inside, but it is actually more complicated than that, as each codec and container has it's own standards and programming limitations that it must adhere to inside to remain properly readable. Also, most codecs are processing the video differently with a different set of rules and operations, so you cannot just go around renaming all containers into other random container names.

If we ignore the container names (the file name endings of .asf, .flv, etc) and just talk about the codecs (the compression used) inside the file, it's easy to always remember that one codec can always be changed into another codec. That is, any format can be converted into another format.
For example, a WMV format video can be imported into a program (that can read WMV) and can be exported as an MPEG2 format (if MPEG2 is what is desired and the program can output it as a file type, format and container).
This allows us to do things such as take an FLV file and convert it so that we can put it on a DVD that can be read in a dvd standalone player or game console that can read dvds. This is video conversion.
All types and formats can be converted into other formats (as long as the program we are using can read the initial input format, the Source Video (or Audio).

This leads us into how we can take any video and import it into Sony Vegas. Although there are additional ways to do it, the easiest way to get any video into Vegas for fast and responsive editing, is to convert it.

The most usable format for Vegas (any edition) is Uncompressed Video (video that is not compressed). This means that the video (and audio if desired) is processed very little in any way that attempts to make it smaller and therefore give away some of the quality in exchange for a reduced file size.

Using Uncompressed, the video will look almost exactly the same as the source quality/sharpness/color, but the file size will be much much larger. A 20GB container of Uncompressed Video will only hold minutes worth of video and audio, for example. Uncompressed is the easiest way to go however, as most video utilities and conversion programs can output video as Uncompressed, with no need for any other software (or codecs) to be installed on your system (other than to read/open/import the source video itself). Uncompressed is usually only viable for small clips however, unless you have the harddrive space to devote to decompressing your videos fully (literally, taking the compression attempts to make it smaller out of it) into Uncompressed formats.

Another compression format, a 'light compression' or 'mildly compressed' format, is MJPEG. Used frequently in digital cameras, MJPEG at it's highest setting ('Quality 100 percent' or 'Quantizer 1') also has high quality output and is easily imported into all of Sony's Vegas products. Although it is not listed officially in the specifications, it is an older format that is handled almost natively by all applications available today, including Vegas, without any special conversion (other than converting your source video file into MJPEG). It is a fast, responsive, high quality format that easily imports into Vegas and has much smaller file sizes than straight Uncompressed. A 1GB container of MJPEG video will hold a couple minutes of video, but when compared to the 10-20-plus gigabytes required by Uncompressed for the same amount of time of the same video, it is clearly a more usable format for compiling a collection of videos on your system, prior to importing them into Vegas to work with. If you have not used MJPEG before, I highly suggest trying it out.
(MJPEG is available in the free FFDSHOW compilation of video and audio codecs and codec packs using the FFDSHOW codec translation)

Another format that Sony's Vegas line works well with is the Blu-Ray Disc Audio Visual (BDAV) container format (usually ending in .MTS or .M2TS) which can contain the codecs MPEG-4, H.264 AVC, MPEG-2 and more inside of it. Rendering to MPEG4, you may find that Vegas defaults to a standardized high bitrate .M2TS output file. With the high-quality Advanced Video Coding capability, you can have very high settings within an .m2ts file that is capable of being imported into Vegas for editing.

Some of the free utilities that can be used in Windows to convert video for easy import into Vegas are:
Using these free utilities (or any other program that you prefer), converting your source video into Uncompressed is the most reliable way to import any video for use in the Sony Vegas line of video editors. After that, other 'only slightly compressed video' formats such as Huffyuv and MJPEG are recommended.

I have found that Avidemux and even the trusty Virtualdub sometimes run into 'problem videos' that will not open (or be read incorrectly, such as being 'seen' as 320x240 when they are not). A solution for these is the previously mentioned Xmedia Recode. I have not yet run into any video that this wonderful freeware program cannot open and save in a format desired, such as the above-mentioned MJPEG, Huffyuv, MPEG-4 AVC and more (don't worry, the author is German but it is available in English from the author's website). I am not affiliated in any way or degree with the author or this application, I am merely a fan of it, choosing it over and above, after trying many others (such as Virtualdub, Mediacoder, Super, Xvid4Psp, Avidemux, Winavi, TMpeg programs and more over the past couple decades).

Remember, you can use other formats in Vegas, even formats that are not listed in the official specifications (such as DivX or XviD), but these formats are more highly compressed (more processing has been done on them, trading off some quality for a far smaller file size) and with larger Groups Of Pictures (GOP's, frames that are compressed in a way that only the changes between each are kept track of, so that each frame is dependent on the frames in front or behind it). These formats require more background processing as Vegas decompresses them on-the-fly in the various tracks in your project to show you the compressed frames as you work with them. This slows down the responsiveness of Vegas and makes your overall work flow slower (although it does work, do not listen to self-proclaimed 'experts' on forums that claim that it does not work). I have done it and seen it done many times in the past, usually due to time constraints - it merely causes extra processing time and some slowdown in your work flow (it may also require additional steps such as installing additional codecs or frameserving, but these topics are for another article). If this slowdown in work flow is undesired, then Uncompressed or MJPEG, Huffyuv and other 'lossless' or 'mild compression' formats is the way to go for Vegas, giving you the ability to use/edit any video that you may have while maintaining quality and responsiveness.

That's it!

  
 Addendum:  There seems to be an attitude going around forums everywhere, that Codec Packs (compilations/collections of various helpful codecs, so that your system can handle a multitude of video formats without any problems) are to be avoided. This attitude and stigma usually comes from persons who have no idea what they are talking about, or only know how to do the one thing they know how to do in Vegas (or use Vegas and have no experience with any other applications or video formats). There is nothing wrong with Codec Packs and I personally have used them for decades without problems (some unhelpful snobs who state that it will 'wreck your Windows' simply know nothing and have no experience in these matters). Using many different video formats (especially when dealing with foreign hardware or video) sometimes necessitates the usefulness of a Codec Pack, which allows the handling of many different video formats not natively handled by Windows and common applications. Many Codec Packs will also have additional capabilities other than just translation of differing video formats, offering features such as multiple subtitle handling, frameserving into video editing applications ('translating the video on the fly' so that a video editor can use the video 'as is') and more. They are nothing to be afraid of (unhelpful and unknowledgeable people will say to avoid anything new and useful at first) and greatly assist in opening the many different formats of video that you may encounter. Feel free to use Codec Packs such as K-lite Codec Packs, The Combined Community Codec Pack and others without fear.  


If you liked this post, buy me a cup of coffee :) (You can even use your credit card to donate a dollar with PayPal and it does not give out your information to the person you are sending it to). Thanks and check back in once in a while to see more tutorials on How To Save Things!


No comments:

Post a Comment