Frameserving from Vegas to Nero Recode:

Delivering HD on DVD

Mark Dileo/VASST Instructor ©2005 Sundance Media Group

HDV:What You NEED to Know

 

 

In this tutorial, Mark Dileo of VASST explains how to frameserve HDV from Sony Vegas to Nero Recode, a new application and codec that can be easily used to deliver HD for settop or computer playback. You'll need to download:
-Debugmode's Frameserver
-Nero Recode
-And you should already have Sony Vegas 5d installed.

(Links to downloads found at end of article)

NeroVision Express 3
Nero Recode is one of the tools included in NeroVision Express 3, which itself is part of the Nero 6 Ultra Edition package.  NeroVision Express 3 includes applications for video capture, DVD authoring, DVD burning, image editing, and a media player called Showtime 2 that handles a large variety of audio and video formats including MPEG-4 and HDV transport stream (*.mt2) files.  Recode allows you recompress a dual layer DVD so that it fits onto a single layer disc with virtually no loss in quality.  Recode also makes it very easy to discard parts of a DVD or combine movies from two or more DVDs to make a compilation of your favorite DVDs.  Of course Recode will only work on non-copy protected content and you must own the copyright in order to legally copy or backup any media.

Besides managing DVDs Recode also includes a very high quality MPEG-4 compressor with which you can “recode” DVD content and video files to MPEG-4.  Recode will accept just about any format video file including HDV transport streams and, to my surprise, frameserving signpost files!  If you don’t know what frameserving is don’t worry, just read on, it’s really not a difficult process.

The fact that Recode accepts signpost files means that it’s possible to frameserve video from your favorite NLE to Recode for encoding to MPEG-4 Layer 10.  More specifically, Recode encodes to MPEG-4 part 10, otherwise known as H.264.  H.264 is a very high quality compression scheme that allows for higher compression rates than MPEG-2 while maintaining high video quality.  H.264 will be an accepted format for the upcoming Blu-Ray disc format so this format will be very important in the near future.  As always, there is a price to pay for high compression ratios and high quality; namely long encoding times and high processor overhead for playback.  Part II of this article will discuss encoding performance of Recode and playback performance of MPEG-4 encoded files with Nero Showtime 2.

Installing the Recode
First you’ll need to install NeroVision Express 3 on your system.  You can download the trial version of Recode here:  http://www.nero.com/us/neroue-prog.php Nero 6 Ultra Edition is a comprehensive CD burning application that includes NeroVision Express 3 and may be purchased via download for $70 or $100 for the retail bundle.  Nero has long been known as a top choice for all types CD/DVD burning and backup tasks.  Now with the inclusion of NeroVision Express 3 it’s a complete MPEG-4 encoding and playback solution.  Nero 6 Ultra Edition includes so many useful applications that I won’t even begin to list them here.  In order to install all of the components of Nero 6 Ultra Edition 6 components must be downloaded and installed.

Installing the Frameserver
You’ll also need to install the free DebugMode frameserving application which can be downloaded here:  http://www.debugmode.com/frameserver/  A frameserver allows for the delivering, or serving of video frames from your NLE to an encoding program such as Recode.  Frameservers use a proxy or signpost file as a means of linking the two applications.  The nice thing about frameserving is that the encoding application receives the uncompressed stream from the NLE for optimum encoding results.  Without a frame server you’d have to render out the entire project in an uncompressed format and then encode it in Recode.  Not only will this take longer, but it will also tie up quite a bit of hard drive space if you have a long project to encode.

I should also mention that other video and audio applications such as Virtual Dub will generally accept signpost files for frameserving purposes.  This allows you to effectively work “through” one NLE to another.  You can think of the signpost file as a link between the two editing applications.

After downloading the frameserver unzip it and run “fssetup.exe” to install the frameserver application.  The only thing you need to do is make sure you select the NLE(s) you plan to frameserve from.

Starting the Frameserver in Vegas

Although the frameserver can be used in a variety of NLE’s, this tutorial will use my preferred NLE, Sony Vegas.  Open a Vegas project, select File>Render As and in the  “Save as type” dialog select “DebugMode FrameServer (*.avi).  It really doesn’t matter what you name the signpost file but I like to call it “signpost.ave” so there is no doubt as to what it represents.

 

Make sure you select “Write audio as PCM samples in signpost AVI” if your project includes audio.  Then select the colorspace of the encoding application.  Since alpha channel information isn’t used during encoding (RGB32) and Sony Vegas uses a RGB colorspace select “RGB24.”

