Log in

View Full Version : IVTC problem on a clean source. please help


solvalou
1st August 2004, 08:57
Hi.

I tried smartdecimate and decomb 5.2.1 on this video but both fail to detect combed frames on fade in and fade out sequences. If you check it on vdub you will see that the source is very clean so the "clean clean clean interlaced interlaced" pattern is very easy to detect. On all the other parts IVTC works perfectly, Im just having problems on fade ins and fade outs.

Here is a sample clip that has both fade in and fade out.
Any help will be greatly apreciated
http://home.ripway.com/2004-1/61792/clip.rar

btw. no deinterlace solution please. the video is really clear so I dont know what is happening. Maybe all deinterlacers have bugs dealing with fade sequences ? :confused:

Leak
1st August 2004, 09:50
Originally posted by solvalou
On all the other parts IVTC works perfectly, Im just having problems on fade ins and fade outs.

the video is really clear so I dont know what is happening. Maybe all deinterlacers have bugs dealing with fade sequences ? :confused:

If you use SeparatedFields and look at the video, you'll see that the fades apparently were applied after the telecine, i.e the brightness decreases with each field instead with each frame, and the duplicated fields inserted by the telecine process also don't have the same brightness as the field they were copied from - that means Telecide can't detect those fields as being duplicates.

Can't really help you there; the only solution would probably be to stretch the images' histogram for making the IVTC choices or something like that, but that would only really work for fade-ins and fade-outs.

<EDIT>
This makes Telecide do what I mean, but of course those frames should only be used for deciding what to match, not for the final output:

MPEG2Source("test.d2v")

ScriptClip(last,"""
\ min=YPlaneMin(5)
\ max=YPlaneMax(5)
\ Levels(min,1,max,0,255)
\ """)

Telecide(order=1)
</EDIT>

np: Luke Vibert - Harmonic (YosepH)

scharfis_brain
1st August 2004, 10:32
try
smartdecimate(24,60)

it works perfectly with your sample

GeneralMartok
1st August 2004, 10:39
Using Telecide's override function will fix this. Use this script to determine what pattern is being used:


LoadPlugin("C:\...\AviSynth 2.5\plugins\DGDecode.dll")
LoadPlugin("C:\...\AviSynth 2.5\plugins\decomb521.dll")
mpeg2source("C:\clip.d2v",idct=5)
Telecide(order=1,guide=1,post=3,show=true,ovr="clip.tel")


The pattern is ncccn. However, Telecide falls out of pattern during the fade out. Create a textfile named "clip.tel":


0,180 ncccn

and save it to the same folder as your .avs-scripts.

Load this script:


LoadPlugin("C:\...\AviSynth 2.5\plugins\DGDecode.dll")
LoadPlugin("C:\...\AviSynth 2.5\plugins\decomb521.dll")
mpeg2source("C:\clip.d2v",idct=5)
Telecide(order=1,guide=1,post=0,ovr="clip.tel")
Decimate()


There is no combing anymore and the dupclicates are correctly removed.

Leak
1st August 2004, 12:07
Originally posted by GeneralMartok
Using Telecide's override function will fix this.
[...]
There is no combing anymore and the dupclicates are correctly removed.

Isn't that a bit overkill, though? If you start doing that on every fade you could as well just use SeparateFields, SelectEvery, Trim and Weave for IVTC...

Anyhow, I've just added a normalizedMatch parameter to my BlendBob plugin that'll adjust the histogram of the previous and next frames when matching, and it also works perfectly on this clip.

Of course, my plugin does a bit of smoothing on the source, so it might not help solvalou (yet), but thanks for bringing this case to my attention anyway. :)

np: El-P - Lazerfaces' Warning (Fantastic Damage)

GeneralMartok
1st August 2004, 13:23
Well, this method works. IMHO there is no all automatic soloution for hybrid clips. A little bit of manual tweaking produces better results. It doesn't take so much time.

scharfis_brain
1st August 2004, 13:25
did noone read my post above?

manono
1st August 2004, 16:58
When scharfi speaks, you should listen. :)

GeneralMartok
1st August 2004, 17:29
Allright, SmartDecimate sounds good. I did in fact not read scharfi's post, because it wasn't there when I wrote my answer.

solvalou
1st August 2004, 19:54
Originally posted by scharfis_brain
try
smartdecimate(24,60)

it works perfectly with your sample

