PDA

View Full Version : deinterlacing DV video, avs script advice


ricardo.santos
27th August 2007, 19:47
Hi everyone!

Im trying to convert a 15min DV file captured with a sony handycam, i want to convert it to DVD with Quenc.

I went on the guides section and found this avisynth script example:

DirectShowSource("C:\band\2\01.avi", 25)
bob

its a 15 min performance of a friends band and when playing the avs their arms kind of have a "saw" effect, that saw effect its not the interlace effect, is there any better way of doing this and eliminate that effect?

Also what do i have to add at the end of the scrip so that Quenc can process the scrip without ahving colourspace error messages.

Thanks once again

smok3
27th August 2007, 19:52
try:

LoadCPlugin("t:\he\path\yadif.dll")
avisource("t:\he\other\path\band.avi")
converttoyv12()
yadif(mode=0)

(that is, if you want to deinterlace)

yadif thread:
http://forum.doom9.org/showthread.php?t=124284
dunno about aliasing.

another way:
http://forum.doom9.org/showthread.php?t=110582

neuron2
27th August 2007, 20:05
If you are going to make a DVD, there is no need to deinterlace, and in fact, it's undesirable to do so. Just encode the AVI to DVD-compliant MPEG2 using interlaced encoding. Then author the DVD.

ricardo.santos
27th August 2007, 20:09
Thanks a lot smok3!

Its better now! i

Dont i need to specify 25fps in the script?

Thanks

neuron2
27th August 2007, 20:11
Why do you want to bob it? You're just wasting bits in your encode.

ricardo.santos
27th August 2007, 20:15
If you are going to make a DVD, there is no need to deinterlace, and in fact, it's undesirable to do so. Just encode the AVI to DVD-compliant MPEG2 using interlaced encoding. Then author the DVD.

Neuron i was kind of expecting that statment from you, i read that before, is there a "misconception" about needing to deinterlace pal matreial when converting it to dvd? If yes, why is it that so many people do it and why there are deinterlacers?

What i´ve heard is that if im distributing the video for home dvd players i shouldnt deinterlace it, but if im distributing it to see it on pc´s i should deinterlace.


Who´s right?

Why do you want to bob it? You're just wasting bits in your encode.

read it on a guide :

100fps.com i think

smok3
27th August 2007, 20:35
techincally speaking: you should not deinterlace, subjectively: i do like the (even fake) progressive look better in 97% of cases (the 3% left is things like: sports, formula1 and similar).

Blue_MiSfit
27th August 2007, 20:55
If you are going to view the encode on a progressive display (computer, or HDTV), then you can achieve higher quality by deinterlacing ahead of time.

Remember though, that you're throwing away half the motion if you do. The DVD spec doesn't allow for 50/59.94p, so you shouldn't bob deinterlace (unless you decimate afterwards). You can only create 23.976p, 25p, and 29.97p DVDs.

It's a toss up :)

Most people watch DVDs on standard NTSC / PAL interlaced CRTs anyway..

If you DO decide do bob / decimate, then please use something better than a dumb bob(). It's really only for testing purposes. Use YADIF for something fast, MCBob for something slow, or TDeint for something in between. Just some suggestions..

~Misfit

ricardo.santos
27th August 2007, 21:04
im not using bob.

i´m using the YADIF "plugin" on a 8 min video to test the quality out, whats the worst "case scenario" if i choose not to deinterlace?

ricardo.santos
27th August 2007, 21:13
Just finished the test and it looks good.

One last question, unfortunally i forgot to deactivate the "night" function while recording, i have about 20 min of footage that has to much white/bright.

Any chance of compensating this with avisynth?

Thanks

smok3
27th August 2007, 21:50
i had some good results using this:
http://strony.aster.pl/paviko/hdragc.htm
(but not in all cases)

Jay Bee
27th August 2007, 23:41
Again: if you're encoding DV for DVD and you are deinterlacing then you are unnessesarilly cutting the resolution in half. The temporal resolution that is.

Whenever you read about deinterlacing you have to keep in mind that most people are working with movie content.

Change yadif to mode 1 to see what I'm talking about.

*.mp4 guy
28th August 2007, 07:22
The motion content barely ever matters that much, in my experience, and of course encoding interlaced results in heavier compression, so I usually deinterlace everything. It is, as always, imporatant to take things on a case by case basis, one-size-fits-all thinking is a good way to mangle 49.9% of your projects.

Jay Bee
28th August 2007, 18:49
The motion content barely ever matters that much

I guess that's the part where I strongly disagree with most people. But as you say, everyone needs to find for themselves what the best solution is, on a case by case basis.

2Bdecided
29th August 2007, 15:51
If you are going to view the encode on a progressive display (computer, or HDTV), then you can achieve higher quality by deinterlacing ahead of time.

But DVD playback software on PCs, and hardware/software in HDTVs (I think you mean "flat panel displays" - HD or SD is irrelevant here), can both deinterlace, and maintain the smooth movement in the process because they can send 50p or 60p to the display.

Whereas if you deinterlace, and then author a DVD (which can't cope with 50p or 60p, so we're talking 24p with 3-2, 25p or 30p), then (as others have said) you've changed smooth movement to stuttery/flickery movement.

There are some Philips TVs which can re-create the smooth movement again, but the vast majority of playback scenarios (of every type, including PCs) will maintain the newly created stuttery/flickery movement.


If you want the "filmic" look, fine. Dropping the frame rate gets you part way there. Half the industry seems to think it's great. It makes me vomit, but I'm never going to watch your footage.

However, if you're making a DVD and you aren't trying to make the footage look different, for goodness sakes don't deinterlace it or you'll wreck it.


