digitalFAQ.com Forums [Archives]

digitalFAQ.com Forums [Archives] (http://www.digitalfaq.com/archives/)
-   Avisynth Scripting (http://www.digitalfaq.com/archives/avisynth/)
-   -   Avisynth: help with Lanczos Resize in FitCD ? (http://www.digitalfaq.com/archives/avisynth/13749-avisynth-lanczos-resize.html)

Zyphon 08-14-2005 07:13 AM

Avisynth: help with Lanczos Resize in FitCD ?
 
@Anyone

I am trying to convert my Alien movies to KDVD and I wanted to get the resize parameters from FitCD.

I am not 100% sure how to use FitCD, My DVD source is PAL 720 x 576 and I wanted to resize to 704 x 576 using Lanczos resize.

In the Mpeg Resizing I selected 16 for both round to settings, see the pic below:

http://www.digitalfaq.com/archives/error.gif

Are these settings correct?

I would appreciate any help and further info on how to get correct settings from FitCD to get my resize params.

Thanks in advance. :)

Dialhot 08-14-2005 07:36 AM

1/ In the present case this won't change anhything but in a general way, you can set the crop rounding to 2 or 4 and not 16. 16 must be kept for resize.

2/ I really doubt your source is fullscreen. So you must determine the top and bottom border that is in the source (using DGIndex, null transform filter in virtualdub or autocrop plugin in avisynth). Then put these two values (or 4 values, you can have also a little border on the right/left) into FitCD to have a correct crop/resize done on the real film area of your source, and not all the frame dimension.

This will also let you apply the filters only on that area and gain a lot of time. All depend on how your script is done. The case :
Code:

Mpeg2Source()
... filters ...
Crop/Resize
Borders

won't gain anything.
But if you do as a process myself :
Code:

Mpeg2Source()
Crop/Resize
... filters ...
Borders

You will gain a lot.
In the past, on the same encoding, CCE goes from 0.74x to 0.82x with that.

Zyphon 08-14-2005 07:48 AM

Thanks for your help Phil, I really appreciate it.

Would be so kind to explain the params of Lanczos please.

Code:

LanczosResize(672,544,8,0,704,576)
I take it this the 672,544 and 704,576 is the targe res. However I dont understand the 8,0 params.

Out of interest on the back on my DVD box I have the following:

AR: 2.35:1 and 16:9 Widescreen. It is a PAL Region 2 DVD.

I don't know if that info offers any more help.

Thanks again Phil for your help in this matter. :)

Zyphon 08-14-2005 08:07 AM

Hi Phil here are two settings from DGIndex, I selected clipping in DGIndex.

Here is the first one:
http://www.digitalfaq.com/archives/error.gif

And the second:
http://www.digitalfaq.com/archives/error.gif
Thanks to ImageShack for Free Image Hosting

With the bottom clipping. I click the move over the slider and then repeatedly hit the right arrow key. Every 4 taps of the righ arrow cursor key results in the value of the clip to increase by 8.

So my question is am I better off going with the first picture values possible cutting some of the bottom of the movie slightly or go with the second picture and leave the small black bar at the bottom?

Dialhot 08-14-2005 08:19 AM

Quote:

Originally Posted by Zyphon
Code:

LanczosResize(672,544,8,0,704,576)
I take it this the 672,544 and 704,576 is the targe res. However I dont understand the 8,0 params.

You take (crop) a 704x576 rectangle out of a 720x576 one. For that you have to cut 16 pixels so you have 16 position where you can start to cut. You can for instance takes the pixels from 0 to 703, or 1 to 704, or 2 to 705... The (8,0) is just to say that you want to take the pixels from 8 to 712 (in other words, you cut 8 pixels on the left, and 8 on the right).

Quote:

AR: 2.35:1 and 16:9 Widescreen. It is a PAL Region 2 DVD.

I don't know if that info offers any more help.
2.35 _means that you will have a border near 104 pixels in top and bottom ! (or 80 because the movie is anamorphic).

Dialhot 08-14-2005 08:24 AM

Quote:

Originally Posted by Zyphon
So my question is am I better off going with the first picture values possible cutting some of the bottom of the movie slightly or go with the second picture and leave the small black bar at the bottom?

You simply see a limitation of DGIndex that made me drop this solution. I now use Autocrop with a simple script like this :
Quote:

Mpeg2Source(...)
Autocrop()
This will give you visually the left and top border and thhe height and width to crop (so you can determine the right/bottom border). There is no round to 8 like in DGIndex.
(note: be carefull, Autocrop always gives a left border of 2 pixels even if there is not. But this can be seen easily if you look closer at your sceen).

Else, with DGIndex what I do generally is to take the situation that is the "less worse". I mean if I have to choose between cutting 3 pixels or letting a 5 pixels border, I choose to cut. But if the choice is between cutting 7 pixels or having a 1 pixel border, than I keep the border.

EDIT: I thought you won't do Alien3 :lol:

Zyphon 08-14-2005 08:57 AM

Quote:

Originally Posted by Dialhot
EDIT: I thought you won't do Alien3 :lol:

Lol :lol:, I wanted to do some tests to see how good AutoGK was last week and Alien3 just happened to be the first DVD out of the boxset that I picked up and seeing it was still on my HDD from when I ripped it last week I thought I would run a couple of tests on it before wiping it and ripping the other 3 movies.

Thanks for the further info Phil, is I have just downloaded the Autocrop.dll from AviSynth site and I shall give that a try.

Again thanks again Phil for taking the time to explain to me the art of clipping and cropping. :D

I very much appreciate it. :)

