PDA

View Full Version : CCE SP 2.70 Letterbox Help needed


Jibreil
6th September 2005, 22:34
Hello friends,

I'm using CCE SP 2.70.02.01. I have a DivX movie with size 720x400 (not widescreen). When I usually convert it into MPEG2 format the video size tends to stretch a bit and the screen is kinda elongated when viewed on my TV.

Now, I would like to use the Letterbox option in 'Picture Quality' settings so that when I author the video with DVD-Lab Pro, the results shown come exactly as the original DivX print.

Please could anyone of you suggest what should be the best way to do it:

How can I calculate the letterbox width? (top & bottom)
Should I be encoding the video in 720x400 size with the Letterbox option?
Should I be encoding the video in 720x576 (PAL) with the Letterbox option?


My idea is to view the DVD on my TV maintaining the same normal video (no streching or elgongated screen) as DivX Video file.

Amnon82
6th September 2005, 23:43
It is simple. You have a resolution of 720x400. As You told us it is a PAL Source you have to get the difference between 400 and 576 which is 176. So You add 88 to top and bottom borders in an avisynth script.

AviSource("<Enter here the path of the AVI>")
#BicubicResize(720,400) #this line you can delete
AddBorders(0,88,0,88)

Letterbox-Option in CCE only overwrite the picture with black bars if You add them. It is only used to put the encoder engine to the picture.

If You have for example an encoded MPEG2Source with letterbox You can tell CCE with this option how big the borders are. So it puts the engine only to the moving picture. If there is to much noise You can black or white it to get better borders ;)

Jibreil
7th September 2005, 11:22
Amnon82: Thank you very much for your reply.

Yes, the video source is PAL since it is 25fps.

I did some search on Doom9 and happened to stumble upon a AVI to DVDR guide where this person uses FitCD (pretty handy tool) to generate a AVISynth script.

This is the script I generated from it, please let me know if it does the job without the need to add Letterboxes :confused:


# -= AviSynth v2.5.5.0 script by FitCD v1.2.4 =-
AVISource("D:\Pharma\Ranbaxy.avi")
BicubicResize(688,416,0,0.6,0,0,720,400)
AddBorders(16,80,16,80)
#Trim(0,191947).FadeOut(150)


I will surely try your script and see which of the two gives me the result I want.

Thanks once again :-)

Boulder
7th September 2005, 11:30
Your "letterboxes" is actually the AddBorders line. As the name suggests, it adds borders to the image.

Did you remember to enable the accurate cropping option in FitCD?

Jibreil
7th September 2005, 11:38
Your "letterboxes" is actually the AddBorders line. As the name suggests, it adds borders to the image.

Did you remember to enable the accurate cropping option in FitCD?

This is the script I get with the 'accurate cropping option' selected


# -= AviSynth v2.5.5.0 script by FitCD v1.2.4 =-
AVISource("D:\Pharma\Ranbaxy.avi")
BicubicResize(688,416,0,0.6,0,1,720,398)
AddBorders(16,80,16,80)
#Trim(0,191947).FadeOut(150)


Result: The Border or Letterboxes (whatever you might call it) tend to increase making the video shrink by height.

Now I've selected 'no cropping' where I get the following script:

# -= AviSynth v2.5.5.0 script by FitCD v1.2.4 =-
AVISource("D:\Pharma\Ranbaxy.avi")
BicubicResize(688,416,0,0.6,0,0,720,400)
AddBorders(16,80,16,80)
#Trim(0,191947).FadeOut(150)

I have left the video for encoding which the above script, waiting to see the result.

Boulder
7th September 2005, 11:42
You probably won't see much difference between the two because the script crops only two pixels. However, with some other files, you might notice that there's a huge aspect ratio error unless you select accurate cropping (or crop manually).

Jibreil
7th September 2005, 11:46
You probably won't see much difference between the two because the script crops only two pixels. However, with some other files, you might notice that there's a huge aspect ratio error unless you select accurate cropping (or crop manually).

So do you suggest I should use the script option reckoned by Anmon82?


AVISource("D:\Pharma\Ranbaxy.avi")
AddBorders(0,88,0,80)
#Trim(0,191947).FadeOut(150)

Boulder
7th September 2005, 11:47
No, I would use the script FitCD gives with accurate cropping enabled. It will guarantee an aspect ratio as close to the original file as possible.

Jibreil
7th September 2005, 11:53
No, I would use the script FitCD gives with accurate cropping enabled. It will guarantee an aspect ratio as close to the original file as possible.

I already did that, but the end result is the Border line increases making the video shrink in height.

Do you mean to say that when I author the video in DVD-Lab Pro the end result on my TV set will be the same as the DivX print?

Boulder
7th September 2005, 11:58
The borders do not touch your video. BicubicResize does that.

Try setting overscan blocks to zero and then see the script FitCD gives you.

Jibreil
7th September 2005, 12:44
The borders do not touch your video. BicubicResize does that.

Try setting overscan blocks to zero and then see the script FitCD gives you.

This is what I get:

# -= AviSynth v2.5.5.0 script by FitCD v1.2.4 =-
AVISource("D:\Pharma\Ranbaxy.avi")
BicubicResize(720,448,0,0.6,8,0,704,400)
AddBorders(0,64,0,64)
#Trim(0,191947).FadeOut(150)

Do you want me to check Anamorphic or leave that alone on both sides?

According to Anmon82 suggestion, I could change the AddBorders to his setting and get the exact result as I want?

