View Full Version : Question About Software Deinterlacing
kalorx
29th October 2006, 19:03
Hi all. I'm sorry if this is considered in the wrong forum, but this was my best guess as to where it should be.
My question has to do with how software DVD players deinterlace/detelecine or what-not DVD video. I use InterVideo WinDVD 7 Platinum to watch my DVD, and I must say, it does just about a perfect job (as far as I can tell) deinterlacing DVDs.
However, when I rip the DVD and deinterlace them using TDeint or DeComb (or any other plugin or filter) I run into a host of problems. TDeint and DeComb are the best I've found, but even they can't playback perfectly smooth video. With both plugins, if the source isn't decimated to 23.976 fps, every fifth frame is "frozen". Even when decimated, TDeint doesn't always produce smooth vertical pans and DeComb doesn't always produce smooth horizontal pans. Even the direction each plugin seems to be good at isn't wholly perfect; there's some skipping or freezing of a frame or two every here and there, and it's very noticeable (at least to me).
My question is, what do professional DVD playback solutions -- like WinDVD -- do any differently to deinterlace? What makes them so much better than these plugins designed by people who obviously have a great deal of knowledge about the subject and know what they're doing?
Is there any way I can emulate what they're doing? How can I keep my videos at 29.97fps without every fifth frame being frozen, and have perfectly smooth pans in any direction? How do they do it?
tritical
29th October 2006, 22:17
Would you be able to post a sample where WinDVD 7 produces a nice result and none of the avisynth methods do?
kalorx
29th October 2006, 23:03
As far as I know, that isn't possible without a capture card, and I don't have one.
foxyshadis
30th October 2006, 01:35
You can cut a chunk of DVD out with DGIndex or Cuttermaran. A panning scene would probably be best. You don't actually have to record the windvd part, we can compare it ourselves.
kalorx
30th October 2006, 01:50
So you just want a chunk of raw DVD?
EDIT: I'm sorry. That was a really stupid question. Yes, you want a raw chunk of DVD.
kalorx
30th October 2006, 05:35
Okay, I used DGIndex to demux raw DVD (I think). I have no idea how you're going to work with what the M2V I got, but hey, you guys know what you're doing a hellava lot more than I do.
To tell you the truth, I'm not sure I did this right, but here's the file just in case. No matter what player or editor I open this video in, it seems like it's already deinterlaced. (4.46 MB)
(Note: this isn't a panning sequence, but it's where I first started noticing differences. This will do fine for now, though.)
http://www.progressivedementia.net/star3.demuxed.m2v
Here are my settings for DeComb:
Telecide(order=1,guide=1,post=2,vthresh=83)
Here are my settings for TDeint:
TDeint(mode=2)
I never use both these lines at the same time.
If you try and use either of these plugins with the video and don't Decimate(), you'll notice that every fifth frame is "frozen". The motion will be smooth for four frames, and then stop for a single frame on the fifth, and then continue. WinDVD doesn't have this problem; even deinterlaced, the playback is smooth. I've checked frame-by-frame.
Okay, the place you want to watch for is the "grate" where Anakin is cutting with his saber. If you're using TDeint, the grate will "shudder" or some-such a bit as Anakin's saber closes in on it (some sort of deinterlacing error I guess). With DeComb it won't; in fact, this whole sequence is perfect with DeComb. You want to know what else offers perfect playback? WinDVD 7.
Now, I know DeComb is better to use as this is a telecined video (01230123 etc.). But as I've previously stated in another thread, I've found TDeint to generally be more reliable for smoothness.
Keep in mind that I've tried all sorts of different TDeint settings to get rid of the problem. I've yet to find a combination of TDeint settings that provides a solution.
That's the first place I noticed a difference between the two plugins, and where I first started realizing that WinDVD seemed to be better at deinterlacing than either DeComb or TDeint. The two are good most of the time, but have isolated instances of meltdown. WinDVD seems to handle everything with ease.
As soon as we're done examining this video (assuming I demuxed it correctly) we can move on to others.
foxyshadis
30th October 2006, 08:03
It's telecined; I expected that based on your first explanation but I didn't want to assume until I saw a sample. Here's a good link on the topic:
http://www.doom9.org/ivtc-tut.htm
But the short story is: Telecining converts 24 fps to 30 fps by doubling up a couple of fields every five frames, but it's not really interlaced; to undo (ivtc) it, you need to use DeComb or TIVTC. (Not TDeint.) Both Telecide and TFM will leave that fifth frame there, for technical reasons, and you need to use Decimate or TDecimate to remove it. That's it! Sorry if you already know and that's patronizing, just making sure.
If you want to use tdeint in combination with tfm, you can, like TFM(clip2=TDeint(...)).TDecimate(), in case you prefer TDeint's way of avoiding artifacts and badly encoded frames, though I didn't see any of that in the sample. If it's hybrid video giving you a problem, TIVTC is very capable of handling that.
TDeint alone, on the other hand, would be used for pure-interlaced content, which is how all live tv and many other television shows are broadcast.
kalorx
30th October 2006, 16:39
Okay, but I suppose my question is, what might WinDVD do that gets rid of the fifth frame problem while still playing back at 29.97fps, something that DeComb can't do?
And also, how did you examine the M2V? I loaded it in a player, in TMPGEnc, and Cuttermaran and it was always detelecined, in 16:9 playback, etc. I couldn't examine it as just raw footage.
buzzqw
30th October 2006, 17:13
@foxyshadis
humble question: since this file is "100.00% FILM" wouldn't be better solution select "Force Film" in Dgindex and use NO other filters ?
BHH
kalorx
30th October 2006, 17:18
I've had some bad experiences with force-filming, even with a video 95%-100% FILM. Some frames still seem to come out awkward.
foxyshadis
30th October 2006, 22:13
The clip might be, but the whole file might not be. If it is in the 99-100 territory, it's worth it though.
Kalorx, windvd might say it's playing at 30 fps, but if you were to record a screen capture with fraps or similar, you'd see that it only showed 24 unique, evenly spaced frames per second. There's no way to usefully play 24 fps at 30, without motion compensation; deinterlacing looks terrible on motion scenes and field-matching stutters like mad.
To examine it, I just loaded it in virtualdub-mpeg2. That way all pulldown flags are honored, whereas most mpeg tools will ignore them.
kalorx
31st October 2006, 00:37
It makes me wonder why it's encoded at 30fps at all if it's just played back at 24fps.
Aside from that, this MPEG-2 tool is really nifty. I wish I'd known about it a while ago...
foxyshadis
31st October 2006, 01:45
Analog TVs were designed to have only one single framerate - 59.94 for ntsc and 50 for pal. Everything else up until HDTV had to be squeezed into that, somehow. HDTV standards explicitly require 24p playback, so eventually all this telecining stuff might go away.
kalorx
31st October 2006, 03:22
I thought HD videos were 60 fps. Is this incorrect?
foxyshadis
31st October 2006, 04:39
24p, 30p, 60p and 60i are all part of the NTSC spec. For PAL it's 24p, 25p, 50p, and 50i. (Presumably a lot of systems will do both.)
kalorx
31st October 2006, 06:07
So although HD-DVDs can playback 60p and 60i, the standard is 24p? Not that I'm complaining, I'm just curious. Also, just out of curiosity, what's the PAL resolution for HD-DVDs? Are NTSC and PAL resolutions the same?
And we're on this topic, does Blu-Ray support all the same framerates? I've been looking for specs of these things, and all I can find is mostly general information (even on the product homepages). It's a damn shame about Blu-Ray. It's going to go the way of the Betamax, and only because Microsoft went with the cheaper HD-DVD... :(
foxyshadis
31st October 2006, 08:28
Those are part of the HDTV standards, the two HD disc formats support all of the possible resolutions and framerates offered by broadcast. Broadcast will probably lean more toward converting 24p content to 50/60i for simplicity for a while, though. (1080p50/60 isn't actually part of the HD standards yet, I see, though it's in DHDVD/Bluray and widely expected to be ratified for broadcast when AVC use increases.)
Really, I don't see what the fuss over BD/HDDVD is, once content is unified under one or the other. While different at the technical level, the differences to consumers are much less clear-cut than the differences between betamax and vhs. Both will have exceptionally crisp picture once studios have fully transitioned and upgraded to VC1/AVC encoders, and enough room for all the extras. (And both snubbed aac and wma, bizarrely.) They're all but clones, and storage space won't make much more difference on quality than DVD-5 vs DVD-9, especially once multi-layers are out.
kalorx
31st October 2006, 17:39
The data transfer rate on BD is much higher, wouldn't that translate to a higher maximum bitrate? The extra space should also make an enormous difference in quality (or at least it seems that way). 50 GB verses 30 GB, once dual-layers come around. That's 20 GB more for not only extra quality on videos, but also more bonus content.
And you say that AAC won't be the most-used audio format in them? I was under the impression that it was going to be. Is this a recent development?
foxyshadis
31st October 2006, 19:36
The audio formats on HD discs are exactly the same as on DVDs - LPCM, MP2, AC3, and DTS, although the bitrates can be a lot higher and LPCM gets 6-channel mode. No AAC, WMA, or MP3.
Bluray has a maximum of 40Mbps, and HDDVD around 30Mbps. I guess we'll have to wait and see whether this makes any difference in the future; on the first tet done here (http://forum.doom9.org/showthread.php?t=114928), few have been able to distiguish 12 and 18 Mbps from the original, let alone 30.
kalorx
31st October 2006, 21:17
Odd. I guess my sources were wrong. I was under the impression that the transfer rate of BD was 54Mbps and HD was 36.5Mbps. That was the same source that proclaimed AAC audio was the future of HD aural pleasure... oh well.
foxyshadis
1st November 2006, 07:44
Well, those are the maximum transfer rates, so your source isn't entirely wrong, but I listed the maximum video transfer rates. I have no idea why BD's max total rate is 14 mbps above its max video rate - do people need 12 6-channel audio streams on the side? But whatever.
But definitely no AAC, major disappointments among the video crowd at forums like this when that came out. Some players will likely be able to read MP4/AAC on the side, though, like some can read AVI/MP3 now.
squid_80
1st November 2006, 13:24
For PAL it's 24p, 25p, 50p, and 50i. (Presumably a lot of systems will do both.)
Where did 24p for PAL come from?
foxyshadis
1st November 2006, 19:44
Since I didn't see it explicitly mentioned as NTSC, I assumed it applied to both, since there isn't a single pal standard yet but a few ad-hoc ones. Still, I haven't found anything to confirm or deny it when I looked; it'd make sense for consistency's sake, but that never bothered standards committees.
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.