Press “Next” to start the frameserver; the signpost file is now “active,” which means that any frame requests made by the encoding application will be fulfilled by the frameserver.  Besides sequentially serving frame-by-frame you can even scan around the project in the receiving application or enable two-pass encoding.  Keep in mind there will be some delay due to the frameserver application overhead.  The frameserver will “call up” the requested frame as if you’re working in the NLE.  Notice that the frameserver will even tell you the rate of frames and samples being served.

 

Importing Video(s) into Recode – Multiple Frameserves with Sony Vegas!

Start Recode and select “Recode DVDs and Videos to Nero Digital.”

 

Now press the “Import Files” button located at the upper right portion of the Recode screen and direct the Import Title dialog to the signpost.avi file created earlier.  You can select the various “video/audio/subtitle/info” tabs to view the attributes of the video to be encoded.  After pressing “Add Title” Recode will take a few moments or longer depending on the length and complexity of the project, to analyze the video.  If you have some normal non-frameserve videos you should also import them now

One of the really great features of Vegas is that you can run multiple instances of it.  This means that you can actually frameserve more than one Vegas project at a time!  Just be sure to name each signpost file differently.  This can be a big time saver if you’re going to encode a few projects at once and you want them to be a certain size.  You don’t need to check the length of each project timeline and then compute bit rates, Recode will do all of this for you automatically.  Select “close” to exit this dialog after you’re finished loading all projects.

Setting Bit Rates and File Sizes
Press the “More” button located at the lower left portion of the Recode screen to show the advanced controls.  The first thing you’ll want to do is set the “Nero Digital Profile” located at the bottom right portion of the screen to “HDTV-AVC.”  This will not encode all video at HD resolution, Recode will automatically encode at the resolution of the source video, as long as this profile is of higher resolution than the source video.  Setting it at the highest resolution profile assures that Recode is able encode at any source resolution and it allows you to specify any resolution for encoding that you wish.  Now is also a good time to rename the video file to be encoded by double-left clicking, with a pause between clicks, on the video file in the “Content” column.  This will be the new name of the encoded file.

On the right side of the screen, towards the middle of the screen you’ll see the “Fit to target” dialog area.  If this box is checked the video or videos to be encoded will be set at a bit rate that will result in the project size specified.  For example if you want your videos to be encoded to fit a standard 4.7GB DVD-5 disc then make that selection.  Recode will make the bit this calculation for all of the videos in the project automatically.  If more than one video is to be encoded you may move the video quality slider located to the right of the video name.  This will change the bit rate of that video while increasing or decreasing the bit rates of the other videos to keep the project at the target size. 

If you want individual control over the bit rate of each video simply uncheck the “Fit to target” dialog.  Then you’ll be able to specify a bit rate for each video.  You can also select “custom” in the “Fit to target” dialog and enter a value in the Custom Target Size dialog box.  This is a great feature.  Not only do you not have to calculate bit rates so that your project will fit on a certain sized media, but Nero will also adjust bit rates so that all of your video fit the target size automatically.

Now select the video that you would like to set associated audio stream bit rate for by left-clicking on the video to highlight it.  Directly in the center of the Recode screen you’ll see four tabs that display the audio/subtitle/info of the selected video’s audio stream(s).  If the video has more than one audio stream each stream will have a corresponding audio tab.  Select the audio tab that you want to set the audio bit rate and press the “Settings” button directly below the tabs.  You can either leave the default settings or make a custom selection.  I’ve found that a bit rate of 128kbps is more than adequate for very good quality music.  If high compression ratios are required you can go as low as 64kbps and maintain decent audio quality.  As is always the case with compression, experiment to find the bit rate above which there is no perceived increase in audio quality.

Setting Video Properties
Select a video and press the “Video” button located at the right side of the screen.  The Nero Digital Video Settings dialog will appear.  This dialog has three tabs that provide for the deinterlacing of interlaced video, cropping of video, and setting the resolution of the encoded video.  Recode generally make excellent default choices so you probably won’t have to adjust the default settings.  The exception is if you want to down sample video.  For example, if you have a 1080i HDV video with 1440x1080 resolution and you want to create SD video you’ll have to manually input the 720x480 screen dimensions in the Resize tab.  Alternatively you can select a digital profile (lower right portion of screen) that corresponds with your intended output size.  I like to know the dimensions of the video I’m exporting so I just leave the HDTV digital profile setting and set lower or higher resolutions if I want to up or down sample the video.

