ZenFire's Blog
I heart CvS2 and 3S
Video Capture part 3: Cropping and Resizing
photo

This time I want to talk about cropping and resizing of source material. These greatly affect how your end-product will look.

Cropping is generally used to remove the black bars on the side of the picture. The resulting image will have a different resolution than what you were originally working with and you might want to resize this to the format you want to work with, but not always. Both 3S and CvS2 have a width of 640 pixels. If you capture at the full NTSC pixel width like you should be, then you will have an image that’s 720 pixels wide. Open up this video in VirtualDub and use the null transform filter to define the area you want cropped. If you subtract the width of the black bars on the left and the right from 720 you’ll end up with 640. This is a very nice width to have, since you can halve it to get 320x240, the common small video 4:3 format. If you do the same thing for the black bars at the top and the bottom for CvS2 source video, you’ll end up with a different height than you might expect. This might not be the exact number for everyone, but usually you should end up with a vertical resolution of 348 pixels. That’s not exactly 4:3, but more in the direction and even past 16:9. I guess they’re targeting the widescreen market or something. So if you want to maintain the same aspect ration as your source video then you should either crop off all of the black bars and have a weird non-standard resolution, or you leave part of the top and bottom black bars. In my King tutorial video I actually decided to stretch the image into a 4:3 aspect ratio, which means everything in that video appears taller than normal.

The biggest benefit of cropping is that more of the screen will be used to display the actual game’s image. This looks a lot better in full-screen mode if the aspect ratio of your viewing screen is equal to that of the video (usually 4:3). Although the black bars in the original image compress very well because they don’t move, it’s still unnecessary overhead. Cropped images look clean and are more efficient use of your decoding power.

Resizing will sometimes be necessary if your source material is of higher resolution than your end-product. With my “A Closer Look at KING” video I had source material of 640x224 (after cropping), because I wanted to give myself the option of releasing a HQ version of the video. The importance of resizing is that you get an aspect ratio that you desire, as well as controlling how big your eventual file size will be. You have several choices when it comes to resizing: nearest neighbor (a.k.a. pixel resize), linear resize and bi-cubic resize. You shouldn’t even consider the first option unless you’re going for a very pixely look on purpose. The second is fast and produces similar results as the last one when it comes to shrinking an image. For stretching an image, for example after capturing half-height video, bi-cubic resizing produces the most visually pleasing results. Bi-cubic resizing algorithms can take up to two parameters which define the curve between samples. To be completely honest: I couldn’t tell the difference between linear and bi-cubic when I more than doubled my source video’s height. I just trusted commonly accepted truths and chose the latter.

Performing cropping and resizing manually for each recording is very tedious. Thankfully there are tools to make to make this easier. VirtualDub can take multiple jobs in a job list and execute them in order, you can then go have a meal or take a shower and it will be done when you come back. Once you’ve specified cropping, resizing and any other additional filters for your raw captures, save these as “processing settings” in a file. The next time you only need to load these settings and save the file to AVI. Even doing all this “open capture file → load settings → add to job list” can be a lot of work, so now the icing on the cake is VdubBatcher. This program creates a job list for VirtualDub using an easy interface for selecting multiple video input files, choosing a settings file as well as specifying a location and naming scheme for your output files.

2007-04-03 21:35:04 GMT
Comments (0 total)
Add to My Yahoo! RSS
1