[ This article was first published in the January, 2010, issue of
Larry’s Final Cut Pro Newsletter. Click here to subscribe. ]
I ran into an interesting problem over the weekend that I want to share with you because the solution is more complex than at first blush.
Here’s the problem: I was asked to create a video for posting on line. The video had two components: me on camera talking, and screen shots.
The client wanted the finished video delivered at 720 x 405 (which is 16:9 DV) and gave me about three days to put this together. Given that time-frame, the only camera that I had access to shot 4:3 DV interlaced, while all the screen shots were captured 1280 x 720 progressive, using the Animation codec.
Yup. It was a mess.
Naturally, the first thing I did was drop everything into one timeline and let FCP handle all the conversions. Easy and simple. And it looked WAY past awful.
Here’s an example of a 4:3 DV image, dropped and stretched into a 16:9 ProRes 4444 timeline and exported for compression. Ugh! Massive stair-stepping along all edges, the complete break-up of images in the computer monitor and I don’t look so great either.
What I discovered needed to be done was to break this movie down into components and process each section individually. Here are the steps I followed to create the final 720 x 405 compressed master:
CREATION PHASE – SCREEN SHOTS
CREATION PHASE – ON-CAMERA
COMPRESSION PHASE
COMPILATION PHASE
The advantage of this approach is that while the codec and image size remain the same (720 x 405, H.264), I can use different compression settings and data rates to make each video look great.
This took me the better part of a day to get the compression part right, which is why I wanted to share it with you here.
PREPPING SCREEN CAPTURE FILES
Lots of tutorials on how to shoot screen capture movies are available – in fact, I’ll add that to my list of things to talk about in future issues.
For now, though, the basics are that, starting in the middle of 2009, I now record all my tutorials at 1280 x 720. This makes them very easy to distribute on the web, which has optimized itself to display HD as 720p video, plus shooting a progressive image makes creating smaller image sizes very easy.
Yes, 1080i video has a bigger image, but dealing with the interlacing is too much work. Everything I shoot now is going to the web, where 720p makes a perfect format.
So, I created, cropped, and edited all my screen captures to 1280 x 720. By default, screen captures are progressive, so I didn’t have to worry about interlacing.
My screen capture program of choice is Telestream’s ScreenFlow, which allows me to export my completed capture using either the Animation or Apple ProRes 4444 codec. If I were using FCP 6, I’d export using Animation. However, I’m using FCP 7, so ProRes 4444 is a better choice.
NOTE: My only real complaint with Screen Flow is that it records all audio on two tracks, which means I have to be very careful not to talk when the computer audio is playing, otherwise, the two audio sources will overlap, which makes audio editing impossible.
I then edited all my screen captures in Final Cut Pro 7 and exported the finished sequence as a self-contained QuickTime movie, using the ProRes 4444 codec. At this point, the file was 16:9, progressive, and 1280 x 720 file.
NOTE: Because my sequence was set to ProRes 4444, I exported using Current Settings. I much prefer exporting using Current Settings than trying to transcode (convert) the video into some other format during export. Compressor does a much better job of transcoding than FCP.
PREPPING THE ON-CAMERA FILES
Next it was time to shoot me on camera doing the open and close to the program.
The only camera I had available shot 4:3 DV, which differed from the screen shots in three critical ways: it was interlaced, it was smaller, and it was 4:3.
But, they say “necessity is the mother of invention” and my deadlines wouldn’t wait, so I shot and edited the video using Final Cut Pro. When I was done, I exported two files: the open and the close. Both were 720 x 480, DV, interlaced.
PREPPING THE SCREEN CAPTURE MOVIE FOR COMPRESSION
While Compressor 3.5 allows for Job Chaining, which means that the output of the first task automatically becomes the input for the second task, I decided not to use this at this time. The main reason was that I had not yet worked out all the settings. If I needed to do this on a regular basis, job chaining would save a great deal of time, without harming the final image quality.
For now, though, I need to get all my files into the same size prior to final compression. To do this, I will “pre-process” the file – get everything sized properly for final compression – then compress it in a second step.
1. Click the Add File button to import the screen capture file into Compressor
2. Create a new setting file by clicking the Plus key in the top right corner of the Settings window and selecting QuickTime movie. (To create an MPEG-4 movie, you’d select MPEG-4.)
3. In the Inspector, rename your new settings file (I used “Resize movie”) and add a description so you’ll know what this does when you look at it later. (I used “Resize movie to 720×405, no audio change.”) Then, since all we want to do is resize the video, set the Audio pop-up menu to Pass-through – which means the audio is not touched. Then, make sure Streaming is set to None.
4. Click the Video Settings button and make sure the codec is set to Apple ProRes 4444 (Use the Animation codec, if you are still running FCP 6). Leave the rest of the settings alone.
NOTE: While ProRes 4444 is not a good format for video playback, it is an excellent format for transferring files between applications, or in creating source files, because it is virtually lossless.
5. Here’s the key part. Go to the Geometry tab (2nd in from the right) and set the Frame Size pop-up to Custom 16:9. Then, change the Width and Height settings to 720 x 405. Make sure, also, that the Pixel Aspect is set to Square; or 1.0000.
6. Save your setting, apply it to the file, and Submit the file for compression. When the process is done – and it doesn’t take very long – your finished file will be 720 x 405, ProRes 4444; with uncompressed audio.
NOTE: It could be argued that you don’t really need to pre-process this file, as we could have sized and compressed this file all at the same time. While true, when I have a project as tricky as this one, I tend to compress the files in small steps, that way, I can spot a problem immediately and fix it, without wondering where in the process the error occurred.
Then, if I need to do this procedure on a regular basis, I would first figure out the workflow, then look for every possible way to automate it for all succeeding files. Job chaining and droplets would be my first places to look.
COMPRESSING THE SCREEN CAPTURE MOVIE
Now that we have adjusted our movie to the correct size, we need to compress it. There is a wide variety of software that could be used for this, but, for this example, I’ll stay with Compressor.
Here’s the short version, if you want to see a step-by-step version, I’ve created a video tutorial that walks you through a similar process:
Workflow
Import your file into Compressor.
From the Setting menu, apply Apple > Formats > MPEG-4 > MPEG-4. This compresses your video into H.264, at 100% size and 100% frame rate. You can absolutely adjust these settings. For now, I will work with the default compression settings.
IMPORTANT NOTE: I’ve found the H.264 settings in Compressor create very washed-out video. To compensate for this, we need to add two filters:
* Color Correct Midtones
* Gamma Correction
The best place to add saturation to a video image is in the mid-tones. Its also the portion of the image than can handle the most saturation. So, in the Filters tab (3rd from right) check the Color Correct Midtones check box to turn it on and apply a value of 3.0 to the Red, Green, and Blue settings.
Then, check on the Gamma Correction filter and increase the value to 1.05. This makes the image look a bit darker and richer.
I use these filter settings on all the H.264 video I create in Compressor.
Finally, in the Geometry tab (2nd from right) make sure the Frame Size and Pixel Aspect ratio are set correctly. In this example, we want 720 x 405, 100% of source, Square pixels.
NOTE: The default setting of the Geometry tab is 320×240 – which can TRULY mess up 16:9 output. Always be sure to take a look at these Geometry settings before starting any compression.
COMPRESSING THE DV VIDEO
Now things get a bit trickier, because this DV file is the wrong size and the wrong aspect ratio. So what we are going to do is reduce the size of the video so it fits into 405 pixels vertically, deinterlace it, and add black bars on either side of the image, so that the frame is 16:9, but the image retains is 4:3 format.
NOTE: I tried cropping and zooming the image to fill the frame, but after deinterlacing the image looked so bad, I gave up trying.
Here are the steps:
1. Load your video into Compressor.
2. Apply the MPEG-4 setting we used above to the clip.
NOTE: This setting can absolutely be tweaked to reduce the data rate and other nifty stuff. This tutorial is more focused on filters and resizing than on data rates. For that reason, I’m just using a default setting.
3. Click the Filters tab and apply the Color Correct Midtones and Gamma Correction filters and settings we used on the other clip.
4. Click the Geometry tab. Make sure the Frame Size matches the other movie – in this case 720×405.
To make sure your numbers are accurate, set the Frame Size pop-up menu to Custom 16:9.
5. Also make sure the Pixel Aspect is set to Default for Size, or, my preference, Square.
6. Look at the bottom of the Geometry window. Output Image Inset Padding automatically adds black to the borders of an image to create pillar-boxing (black on the sides) or letter-boxing (black at the top and bottom). I added a value of 90 to both the left and right sides, which means the image keeps it 4:3 shape, with black padding out the rest of the image to fill the 16:9 frame.
Once you are done adjusting the settings, click Submit to compress the file.
NOTE: If you don’t like how the deinterlacing turned out, you can adjust this manually. By default, the Frame Controls should deinterlace without problems. But, if not, go to the Frame Controls tab (3rd from left) and change the settings to match this screen shot:
- Click OFF the auto-sensor (it looks like a large asterisk in the top left corner
- Turn ON Frame Controls
- Set Output Fields to Progressive
- Set Deinterlace to Better
- Turn OFF Adaptive Details
When you are done, you now have several comporessed movies, all with the same image size and codec, but with potentially different data rates. Different data rates does not cause QuickTime any problems.
LAST STEP – BUILDING THE COMPLETED MOVIE
Now that all our files are compressed and output, we need to build a completed movie. This can NOT be done, at the present time, using QuickTime X (shipped with Snow Leopard) but only with QuickTime 7 Pro.
1. Open the first movie in QuickTime. Notice that it is 16:9, with a 4:3 image inside. (Oh! And did you notice that the image quality is a LOT better?! It also looks good when scaled up to full-size.)
2. Open the second movie in QuickTime
3. Choose Edit > Select All (Command+A) to select the ENTIRE second movie.
4. Choose Edit > Copy to place the entire selected movie in the clipboard.
5. Go back to the first movie and click the right pointing arrow with a line to jump the Playhead to the end of the movie.
6. Select Edit > Paste to paste the entire second movie at the position of the Playhead. You have now combined two movies into one.
7. Open the third movie, Select All and copy it to the clipboard, just as before.
8. Go back to the first movie. Be sure the playhead is at the far right end of the Timeline; use the “Jump to End” button to position the playhead to the far right, if necessary.
9. Edit > Paste the third movie.
10. Move your playhead back to the beginningof the Timeline, and make sure the In and Out indicators are both dragged to the beginning of the movie.
11. Choose File > Save As. Give your file a name and make sure to save it as a self-contained movie.
All these different movies are now in the same movie, with the same size, same codec, and look great. There are lots of ways you can vary this procedure for different file sizes, frame sizes, and compression settings. But in all cases, the basic workflow remains the same.
Done. Whew!
UPDATE – FEB. 3, 2010
Mark Trenary adds:
In respect your article about outputting MPEG4 files, I was recently wanting to encode using MPEG4 format Part.10 i.e. H.264 codec.
Some searching Apple forums and several trials later I concluded I couldn’t export from Compressor using H.264 codec in MPEG4 format (apart from the device presets or of course using a QT .mov container)
Rather one must export using QuickTime 7 conversion, select Movie to MPEG-4, click options then change File Format to MP4 (not ISMA), now you can select H.264 as your codec. The select H.264 video format.
A potential issue I assume is that by deselecting the Internet Streaming Media Alliance – the compatibility with other players is not guaranteed.
For what its worth, Compressor MPEG4 export files are reported to be using “MPEG4 decompressor libavcodec”.
whereas QT MPEG4 exports as described above are reported thus:
I’d be interested in clarification from readers about exporting compliant MPEG4 files using MPEG Part.10 H.264 codec. Would there problems with playback selecting the non ISMA format for web publishing of MPEG4 movies?
Larry replies: Thanks, Mark, for this additional information.
Tom Wolksy adds:
Animation is a truly horrible codec for editing. Why not use PhotoJPEG or something else, or is Animation all that the screen capture app would produce? Why 4×4? It seems such overkill for such a small frame resolution> Or was there some need for transparency?
Also, I think selecting Export Chapter Markers will work as well.
Finally, I don’t think we can even make a reference movie for H.264 video.
Larry replies: Thanks, Tom. In my case, the Animation codec was determined by the screen capture program. And I agree, if you don’t need transparency, ProRes 4444 can be more than you need.
3 Responses to Compressing Different Video Formats into One QuickTime Movie
Hi Larry, Thanks for this, I have been trying to work on the best way to record my screen and use it in demonstrations and I am wondering if you can help me at all.
I have a Sony V1P camera that shoots in 25p mode and I am using screenium to record my computer screen. I have a very large monitor and can shoot the screen capture as high as about 2500 pix wide, which is fantastic if not using video footage from my video camera, but as soon as I bring it all into FCP 7, either my video footage looks shocking or my onscreen video looks terrible. Can you possibly tell me whether I should shoot in a lower resolution on my screen to balance the Video camera’s best option or is there a better way to ensure that the footage from both look crisp when outputting from FCP?
Hi Larry,
I’ve got a few films from the old days, shot in SD 4:3 25i (why didn’t I use ‘movie mode’ on the camera that I now understand is 25p?) that I’d like to convert from.avi into .mov files, so I can show my friends or bring into a (widescreen) project if needed.
(I think a friend wants to use some footage in his work.)
So what would you suggest I do in compressor?
Pro Res 422 vs h.264?
Frame rate automatic vs 25?
Gamma correction none or automatic?
Do I check interlaced? And if so, is it top field first?
So basically, what’s the best way of turning an SD 4:3 25i (Pal) .avi into a 25p .mov, at the best quality?
Many thanks.
Andy…
Larry Jordan – Compressing Different Video Formats into One QuickTime Movie | Final Cut Pro Training & Classes…