PDA

View Full Version : deinterlacing wich method should i use??


harel
6th August 2002, 19:49
i have sony trv 730 i transfer my movie to the pc
with studio 7 in dv type 2 format and i finish work on it u(tiltels cut act..) now i want to make convert it to divx
i need to know which methode of deinterlacing to use
i use virtual dab

10x

saptecai
7th August 2002, 01:06
I am dealing with the same task. I am not sure whether to deinterlace or encode to mpeg-2 and keep it interlaced,yet.
Anyway, check out www.100fps.com (http://www.100fps.com/)

Watz iz biten zeed!

theReal
7th August 2002, 01:40
There's three really good deinterlacers (that I know of) for avisynth: SmartDeinterlace, Fielddeinterlace (in decomb.dll) and TomsMoComp

I found recently that Decomb's Fileddeinterlace seemed to compress best for some DV shots, but maybe it depends on the source material.

50fps is really nice, but the filesize is getting so over the top with DV that I'd only use it if I really needed to (that is for high motion scenes where it really looks much smoother).

harel
7th August 2002, 13:18
Originally posted by theReal
There's three really good deinterlacers (that I know of) for avisynth: SmartDeinterlace, Fielddeinterlace (in decomb.dll) and TomsMoComp

I found recently that Decomb's Fileddeinterlace seemed to compress best for some DV shots, but maybe it depends on the source material.

can u please explain the methode above and how do i use them in virtual dab an avisynth,and when u use them do u chek the all frames are interlaced in the divx 5.02 or u live it at progressive??
The movie i try to encode is a dv type 2 (miroVIDEO DV 300) and
it got alot of movement . its a movie of me flying in the erodium( its an air tunnel that blow air in 120 kmh )
see the link
airodium (http://www.skydive.co.il/eng_erodium.html) i encoded the movie with deinterlac blend with virtual dab and its good but i want excellent.
thanks

ps i use divx 5.02 pro with bitrate of 2500 is it ok or is it to high/low????

theReal
7th August 2002, 17:01
I just wrote a huge post with links and descriptions and stuff, then I accidentally clicked on the "help" button of the Smartdeinterlace dialog and that **** **** **** IE opened the help page and my posting was gone! :angry: :angry: :angry:

OK, again...

Divx 5 pro has an internal deinterlacer that you activate with "all frames are interlaced". I think it's about as good as VDub's blend deinterlace. Better don't use it (= leave it to "all frames are progressive")

You can get a lot of VDub and avisynth filters at Donald Graft's site (temporarily here: http://shelob.mordor.net/dgraft/ )

Tom Barry' TomsMoComp for avisynth is here: http://www.trbarry.com/TomsMoComp.zip

If you don't know how to use avisynth, using SmartDeinterlace for VDub is the easiest, I guess. I always change some of the default settings for DV deinterlacing: use "field only differencing", use "motion map denoising", set the motion threshold to 10 instead of 15. "Blend instead of interpolate" compresses better, but sometimes it doesn't look as good as interpolation, you have to try it.

If you know how to use avisynth, the usage of TomsMoComp and Decomb is pretty easy. For example - Decomb: all you need to do is load the dll and write "Fielddeinterlace()" in the script, that's it! )


2500 is a good bitrate for DV at 640x480 if you enable b-frames. Without b-frames, I'd use 3000 to 3200 (but lower bitrates is what b-frames are there for, so enable them :))
For resizing the video, "precise bilinear" in VDub makes the video more compressible than any of the other resizing filters. Bicubic resizing looks a little better, but then you need higher bitrates.

Instead of 2-pass encoding, you can also use quality based encoding at around 90%-93% quality, so you will only need one pass instead of two and the quality will be constant in any case.


P.S.: Is it just me, or is it the order of the buttons on the Smartdeinterlace-Tab? I almost clicked on "help" instead of "cancel" again. It seems very unnatural to me that "help" is located between the "ok" and "cancel" button...

taudule
7th August 2002, 17:45
Use Tom Barry' TomsMoComp in an avisynth script :
TomsMoComp(0,15,1)

It's the best deinterlacer for DV i've used.
FieldDeinterlace() blurs the video as soon as theres movement in it.

EDITED on 9/3 :
Sorry, i apologize, i didn't read the help file far enough. To compare FieldDeinterlace to TomsMoComp, one must use FieldDeinterlace(blend=false).
However, when i look at the edges of the objects in the frames deinterlaced by FD,

|_
__|_
____|_
______|_
________|_
__________i think i still prefer TMC :rolleyes:
O.

theReal
7th August 2002, 20:40
I think Fielddeinterlace blends per default (I guess you can also turn that off) while Tom's filter interpolates per default. However, Fielddeinterlace compresses a little better, and for DV it's sometimes better to get better compression than 100% quality (the bitrate you have to use is pretty high anyways...)

wongck5
12th August 2002, 18:42
I like the 50fps mode because it gives the smoothest pictures I've ever seen, especially for high motion scene.
However, I needs to lower the resolution to 384x288 (PAL) in order to have better compression quality.

harel
14th August 2002, 11:03
Originally posted by taudule
Use Tom Barry' TomsMoComp in an avisynth script :
TomsMoComp(0,15,1)

It's the best deinterlacer for DV i've used.
FieldDeinterlace() blurs the video as soon as theres movement in it.
O.

can u please explain the methode above and how do i use them in virtual dab an avisynth
10x

neuron2
15th August 2002, 00:10
>FieldDeinterlace() blurs the video as soon as theres movement in it.

Set blend=false and this won't happen, as theReal pointed out.

You know, the help file is there for a reason!!!

Koepi, rescue me. :-)

bbiandov
21st August 2002, 19:04
theReal, how do you specify which field is first in the deinterlace process. Isn't that required - that is to tell your deinterlace filter which field comes first? I know most (including my own) DV camcorders write lower-field-first on the raw AVI file after capture.

I would suspect it matters which field is first for better deinterlacing? or may be I am wrong?

Thanks
BB

theReal
21st August 2002, 20:09
hmm, I know that TomsMoComp has a parameter for either top field first or bottom field first - however, I never used any parameters for Decomb's fielddeinterlace (but it always worked fine).

btw I'm feeling honored that you ask me, but better ask neuron2, I guess he can explain much better how his filter determines field order :D

neuron2
24th August 2002, 03:43
The field order doesn't matter for deinterlacing and I don't know why TomsMoComp requires it to be specified.

Consider that the filter just sees lines of a frame like this (where A is one field and B is the other and I'm showing one column of pixels with the fields offset just for viewing ease):


A
B
A
B <-
A
B
A
B

Now think of our analysis of the pointed-to B pixel. We compare it to the A pixels in the lines above and below to look for combing. If we see combing we replace B with a blend of the A pixels above and below when blend=false, and with a blend of the B and the two As when blend=true.

If the field order changes, we get:


B
A
B <-
A
B
A
B
A

It is clear that the calculation for the pointed to B pixel does not change.

bbiandov
25th August 2002, 21:11
neuron2, is this how smart deinterlace works only, or basically a rule for all methods and programs?

neuron2
26th August 2002, 05:57
This is how Smart Deinterlacer, FieldDeinterlace(), and Gunnar Thalin's area-based deinterlacer work. I cannot speak for others, but it is likely that they pass one field through and analyse the other one, as I describe below. You see, my analysis was incomplete. I'll finish it now.

Referring to my first diagram, the deinterlacer passes the A pixels through without any processing and then processes the B pixels as described. If you change the field order, you'll start passing the B pixels through and analysing the A pixels. Usually this makes no practical difference, but it can. Suppose one of the two fields was a blended field and the other was not. Then you want to pass the non-blended field through, so that the resulting frame doesn't show a blend. This is what the field-order option on TomsMoComp does, i.e., selects which field is to be interpolated. If you have a clip with lots of blends restricted to one field it would be useful to be able to force the desired field to be interpolated. Such clips are rare but nevertheless I plan to add this capability to the next version of FieldDeinterlace.

bb
26th August 2002, 07:31
@neuron2:
But that does not apply to DV sources, does it?

bb

neuron2
26th August 2002, 08:29
@bb

>But that does not apply to DV sources, does it?

What is the referent of your term "that"?

bb
26th August 2002, 10:52
@neuron2:
Sorry for my post not being clear enough.

"That" refers to "that" you have to deal with blended fields. I don't think camcorders produce blended fields.

bb

neuron2
26th August 2002, 14:28
@bb

Your post didn't mention camcorders, it just asked about DV sources. Yes, I believe you are correct, camcorders do not produce blended fields.

taudule
3rd September 2002, 12:53
@neuron2 :

Sorry, i edited my post...

O.

neuron2
3rd September 2002, 13:38
@taudule

TomsMoComp is applying smoothing. That is why you don't see stairstepping versus FD's blend mode. I'll consider adding optional vertical smoothing to FD.

Fredrik
3rd September 2002, 20:26
I've been reading about deinterlacing for some time now, but I'm still looking for the best method. The best one yet for me, is to resize the video to 384x288... :rolleyes:
If someone wants to try and deinterlace and compress a clip I've uploaded (32MB, 8 second unedited DV, straight from a PAL DV camera), you're welcome to try... :D

The clip is available here:
http://bantha.shellpower.net/sample-interlaced.avi

Right-click, and choose "save as".

All my methods has resulted in severe ghosting of the video.

Any suggestions are welcomed! :D

Best regards,
Fred

theReal
3rd September 2002, 23:04
I tried it - no ghosting with "fielddeinterlace(blend=false)" and no ghosting with "tomsmocomp(1,15,1)".

However I find that on action clips like this, 50fps looks best:

seperatefields()
bob()

For even better quality 50fps (but very slow encoding speed), use Gunnar Thalin's VDub filter "Deinterlace smooth" instead of "bob()"

Fredrik
4th September 2002, 10:39
Thanks for your reply, theReal.
I have tried the conversion from 25 fps -> 50 fps. The result is great, and very fluid.
My resulting clip, was 720x288. When playing that clip, you need to resize to 4:3 (720x540) during play. The 50 fps clip (from what I understand), is extremely CPU intensive, requiring a fast CPU to run smoothly.

Should I maybe resize the video?

Is it even possible to make a 50fps DiVX clip working smoothly and with the correct aspect ratio in windows media player?

Best regards,
Fredrik, DV newbie :p

ulfschack
4th September 2002, 11:59
Yes, but if you've ticked "the works" from the 5.02Pro even a 2 GHz will stutter every now and then. But who cares? It's for future use, right? And we all know what happens to computers in the future. You should simply concentrate on getting as good a quality as possible with whatever means available today. ... well, I'm not telling you what to do ... but rather airing my my own HO :)

cheers

PS I accidentally erased my m2v-file (to be put on DVD) for the month of juli. The source tape was overwritten allready. So I made a new m2v - file from my DivX backup simply by unbobbing and weaving the frames back together. I have to say that I was rather pleased by the result. That procedure wouldn't have been possible had I chosen to deinterlace when generating the DivX. I use 97% CQ BTW.

cheers again

theReal
4th September 2002, 13:25
Fredrik, you can resize the clip before encoding - even if you resize down to 384x288, you have a better resolution than 25fps 384x288 because you still have twice the amount of frames.

btwl there's a lot of tests and samples for this topic on www.100fps.com

Fredrik
4th September 2002, 19:22
Originally posted by theReal
I tried it - no ghosting with "fielddeinterlace(blend=false)" and no ghosting with "tomsmocomp(1,15,1)".

However I find that on action clips like this, 50fps looks best:

seperatefields()
bob()

For even better quality 50fps (but very slow encoding speed), use Gunnar Thalin's VDub filter "Deinterlace smooth" instead of "bob()"

"fielddeinterlace(blend=false)" and "tomsmocomp(1,15,1)"?
Is that some avisynth filter? I'm not very familiar with
that program, unfortunatley.
Or are they filters for virtual dub? :confused:

Best regards,
Fred

bb
5th September 2002, 07:34
Both are AviSynth filters; fielddeinterlace() is part of Donald Graft's fabulous Decomb package, whereas tomsmocomp() has been created by trbarry (Tom).

Learn AviSynth, it's worth it!

bb

bbiandov
13th February 2003, 02:05
bb, would you say that D. Graft's filter (deinterleace) for AVIsynth works better than the same exact add-on for vdub? My expectation is that both produce identical results?

neuron2
13th February 2003, 02:46
Hope I can be permitted to comment.

The VirtualDub version is more capable. It supports both field and frame comparison, has motion map denoising, offers a cubic interpolation, and provides a way to view the motion map for easier tweaking of parameters. However, if you choose field comparison and no denoising, the results for equivalent thresholds are very close. But Decomb is faster.

(BTW, I am working on a new deinterlacing strategy that attempts to avoid being caught on the horns of the frame versus field comparisons dilemma. It will also make a new Bob that is fast and solves the flutter problem.)

bb
13th February 2003, 07:22
Originally posted by bbiandov
bb, would you say that D. Graft's filter (deinterleace) for AVIsynth works better than the same exact add-on for vdub? My expectation is that both produce identical results?
Thanks to neuron2 I don't need to answer this (he's the developer, in case you don't know).

@neuron2:
That's great news again. Where are you going to post the news? In a new thread or an existing one?

bb

neuron2
13th February 2003, 07:27
I'll make a new thread but I'm going on vacation for 2 months and it won't be released before I get back.