# -= AviSynth v2.5.5.0 script by FitCD v1.2.4 =-
AVISource("D:\Pharma\Ranbaxy.avi")
BicubicResize(720,448,0,0.6,8,0,704,400)
AddBorders(0,88,0,88)
#Trim(0,191947).FadeOut(150)

Boulder
7th September 2005, 13:07
You can't just change the script FitCD gives you.

BicubicResize(720,448,0,0.6,8,0,704,400)
AddBorders(0,88,0,88)

will result in 720x624(=448+88+88) video which is illegal for DVD.

It seems you don't understand the way the scripts work. I strongly suggest you check the Avisynth docs which explain the different parameters and how they work. The BicubicResize line first crops 8 pixels off left and right (resulting in a 704x400 video), then resizes to 720x448. AddBorders adds 88-pixel borders to the top and bottom which makes the video 720x624.

If you want a simple approach, use FitCD's script as it is with accurate cropping enabled. As I said, it will ensure that the A/R error is minimal compared to the input file so no stretched/squeezed video anymore.

Jibreil
7th September 2005, 15:37
You can't just change the script FitCD gives you.

BicubicResize(720,448,0,0.6,8,0,704,400)
AddBorders(0,88,0,88)

will result in 720x624(=448+88+88) video which is illegal for DVD.

It seems you don't understand the way the scripts work. I strongly suggest you check the Avisynth docs which explain the different parameters and how they work. The BicubicResize line first crops 8 pixels off left and right (resulting in a 704x400 video), then resizes to 720x448. AddBorders adds 88-pixel borders to the top and bottom which makes the video 720x624.

If you want a simple approach, use FitCD's script as it is with accurate cropping enabled. As I said, it will ensure that the A/R error is minimal compared to the input file so no stretched/squeezed video anymore.

Yes, I really dont quite understand how scripts work. But, some of it does make sense to me now. Anyways, my doubts and queries are clear. I have left the video for encoding by setting the 'Block Overscan' to 0.

After a few hours, I shall know it's results and will definetly get back to you.

Thank you once again for all your help, every bit of info was worth the time. :thanks:

Amnon82
7th September 2005, 22:24
AviSource("<Enter here the path of the AVI>")
#BicubicResize(720,400) #this line you can delete
AddBorders(0,88,0,88)

I wrote this. You mixed it with the FitCD-Avisynth-Script.

I only added the line '#BicubicResize(720,400) #this line you can delete' to tell everybody that Your AVI has this resolution.

If you add a # in front of a line, AVISYNTH skips this line so my script was only this:

AviSource("<Enter here the path of the AVI>")
AddBorders(0,88,0,88)

So I only added the borders to get a valid resolution of 720x756.

Fit2CD is always better to get the right resolution, but as You told in the first post of this thread, that Your source is NO 16:9 encode I desided to add only the necessary borders to get it working with DVD-Lab.

Back to the Letterbox-Function of CCE. It only blanks the part of the video with white or black. It doesn't change the resolution.

For example: You have a 4:3 encode which has freaky pixel issues on the top or the bottom like You know form VHS-Cassettes You can paint them black.

Here the exact part of the manual of CCE 2.70:

Letterbox is a format to show an entire wide image of movie on 4:3 TV screen, adding black bars at the top and bottom of the screen. (Comment by me: This is what we all know.) If your source is letterboxed (Comment by me: A 4:3 Encode is ment which has already the black areas), you can improve the precicion of 3:2 pulldown detection, specifying these black areas to except them form the pulldown detection (Comment by me: CCE will put the encoder-engine only on the moving picture). Or when the noise is on the black areas, you can remove it and paint them black (Comment by me: or white if you want;)).

Jibreil
10th September 2005, 08:12
AviSource("<Enter here the path of the AVI>")
#BicubicResize(720,400) #this line you can delete
AddBorders(0,88,0,88)

I wrote this. You mixed it with the FitCD-Avisynth-Script.

I only added the line '#BicubicResize(720,400) #this line you can delete' to tell everybody that Your AVI has this resolution.

If you add a # in front of a line, AVISYNTH skips this line so my script was only this:

AviSource("<Enter here the path of the AVI>")
AddBorders(0,88,0,88)

So I only added the borders to get a valid resolution of 720x756.

Fit2CD is always better to get the right resolution, but as You told in the first post of this thread, that Your source is NO 16:9 encode I desided to add only the necessary borders to get it working with DVD-Lab.

Back to the Letterbox-Function of CCE. It only blanks the part of the video with white or black. It doesn't change the resolution.

For example: You have a 4:3 encode which has freaky pixel issues on the top or the bottom like You know form VHS-Cassettes You can paint them black.

Here the exact part of the manual of CCE 2.70:

Letterbox is a format to show an entire wide image of movie on 4:3 TV screen, adding black bars at the top and bottom of the screen. (Comment by me: This is what we all know.) If your source is letterboxed (Comment by me: A 4:3 Encode is ment which has already the black areas), you can improve the precicion of 3:2 pulldown detection, specifying these black areas to except them form the pulldown detection (Comment by me: CCE will put the encoder-engine only on the moving picture). Or when the noise is on the black areas, you can remove it and paint them black (Comment by me: or white if you want;)).

This is gonna sound really funny! I thought of this only after waisting 12 hours in re-encoding multiple times, whereas I could have read your message and tried it straight ahead, well trial n error makes you learn ;-)

I realised that I should encode it in 4:3 with the FitCD AviSynth script and the result came perfect. But since you said the same thing with the addition of the 3:2 pulldown option, I think I will do that as well :-D

I did a 3 pass Multiple VBR Encode, do you reckon 4 or 3 should be fine?

Thanks alot for all your help