Zyphon 08-14-2005 09:11 AM

Thank you Phil for bringing to light for me this tool Autocrop it is very neat.

Below is a test script that I did with it using a very simple script as you suggested:
Code:

# -= AviSynth v2.5.5.0 script by FitCD v1.2.4 =-
LoadPlugin("F:\Program Files\DIKO\avisynth plugins\MPEG2Dec3.dll")
LoadPlugin("F:\Program Files\DIKO\avisynth plugins\AutoCrop.dll")
Mpeg2Source("G:\MyMovies\Conversions\Alien3.d2v")
Autocrop()

http://www.digitalfaq.com/archives/i...2005/08/25.jpg
Thanks to ImageShack for Free Image Hosting

You say that Autocrop will give always give a left border of 2 pixels. In my case it is 10, should I subtract 2 from that to make it 8?

EDIT: The four crop settings values you get at the end, do you enter these for Lanczor Resize?

EDIT2: I can see on the right hand side cropping that Ripley's glove is overlapping the cropline and slightly can been seen on the other side of the line, is this just me? Can it be ignored?

Thanks Phil. :)

incredible 08-14-2005 09:41 AM

Or use my little tool I wrote for displaying and cropping d2v contend out of DgIndex (not DVD2AVI!). Its part of a new Video Appl. Im writing. I quickly added for your purpose a little result TextFrame to show the crop results and compiled it again.

It Autocrops using Mod2.
A copy of DgDecode.dll has to be in the same Folder as this appl.

http://home.arcor.de/packshot/dgdecodeplayback.exe

The movie automatically starts, press stop and hit Autocrop.

http://www.digitalfaq.com/archives/i...2005/08/26.jpg

kwag 08-14-2005 10:22 AM

Quote:

Originally Posted by incredible
Or use my little tool I wrote for displaying and cropping d2v

Cool Inc :cool:

-kwag

Zyphon 08-14-2005 10:51 AM

@incredible

Andrej you are a lifesaveer! Thank you. :D

Was this written using PureBasic?

Looks really cool, thanks buddy I shall download it and run some tests now. :)

incredible 08-14-2005 10:52 AM

Quote:

Originally Posted by Zyphon
Was this written using PureBasic?

Yes

Quote:

Looks really cool, thanks buddy I shall download it and run some tests now.
Its in mega Beta State and just testet on 3-4 diff Movies.

;)

Dialhot 08-14-2005 11:18 AM

Quote:

Originally Posted by Zyphon
You say that Autocrop will give always give a left border of 2 pixels. In my case it is 10, should I subtract 2 from that to make it 8?

You answered yourself in the following lines :
[/quote]EDIT2: I can see on the right hand side cropping that Ripley's glove is overlapping the cropline and slightly can been seen on the other side of the line, is this just me? Can it be ignored?[/quote]
As you can see, autocrop seems to have the bad habit to do a 2 pixel error on right - left (it does not suffer abotu that for top/bottom).

Quote:

EDIT: The four crop settings values you get at the end, do you enter these for Lanczor Resize?
No, I prefer to let FitCD giving me correct values that take in account the diff A/R of the source and the target I use. ANd also because I use an overscan that autocrop can't compute for you.

