Log in

View Full Version : Need help with anime encoding (Transformers)


Bh4i
8th December 2006, 22:44
Since i bought season 1 of Transformers and planning to buy all seasons, i want to rip all episodes.
There is a total of 98 episodes. Source for all episodes will be the original DVD9's. Quality of source is quite good imo, but i think it can be improved (problem is i dont know exaclty how :p )

Screens:

http://maxupload.com/img/D88555F9.jpg
http://maxupload.com/img/B97D1364.jpg
http://maxupload.com/img/DD223B15.jpg
http://maxupload.com/img/A18A0AFE.jpg
http://maxupload.com/img/834DA9D4.jpg

Sample 1 (19,8 MB) (http://maxupload.com/88BAAEEA)

Sample 2 (10,0 MB) (http://maxupload.com/349221E9)

Current script:LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\FFT3DFilter\fft3dfilter.dll")
DGDecode_mpeg2source("D:\Transform Rip\VTS_04_1.d2v",info=3)
ColorMatrix(hints=true)
FFT3DFilter(sigma=3,bw=32,bh=32,bt=3,ow=16,oh=16)
edeintted = AssumeTFF().SeparateFields().SelectEven().EEDI2(field=-1)
tdeintted = TDeint(edeint=edeintted,order=1)
tfm(clip2=tdeintted).tdecimate(mode=1,hybrid=1)
FFT3DFilter(sigma=3,bw=32,bh=32,bt=3,ow=16,oh=16)

Some points:

This is my first anime encode :rolleyes:
As u can see the script is very simple.. i do have included fft3dfilter, cause i read somewhere these settings are good for anime denoising. But imo fft3dfilter is to slow.. it would be nice if there was a good alternative
I want to backup all 98 episode on 2 DVD5's. That means the size of one episode must be ~88 MB with a average runtime of ~23 min/episode. Im planning to use x264 as encoder, cause i think its the best for this job. I do know its only possible to play the rips on a PC, but thats no problem :cool:
As u can see in screen #2 (http://maxupload.com/img/B97D1364.jpg) and in sample 2 (""), there r some weird blue vertical lines. I dont think there is any way to fix this, but if im wrong i would like to know :)
The deinterlace method i got from MeGUI, and it seems to be good...
Are there any settings which i should change in MeGUI. Is there something really wrong when i choose a MeGUI preset?
ANY suggestion for using other scripts, other filters etc are appreciated


:thanks:

[MA]Debito
9th December 2006, 06:52
I think you should put a Crop(8,0,-4,0) after your filters but before your resize. Would take them left and right borders right off.

And a LanczosResize(640,480) at the end (assuming it's a 4:3 source)

check
9th December 2006, 12:15
Something along these lines seems to work well:
MPEG2Source("", cpu=0)
crop(8,0,-8,0)

edeintted = AssumeTFF().SeparateFields().SelectEven().EEDI2(field=-1)
tdeintted = TDeint(edeint=edeintted,order=1)
tfm(clip2=tdeintted).tdecimate(mode=1,hybrid=1)

hqdn3d(6)
awarpsharp(7,2)
limitedsharpenfaster(strength=30)

Bh4i
9th December 2006, 23:34
Wow check, thats a awesome script! :)

It works fantastic and is also fast. And it seems i can use this on any anime (cant see anything specific for this source).

There is a very little bit blocking, but i dont think that can be helped. Thnx very much :)

@[MA]Debito: I did the crop, but not the resize. Is there any special reason why i should resize?

Bh4i
10th December 2006, 01:33
The rip does have a wrong AR.. i did not resize, only: crop(8,0,-8,0)

Original AR is 4:3 (720x480).

Someone know how to crop, cause MeGUI doesn really help in this case...

check
10th December 2006, 01:48
The DAR is 4:3, and the AR error in using 720 over 704 is less than 5%.

Bh4i
10th December 2006, 01:54
But i still wonder some things, dont want to open a new topic, it would be nice if u can answer.

Im still a bit confused about AR:

1) When i open the source file in any mediaplayer, it plays the file in 4:3 format
2) When i open the source file in virtualdub or MeGUI preview windows, WITHOUT modifying anything, it shows me a wrong AR
3) When i open the encoded file in MPC, it gives me a little bit stretched video, but i can easily correct this. When i run mediainfo over the encoded file, it still gives me a AR of 4:3

Video #0
Codec : H.264
Info : H.264 (3GPP)
PlayTime : 22mn 47s
Bit rate : 2082 Kbps
Width : 704
Height : 480
Aspect ratio : 4/3
Frame rate : 23.976 fps
Bits/(Pixel*Frame) : 0.257
Size : 130604232

Im a bit confused :confused:

foxyshadis
10th December 2006, 04:16
Vdub, megui, and their kinfolk have no automatic AR correction. zip, zero. If you need it, right-click one of the panes in vdub to set the DAR for it. (But this is display-only, this information will not translate to, say, xvid.)

Once you crop the video, it's no longer 4:3. It's now approx 13:10. ((640/720*704)/480=1.3037037...)

