Log in

View Full Version : Keeping Aspect Ratio


jk888
20th March 2004, 19:01
How do I keep the aspect ratio after resizing? I searched hard for it and there seems to be no material on aspect ratios.

Here's my script:

LoadPlugin("F:\AviSynth 2.5\plugins\mpeg2dec3dg.dll")
LoadPlugin("F:\AviSynth 2.5\plugins\Decomb511.dll")
mpeg2source("F:\DVD2\test.d2v")
FieldDeinterlace(blend=false)
Crop(4,8,-4,-8)
LanczosResize(624,416)

I just want to keep the original 16/9 aspect ratio. Also I was wondering if using the aspect ratio settings in the Xvid encoder is good.

Soulhunter
20th March 2004, 20:09
Why not simply use the windows in-build calculator... :rolleyes:


624 / 16 * 9 = 351

But 351 is not a multiple of 16 !!!

351 / 16 = 21,9375

So closest multiple would be 22... ;)

22 * 16 = 352

So you could use a resolution of 624x352 !!!


Bye

Didée
20th March 2004, 20:30
Use Gknot.

- Didée

Soulhunter
20th March 2004, 20:39
Originally posted by Didée
Use Gknot.
Sure, thats the easiest way... :D


Bye

jk888
20th March 2004, 21:04
Gknot is too easy, I want to learn it from the ground up.

That calculation is good but remember I cropped the video before resizing, so the video becomes 712 x 464. 712 is mod 8 while 464 is mod 16. So should I pick a mod 8 resolution?

Soulhunter
20th March 2004, 21:36
Originally posted by jk888
...but remember I cropped the video before resizing, so the video becomes 712 x 464...Could write another calculation, but Im too lazy... :D


- Try to crop after resizing (to a 16:9 AR) !!!

- See how much pixels are left now...

- Round the H/W values to the nearest multiple of 16 (or 8 if your GC supports this) !!!


Bye