@Inc
I will try your app. It is nice.

Zyphon 08-14-2005 12:09 PM

Quote:

Originally Posted by incredible
Quote:

Originally Posted by Zyphon
Was this written using PureBasic?

Yes

Cool. :D

Quote:

Originally Posted by incredible
Quote:

Originally Posted by Zyphon
Looks really cool, thanks buddy I shall download it and run some tests now.

Its in mega Beta State and just testet on 3-4 diff Movies.

;)

Still it is still looking good, look forward to the updates this tool looks very promising. :)

Zyphon 08-14-2005 12:33 PM

@Incredible

Unfortunately when I try to enter a .d2v file made with DGIndex 1.4.0 Final, your tool crashes and I then quits. :(

I am at a loss what could cause this, My OS is XP Pro SP1.

@Dialhot

Phil sorry to carry on, just a liitle more advice needed. What values exactly from Autocrop do I need to input into FitCD?

Also what should I round to? Mod 2,4,8 or 16?

I like to use overscan=2 also. In my destination, the round to is set to32 for the width but the hight is set to 16 in the slider bar as seen in the first picture.

I am really confused with the round to and which mod to use. Sorry for the dumb questions but I am still such a noob when it comes to using FitCD.

Zyphon 08-14-2005 12:46 PM

Quote:

Originally Posted by Zyphon
@Incredible

Unfortunately when I try to enter a .d2v file made with DGIndex 1.4.0 Final, your tool crashes and I then quits. :(

I am at a loss what could cause this, My OS is XP Pro SP1.

:douh:

I just realised after reading your post again, I forgot to put the DGDecode.dll into the same directory as your tool. My so dumb!! :oops: :oops:

Now it works perfectly, now please excuse me while I go find my brain. :lol:

Zyphon 08-14-2005 12:55 PM

Here are the crop results from your tool Andrej.

http://www.digitalfaq.com/archives/error.gif
Thanks to ImageShack for Free Image Hosting

Mind you if you look at the bottom crop line it overlaps the credits slightly.

A very good tool btw though, I hope for future releases there may be a slider bar so you can see how the crop lines look at mid point of the movie.

Great work Andrej. :D

Now with the settings from your tool, I have put these into FitCD:

http://www.digitalfaq.com/archives/i...2005/08/27.jpg
Thanks to ImageShack for Free Image Hosting

I still don't get the round to options though and would appreciate a tip in the right direction.

Thanks in advance. :)

Dialhot 08-14-2005 01:04 PM

Okay, so I resume all the informations you gave :
- Autocrop gives left = 10, top = 72, width = 704, height = 430
- Autocrop is giving a two pixel too big border on the right side. So correct width should be 706.
- you want a oversan about two and a dest res to 704*576.
This is how I set my Fitcd :
http://www.digitalfaq.com/archives/i.../2005/08/7.png
As you can see, this will crop too much the source (694 x 430). In this situation I will go for an oversan of 1 (or 3) to have a lesser cropping (706 x 426) :
http://www.digitalfaq.com/archives/i.../2005/08/8.png

Zyphon 08-14-2005 01:35 PM

@Dialhot

Thank you Phil, I get the same results by changing to overscan=1.

Is the round to 2 & 2 ok for the Source?

Also have you tried unticking the Anamorphic, you get huge black borders I take it this will mess up the AR?

Thanks as always Phil for your very insightful informationa and help it is greatly appreciated. :)

Dialhot 08-14-2005 01:45 PM

Quote:

Originally Posted by Zyphon
Is the round to 2 & 2 ok for the Source?

Yes it is. It can be refused by some filters anyway (round to 4 in this case). And if I'm not wrong, if your source is interlaced then 4 is the minimum also (to be confirmed).

Quote:

Also have you tried unticking the Anamorphic, you get huge black borders I take it this will mess up the AR?
Yes if you did it for the source (you must check the box according to your source parameters). But for target, it's your own choice. FitCD will just compute correct values according to what you choosed.


All times are GMT -5. The time now is 10:23 PM  —  vBulletin © Jelsoft Enterprises Ltd

Site design, images and content © 2002-2024 The Digital FAQ, www.digitalFAQ.com
Forum Software by vBulletin · Copyright © 2024 Jelsoft Enterprises Ltd.