If you are using Sony Vegas I strongly suggest down sampling any video in Vegas.  Vegas employs a very high quality down sampling algorithm and it provides spectacular results.  To do this just set your project properties resolution and pixel aspect ratio to your desired final video format.

You’ll also notice an option in the resize tab called “Letterboxing (square pixel).”  When selected, this option will pad your encoded video with letterboxes, black horizontal bars above and below the video.  This is often useful when you need to downsample a widescreen format to a 4:3 aspect ratio format, such as HDV to SD.

If you are going to be deinterlacing your video you might want to do that in your host application since it probably has more than one deinterlacing option.  There are many types of deinterlacing and each one is best suited for a specific type of video.  Again, experimentation is critical for achieving great results.

Although you probably won’t need to if you’re encoding a video project from your NLE, Recode also provides the option to set start and end points as well as chapter points.  These options may be selected by pressing the “Start/End” and “Chapters” buttons located on the right portion of the Recode screen.

Now we’re ready to move onto the encoding screen.  Press the “Next” button located at the bottom right portion of the screen.

HDV 1080i and Correcting the Display Aspect Ratio
The HDV 1080i anamorphic 1440x1080 video format used by the Sony Z1U and FX1 camcorders can present some playback aspect ratio problems if you don’t set things up correctly in both Vegas and Recode.  Normally the 1440 vertical lines of HDV 1080i video is automatically scaled to 1920 vertical lines in the playback application.  If the video is not played back full size (1920x1080) then the playback software will rescale the video to a multiple of those dimensions.  

Currently aspect ratio is not being carried through correctly when frameserving HDV 1080i video from Vegas to Recode, but it does occur when directly encoding HDV 1080i content to MPEG-4 in Recode.  I’m not sure about this, but I suspect that the 1.333 pixel aspect ratio is not being passed through Vegas to Recode, or Showtime 2 isn’t reading the aspect ratio correctly for some reason.  The 1.333 PAR (pixel aspect ratio) “instructs” the playback device to stretch out the video to the proper 16/9 proportion.  This is a new format and it’s not unusual to have “teething” problems of this sort.  I’m sure this will all be straightened out soon enough.  For now though, here are some workarounds.

 

If you are editing HDV 1080i video in Vegas you should have the project properties template set to HDV 1080i and the preview window set to “simulate aspect ratio of device.”  Unfortunately this project property setting may cause some media players, such a Nero’s Showtime 2, to incorrectly display the 16:9 HDV 1080i video (frameserved from Vegas) with a 4:3 aspect ratio video.  Although this can be corrected in Showtime 2 by forcing a 16/9 aspect ratio, it is possible to create video that will be correctly recognized as widescreen by Showtime 2 with a small loss in overall resolution.  We’ll discuss how to do that in a moment.

 

Keep in mind that if you use the following technique you will be slightly reducing the vertical resolution of the video from 1440x1080 to 1440x816.  Since you will most likely be deinterlacing the video anyway, the difference in quality will be minimal, especially when viewed on smaller or lower resolution displays.  If you must maintain the full 1440x1080 resolution of the source video use the technique above and force Showtime 2 to use the 16:9 aspect ratio!  Here’s how to frameserve HDV 1080i video from Vegas to Recode 2 will be correctly recognized by Showtime 2 as 16:9 aspect ratio.  After selecting the HDV 1080i project template in Vegas, change the pixel aspect ratio to 1.000 (square pixel) from 1.333.  What this does is rescale the 1440x1080 video to fit in a 4:3 aspect ratio screen.

Here’s how to frameserve HDV 1080i video from Vegas to Recode 2 will be correctly recognized by Showtime 2 as 16:9 aspect ratio.  After selecting the HDV 1080i project template in Vegas, change the pixel aspect ratio to 1.000 (square pixel) from 1.333. 

When the pixel aspect ratio is set to 1.000 Vegas will serve the HDV 1080i video in a 4:3 aspect ratio letterboxed format.  If this video is encoded in Recode then the letterbox bars will also be encoded even if the letterbox option in the Video>Resize tab is not selected.  Although MPEG-4 is very efficient at encoding static constant colors, it’s best to crop out this unnecessary part of the video so that all available bandwidth is used to encode actual video.  Select the HDV 1080i video to be encoded in Recode by left-clicking on it and then press the “Video” button on the right side of the Recode screen.  This will open the Nero Digital Video Settings dialog.  Select the “crop” tab.  Select “custom crop” and “Adjust...”  Recode does a great job of automatically cropping letterboxed video but on occasion doesn’t get it exactly right.  The settings for HDV 1080i should be “0” for left and right and “136” for top and bottom.

 