Bh4i
11th December 2006, 02:39
Its clear know, thnx for the help :)

chipzoller
11th December 2006, 03:23
Bh4i, I would recommend that you do an ivtc instead of just deinterlacing. This would 1.) speed up your encode and 2.) increase compressibility and quality.

While the method megui suggests for deinterlacing is good, what you need is an ivtc (Inverse telecine). Look at tivtc plugin for functions tfm and tdecimate.

Mug Funky
11th December 2006, 03:49
IIRC not all of transformers is clean telecine... it's all off one-inch analog tape and quite blurry at times (not as blurry as the R4's... oh well, you can't win them all :)).

chipzoller
11th December 2006, 03:52
True, but IIRC I did a backup of one of these discs to x264-in-mkv and *think* I just did an ivtc with a mode 2 decimation and all was well.

Chainmax
11th December 2006, 13:26
I'd suggest this:

source loading
colormatrix(hints=true)
IVTCing/Deinterlacing <-- with TIVTC/TDeint+EEDI2 respectively
DeGrainMedian()
BicubicResize(512,384,0,0.5)
RemoveGrain(mode=5)
aWarpSharp(depth=16,cm=1)

DeGrainMedian is there because it should be about equivalent to FFT3DFilter with a sigma of 3 but quite faster. The neutral bicubic resizing (i.é: the 0,0.5 switch) setting is a good compromise between sharpness and compressibility, and aWarpSharp does an amazing job at sharpening without actually sharpening (just thinning lines). Take into account that even using MeGUI's AE-MaxQuality preset, 512x384 is really pushing it and you should probably bump the deblocking to 2,2 or maybe even 3,3.

Serbianboss
11th December 2006, 13:40
Sorry for maybe offtopic, what is script for TDeint+EEDI2 for BFF material ?

Chainmax
11th December 2006, 22:22
How to IVTC

For TFF clips:
AssumeTFF()
Interp = SeparateFields().SelectEven().EEDI2(field=1)
Deinted=TDeint(order=1,field=1,edeint=Interp)
TFM(mode=6,order=1,PP=7,slow=2,Clip2=Deinted)
TDecimate(mode=1)

For BFF clips:
AssumeBFF()
Interp = SeparateFields().SelectEven().EEDI2(field=0)
Deinted = TDeint(order=0,field=0,edeint=Interp)
TFM(mode=6,order=0,PP=7,slow=2,Clip2=Deinted)
TDecimate(mode=1)



How to Deinterlace

For TFF Clips:
AssumeTFF()
Interp = SeparateFields().SelectEven().EEDI2(field=1)
TDeint(order=1,field=1,edeint=Interp)

For BFF Clips:
AssumeBFF()
Interp = SeparateFields().SelectEven().EEDI2(field=0)
TDeint(order=0,field=0,edeint=Interp)



How to Bob (using MVBob's SecureBob)

For TFF Clips:
AssumeTFF()
SecureBob()

For BFF Clips:
AssumeBFF()
SecureBob()

Serbianboss
11th December 2006, 23:35
This combination Tdeint and EEDI2 is using for making divx.

For example if we have source(Pal,dv avi,interlaced) and want to make divx and deinterlance and resize does this is ok:


AVISource("C:\Documents and Settings\Nenad\Desktop\pal.avi")
AssumeBFF()
Interp = SeparateFields().SelectEven().EEDI2(field=0)
TDeint(order=0,field=0,edeint=Interp)
bicubicresize(512,384)


Or can we use limitedsharpen faster to resize, does will that be better instead bicubic resize.

bananacreamandpeca
19th January 2007, 03:21
I'd suggest this:

source loading
colormatrix(hints=true)
IVTCing/Deinterlacing <-- with TIVTC/TDeint+EEDI2 respectively
DeGrainMedian()
BicubicResize(512,384,0,0.5)
RemoveGrain(mode=5)
aWarpSharp(depth=16,cm=1)

DeGrainMedian is there because it should be about equivalent to FFT3DFilter with a sigma of 3 but quite faster. The neutral bicubic resizing (i.é: the 0,0.5 switch) setting is a good compromise between sharpness and compressibility, and aWarpSharp does an amazing job at sharpening without actually sharpening (just thinning lines). Take into account that even using MeGUI's AE-MaxQuality preset, 512x384 is really pushing it and you should probably bump the deblocking to 2,2 or maybe even 3,3.

I like it, thanks! Never knew about awarpsharp, always used
Msharpen wich does a pretty good job at edge sharpening.

Though I'm encoding He-Man right now, and *only* for this cartoon I find the thicker blacklines add something to it
wich make sme feel more like back in the 80's

But my question is, will thicker black lines in anime effect
compressibility?

Thanks

foxyshadis
19th January 2007, 03:32
Not really, though overly sharp edges might. There's a script out there called FastLineDarken that can give you a little more oomph on the outlines, as well. A shallow warpsharp+fastlinedarken gives an effect I find pleasing for those old cartoons.

Test very carefully if you ever use anything but cm=0 in aWarpSharp. It's totally buggy at many resolutions, gives a wild green & violet screen, but if it works with yours that's all that matters.