Hmmmm... I must be doing something wrong because it doesnt work at all on the vertical pan... only the horizontal pan is correctly IVTCed. Below is my script and some image samples of the combed frames on the vertical pan.. also with smartdecimate I have lots of other problems in long freezed scenes. For example when there is a horizontal pan and the camera stops, then smartdecimate starts creating crappy frames like if the resolution was lower and it happens on 90% of the scenes. I don't understand why it happens as the video is clean and the frames where it happens dont have any motion at all.. they are static frames ( i included some image samples also and the clip for you to test).

image samples:http://home.ripway.com/2004-1/61792/screenshots.rar
new clip of static bug: http://home.ripway.com/2004-1/61792/test3.rar

script:
LoadPlugin("C:\Program Files\Video\AviSynth 2.5\plugins\MPEG2Dec3dg.dll")
LoadPlugin("C:\Program Files\Video\AviSynth 2.5\plugins\avisynth_c.dll")
LoadCPlugin("C:\Program Files\Video\AviSynth 2.5\plugins\smartdecimate.dll")
mpeg2source("C:\DVD\teste.d2v")
Trim(0,43035)
smartdecimate(24,60)
AudioDub(BlankClip())
converttoyuy2()

scharfis_brain
1st August 2004, 20:04
try disabling the bobbing feature of smartdecimate:

a=doubleweave()
smartdecimate(24,60,bob=a,weave=a)

solvalou
1st August 2004, 20:16
Yes.. it worked :) but now its letting some VERY easy to detect combed frames pass as if it was progressive :(

also.. I was wondering why it works for you on vertical pan and for me it doesnt ? Could it be that im using dvd2avi 1.77.3Dg with mpegdec3dg.dll and you use dgdecode ? :confused:

example of vertical pan (no fade here, plain simple vert pan):
http://home.ripway.com/2004-1/61792/sample.jpg

scharfis_brain
1st August 2004, 21:09
are you sure, the vertical pan is 30p or 24p (telecined) ?
could it be that this pan is pure 60i ?

btw. smartdecimate works on the sampe you provided with your initial post, but I cannot assure it is working for the whole movie.

solvalou
2nd August 2004, 07:34
Originally posted by Leak
Anyhow, I've just added a normalizedMatch parameter to my BlendBob plugin that'll adjust the histogram of the previous and next frames when matching, and it also works perfectly on this clip.


I tried your plugin but it also couldnt process the vertical pan with fade out. the horizontal pan with fade in went perfect tho.

Theres also something strange, on a lot of pan scenes it is leaving like a ghost, but its almost unnoticeable but its there. Is there a way to get rid of it ? messing with the plugin parameters ?

Leak
2nd August 2004, 09:16
Originally posted by solvalou
I tried your plugin but it also couldnt process the vertical pan with fade out. the horizontal pan with fade in went perfect tho.

Oh, it can process the vertical pan now, but that's only in my development version - it'll be in the next release.

Theres also something strange, on a lot of pan scenes it is leaving like a ghost, but its almost unnoticeable but its there. Is there a way to get rid of it ? messing with the plugin parameters?

Not really, though you could try lowering the threshold parameter of KernelBob - the right way to get rid of it is for me to implement real fieldmatching instead of frame blending. That's my goal for the next release...

I've also noticed that KernelDeint has a small bug - it uses different motion masks (instead of one for both) for the two chroma planes, which can lead to slight chroma ghosting.

Oh, and which series is that, by the way?

np: Bigg Jus - The Story Entangles (The Under Flippage) (Black Mamba Serums v2.0)

Bulletproof
3rd August 2004, 04:21
This seems to sort of work:

Telecide(order=1,back=1,nt=55,post=0)
Decimate(mode=2,quality=3)

It just misses a bit of the fading, but you could probably fix that by just putting post processing on.

Mug Funky
12th August 2004, 11:12
i've got a similar problem with Evangelion Platinum edition (R1 NTSC)...

the titling in the intro sequence appears to be 30p somehow (or maybe 24p on a different cycle).

seeing as the fade-outs on the titles are such an insignificant part of the program, i decided to simply do a vertical blur/unblur on it to blend the fields together (after telecide of course). works pretty good when you combine it with comb-masking (though it still hits sharp edges a litte, this isn't really a problem on an interlaced screen, and the alternative would be field-matching through script, which my computer absolutely cannot handle in a reasonable amount of time).