Now navigate to the resize tab and leave the default “Automatic (recommended)” resizing option.  This will create video that doesn’t have letterboxing yet will still display with the proper aspect ratio in Showtime 2.  If you want letterboxing just manually set the resolution to 1440x1080.

You can manually adjust the cropping borders from the crop dialog.  If you press zoom the crop dialog will most likely zoom to a size larger than your screen area making it impossible to see the “un-zoom” button!  This happened to me.  To fix it exit and re-enter the crop dialog and then press tab 5 times and then press the enter key.

Encoding the Video(s)
On the Burn Settings page you’ll see two large icons on the left side of the screen labeled “Burn Options” and “Nero Digital Settings.”  Once again Recode makes good default burn settings but there are a few you might want to tweak.  In the “Destination” dialog at the top of the screen select if you want to create files or a disc image.  Now press “Browse” and select where you want the files or disc images to be created on your system.

Press the “Nero Digital Options” located at the left side of the screen and select the “Expert Mode” tick box located at the lower left portion of the screen.  There are a lot of encoding options here and I’m not going to go through them all.  For most encoding sessions the Recode default settings will be adequate but you should experiment with the various settings to fine tune your video.  Setting a small start/end portion of each video (see previous section) will allow quick testing of your videos to be encoded.  I suggest testing a high motion portion of the video as they are generally the most problematic.

If you have video with lots of motion in it, or have the time to produce the highest possible quality video for a given bit rate I suggest enabling two-pass encode.  Select Profile>AVC Encoder>Rate Control to select two-pass encoding.

The “Decision Quality” will also have a significant effect on the quality of the encoded video.  This control is accessed from “Profile>AVC Encoder>General Settings.  Set this to Highest Quality for the best quality (and slowest) encode.

Located under “Profile>AVC Encoder>Visual Enhancements” are controls that may or may not make your video look better.  The enhancements located on this page are best left off if you have color corrected your video in the NLE.  This is especially true if you have set your video to be within certain broadcast standards as these settings will most likely throw your video out of those tolerances.  These setting may be useful for a quick fix though.  As always, experiment.

The last setting we should consider before encoding is the “Priority” control for Recode located at the bottom right portion of the screen.  This control determines how much processor time Recode will be allotted during the encoding process.  As the processing load is increased working in other programs will become slower and slower.  I recommend leaving the default setting of “Low” as Recode will “let go” of the processor when you need it for other operations but use all available left over processor cycles.  This allows you to work efficiently on other tasks while Recode works silently in the background.  I should also note that Recode is highly optimized for multi-processor systems.  On my hyperthreaded P4 the cpu overhead remains pegged at 100% during encoding.

That’s it!  Sit back and relax, or work on other projects while Recode encodes your Vegas project to MPEG-4.  This tutorial is by no means provides a comprehensive description of all of the features and capabilities of Recode but it should provide enough information to get you going so that you can quickly explore the rest of the Recode tools and options.

Performance – A Sneak Peek at Part II
In the second part of this tutorial I’m going to be exploring the encoding performance and visual quality of Recode as well as how H.264 (MPEG-4 Part 10) stacks up to WMV and MPEG-2 at equivalent bit rates.  I’ll also be looking at the effects of hyperthreading on both encoding in Recode and playback in Showtime 2.  So far I’m very impressed with the quality of the MPEG-4 video produced by Recode.  I’m also surprised at the enormous amount of processing power it takes to smoothly playback MPEG-4 video. 

Until next time! 

- Mark

   
Products mentioned in this article  
Nero Recode http://www.nerodigital.com
Sony Vegas http://mediasoftware.sonypictures.com/products/vegasfamily.asp
Debugmode Frame Server http://www.debugmode.com

 

 
   View other VASST training tools, FREE! Click the link below to be transported to the VASST resources pages.
VegFiles
Plugins
Scripts
Hardware

 

Tutorials
Themes
Forums/Groups
HDVPortal

 

Books/DVDs
Reviews
FreeStuff
VegasFAQ's