PDA

View Full Version : IVTC Problem using Gknot's avisynth script


edguit@r
21st August 2002, 19:55
Hi all,

I used an avisynth script generated by Gknot to encode some stuff from the "Lord Of The Rings" DVD. To correct the gamma of original video I added the "levels" command to get a better picture. The source is 4:3 NTSC pure interlaced Video, so I also choosed to do an IVTC using Decomb 3.9. The script looked like this:


##
LoadPlugin("x:\path\mpeg2dec.dll")
LoadPlugin("Z:\path\decomb.dll")
mpeg2source("MyDVD2AVIproject.d2v")
Telecide()
Decimate(cycle=5)
crop(8,0,703,478)
levels(0,1.3,255,0,255)
BicubicResize(544,416,0,0.5)
##

The problem is that VirtualDub gives me an error, telling me that it can not read from the source (???). My DVD2AVI project was made with no field operations (for a future IVTC).

So I made some changes in the avisynth script, having sucess with the following:

##
LoadPlugin("C:\VIDEOA~1\GORDIA~1\mpeg2dec.dll")
LoadPlugin("C:\VIDEOA~1\GORDIA~1\decomb.dll")
mpeg2source("MyDVD2AVIproject.d2v")
Telecide()
Decimate(cycle=5)
crop(8,0,703,478)
BicubicResize(544,416,0,0.5)
levels(0,1.3,255,0,255)
##

With this script I could open the source, but the encoding was slow like hell. It took about 5 hours only for first pass on DivX 5-two-pass encoding. The total encoding time was 9 hours and 40 minutes. The result video was fine to me. No problems at all. The Video was 01 hour and 20 min long.

Did I do anything wrong?

I am using an Athlon XP 1600+/512Mb DDR/Soyo Dragon Plus.
The Avisynth version is 1.0beta6.

By the way, is there any better script solution to encode a pure interlaced NTSC video? The commands in Decomb/Avisynth to peform a IVTC on a hybrid video source (Film Progressive/Ntsc Interlaced) are the same I used above?

I'll apreciate any comments and help.

Thanks.

hakko504
21st August 2002, 20:23
Use:crop(8,0,704,478)

neuron2
21st August 2002, 20:40
"Pure 3:2 NTSC interlaced video" is a contradiction in terms. Do you mean pure 3:2 telecined progressive material or pure interlaced video material?

edguit@r
21st August 2002, 21:13
To neuron2,

When I wrote "4:3 NTSC pure interlaced Video", i mean pure NTSC interlaced video with format 4x3 (screen format). "Pure" because the whole video is interlaced, not progressive or interlaced/progressive.

Sorry about the confusion.

How do I Know if a video is 3:2 telecined? Any hint?

Thx.

edguit@r
21st August 2002, 21:15
To hakko504,

Why crop(8,0,704,478)? I has to be a multiple of 4? The code: crop(8,0,703,478) was given by GKnot.

hakko504
21st August 2002, 21:22
Some filters require mod4 or even mod16 resolutions. However, when using YUY2 colorspace color information is always stored in pairs, so the width must be mod2. Some never versions of AVIsynth does adjust the vaue automatically, but to be on the safe side always use mod2 resolutions for width. Personally I feel GKnot is misbehaving when it produces odd values for crop.

edguit@r
23rd August 2002, 00:00
To hakko504,

Sorry. Using "crop(8,0,704,478)" doesn't work either. VirtualDub can not read from source.

dividee
23rd August 2002, 01:36
I don't know why the first script doesn't work, but the speed issue could be related to the limited memory usage in 1.0b6 (see this (http://forum.doom9.org/showthread.php?s=&threadid=31333) thread). I suggest either going back to 1.0b5 or the brand new 2.05.

manono
23rd August 2002, 05:19
Hi-

1. I'm with hakko504-I always make the crops even numbers. And if IVTCing I'll abide by the "Horizontal Crop Divisible By 4" rule.

2. To gain a little speed-put Telecide-Decimate after crop. To gain a lot of speed use this-Telecide(Post=False).Decimate(5). That will disable the deinterlacer. Do it only if you're sure no interlaced frames are sneaking through. And to gain the most speed of all, follow dividee's advice.

3. You said the resulting .avi looked good (no jerkiness?). That should prove it wasn't 4:3 NTSC pure interlaced Video. You can't go by what DVD2AVI tells you. You have to look at the frames. Perhaps you should work your way through hakko504's Sticky (http://forum.doom9.org/showthread.php?threadid=23776) on the subject. Near the bottom is a discussion about the things you want to know. I think he was too modest to point it out, but I don't mind.:)

4. The .avs not working seemed to result from the placement of the levels filter in the .avs. I don't understand either why it didn't work originally, but you frequently have to move things around. If an .avs doesn't work, start commenting things out, open it in VDub and scroll around to see if it crashes. Once you find the offending line, start changing parameters or it's position in the .avs until the problem is solved. Nobody said this stuff was easy.

neuron2
23rd August 2002, 14:37
@edguit@ar

Excuse my misreading of 4:3 as 3:2 :)

If your source really is pure video, then there is no reason to apply IVTC (whether Decomb or other). But it's unlikely that rip would be pure video and, as has been pointed out, if your output is good with the IVTC, then probably it was telecined from progressive source.