It seems to me that there are lots of people used to watching film content with 3-2 pulldown, or film content in general, or animation, or video content on PCs where the frame rate of the monitor doesn't match that of the content - four situations where you will never see "real life"-like smooth movement. Such people can happily destroy the smooth movement of interlaced video clips, and not know or care.

However, a lot of us spend most of our lives not watching stuttery 24p movement on a screen. Our home videos are not carefully contrived to work OK at 24p like a Holywood epic, but have real people moving around unpredictably, and by necessity include pans, some of them quite fast. I don't know about other people, but I own a video camera so that I don't have to put up with the 640x480p30 that I can get out of my still camera, because it's just too stuttery/jerky and un-lifelike.


Back to the original post: adding the filmic look, via deinterlacing and various other methods, might be appropriate for a music video. I've often seen this done to parts of the footage, and cutting between this and straight video, for artistic effect. It can bring contrast to an otherwise monotonous sequence. Mind you, done badly, it can be painful to watch. If you give a damn about this project, you should really try both and decide which looks best with this content.

Cheers,
David.

Blue_MiSfit
30th August 2007, 18:07
That's a very good point, and I totally agree that preserving the motion is crucial for most content.

My only point is that for some delivery methods like the web, you can't deliver interlaced content and assume it's going to be bobbed on playback. On a TV, you can safely assume that, but on YouTube (for example), you've got 30p at best.

In these instances, you're much better off using high quality deinterlacing in AviSynth to 30p.

All assuming 60i input of course ;)

~MiSfit

2Bdecided
30th August 2007, 20:18
Of course. If the delivery has to be progressive, deinterlacing is a must.

Pity all us poor souls in 50Hz countries who have no easy way of hitting the "web standard" of 30p with our content! (without motion judder, or painfully slow frame rate conversion, that is).

Cheers,
David.

scharfis_brain
30th August 2007, 20:38
why is 30p a web standard?

25p should be perfectly possible as well!

sometimes I encoded my videos to 16.6667 fps (every third field) or 12.5 fps (every fourth field) for better Image quality

Leak
30th August 2007, 23:55
why is 30p a web standard?
A distinct lack of TFT screens that can either do 50 or 75 Hz (or do them well, for that matter) might be part of the problem...

np: Fluke - Kitten Moon (Risotto)

smok3
31st August 2007, 09:33
2Bdecided, no you will not get filmic look (filmic look is actuallly mostly about DOF imho, which means it would be possible to have great filmic look even on interlaced stuff), it is just the interlaced nature that makes me vomit :)

2Bdecided
31st August 2007, 11:36
50Hz is almost impossible in the PC world (there are some nice hacks to feed a "PAL" TV RGB directly from certain video cards, but that's not a PC monitor). 75Hz has 2-1 motion judder. 100Hz would work OK on LCD, but is rare. 100Hz on CRT leads to double images from 50Hz content unless it's frame rate converted.

Whereas every PC does 60Hz just fine (though with visible flicker, if CRT). Displaying 30p and 15p content at 60Hz is trivial.

Mind you, you can take 50i content, make it 30p by bobbing and dropping frames, and then send it to someone who has their monitor set at 75Hz. The judder on that is unbelievable.


smoke3,

In my language filmic ~= film. By "filmic look" I mean that horrible drop-field weird gamma effect they put on a lot of cheap TV these days, assuming it looks better / more expensive (they are so wrong). Sometimes it's used to disguise cheap miniDV-sourced footage.

As you say, you can have shallow depth of field, and some distortion/softening of the colour palette, even on, say, 1080p60 material. I think that looks lovely (though I've only seen it once). It's the motion stutter of 24p/25p which I object to.

(and before you ask, I think 3-2 pulldown just looks like the TV/PC/player is faulty!)

Cheers,
David.

Xitsa
31st August 2007, 21:34
try:

LoadCPlugin("t:\he\path\yadif.dll")
avisource("t:\he\other\path\band.avi")
converttoyv12()
yadif(mode=0)

(that is, if you want to deinterlace)

yadif thread:
http://forum.doom9.org/showthread.php?t=124284
dunno about aliasing.

another way:
http://forum.doom9.org/showthread.php?t=110582
Back to the ways to deinterlace:
Is there any reason to use yadif in securebob in MVBob?
It is using EEDI by default now.
Has somebody compared diffirent deinterlacers to know there problems?
How to choose between them?
What kind of scenes should I find to test for speed/quality ratio?
Did I missed plena guide somehow?
:helpful:

smok3
31st August 2007, 21:48
yadif is way faster than the rest and besides some aliasing i don't see a serious problem with it.

scharfis_brain
31st August 2007, 22:02
@2Bdecided:
that's why I like my big CRT.
50 Hz SD stuff I watch at 150 Hz refresh rate without any vertical scaling (1024 x576 screen resolution)
and NTSC stuff I watch at 120 Hz.

so there is no flicker and everything runs smoothly.

zilog jones
31st August 2007, 22:58
I'd also be one to keep interlaced video interlaced wherever possible, and only deinterlacing when you have no other choice, e.g. uploading to stuff like YouTube where you're stuck with 320x240 cack.

Even a lot of broadcasting production companies seem to be loving deinterlacing these days. I've seen many programs recently consisting mostly of archive video footage - all "filmised" (probably so they can resize it to 16:9 - they might as well reduce the vertical resolution even more while they're at it!) - and it looks horrible! Especially with older footage, the tape droupouts and characteristic trailing from vidicon tube cameras just looks completely unrealistic.

I watch interlaced video on my PC using ffdshow to de-interlace, with my Trinitron on 768x576 @ 100Hz (never tried if it could go up to 150... :) )

Jay Bee
3rd September 2007, 11:28
Nice posts 2Bdecided. Reassuring to see that there are other people who can't believe the way interlaced content is handled in internet land.