View Single Post
Old 10th December 2014, 20:10   #3  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,823
Try the Yoda Resize Calculator. It's an exe but it's safe. You set the input resolution and/or aspect ratio along with your desired cropping and resizing, and It'll calculate the aspect ratio distortion for you. I just fiddle with the cropping and/or resizing a bit until the distortion is at a minimum. Sometimes keeping it close to zero means cropping a few pixels from the picture somewhere.
According to the calculator you could resize to 960x526 after the cropping you specified.

The calculator will apply mod1 cropping, but the AVIsynth crop function works in increments of two. If you're like me, and a little OCD at times, you can use the resize filter to apply extra mod1 cropping to the video (in case you weren't aware). If, for example (I'm just making up numbers at the moment), ideally you'd like to reduce the aspect ratio distortion by cropping 3 pixels from the left instead of 2, and 41 from the bottom rather than 40, you can do it this way:

Crop(2,40,-2,-40)
Spline36Resize(960,526,1,0,0,-1)

Although if you're cropping first, then upscaling with nnedi3 and resizing, don't forget to account for the upscaling if you use the resize filter to crop. I'm a bit silly and it tends to confuse me, but if you double the size of the video after the initial cropping, then you'd need to double any resize filter cropping too. So to crop the original video by 3 pixels left, and 2 right, 40 top and 41 bottom, you'd need to do it like this if nnedi3_rpow2 (2) is in the middle.

Crop(2,40,-2,-40)
nnedi3_rpow2 (2)
Spline36Resize(960,526,2,0,0,-2)

Last edited by hello_hello; 10th December 2014 at 20:38.
hello_hello is offline   Reply With Quote