Log in

View Full Version : Why do we need to deinterlace when doing MPEG2?


Pko
8th March 2002, 11:37
Supposedly, MPEG2 supports interlaced input (and it does! interlaced DVDs are very common and they look great on TV and use normal DVD bitrates).

But if you try to encode them directly with CCE (or TMPGEnc), the results are awful... It seems that, althugh original is interlaced and you tell the encoder that it must do an interlaced stream, it is not done so. It treats the full frame composed of even an odd fields as a whole image to compress and so the nasty artifacts appear, and also the high frequency of that artifacts waste the bitrate and the results are really poor.

A workaround is to deinterlace first, doing it with decomb or other tools or simply using even or odd frames. Or, if the original was proressive telecined, undo the telecine, encode the FILM stream and add pulldown. But for truly interlaced sources, the workarounds are obviously a very far from optimal solution.

I think that the problem is that the encoder does not receive the stream correctly... I do not know how that must be done, I think that if you feed a full interlaced frame at the real framerate, the encoder should do everything necessary to correctly encode that stream, but obviously it is not so. Other posibilities I can think of right now is that perhaps there is a special format for interlaced streams (if so, how to force them from avisynth, for example?).

Or perhaps you must give the encoder a field stream, that is, a stream that has double framerate and the "frames" are in fact fields (same horizontal resolution, half vertical resolution). So, a truly interlaced PAL stream (720x576@25fps) will become a 720x288@50fps; the encoder will process it and the output will be an INTERLACED MPEG2 file of 720x576@25fps... But the questions are: will it work that way? how to do it?

Perhaps I shoul ask this in TMPGEnc forum also...

lgcbmb
14th March 2002, 13:38
I have had few problems getting interlaced source to encode well. I use the following process:

-Rip dvd with smartripper.
-Save vobs as project in dvd2avi (not using forcefilm)
-d2v>avi with using vfapi
-open avi in vdub. If resizing select “interlaced” checkbox. Save as huffyuv avi.
-open avi in CCE. Under video setting: uncheck progressive frames.
-encode and watch. Bitrate Viewer says this is an interlaced, field based stream at 29fps.
-Ive used this on Hollywood dvds and anime dvds (nasty telecine).

I watch the interlaced mpeg2 output with tvout, using windvd 2.3. With a g550, you must set “use field based scaling” under dualhead/dvdmax settings. This enabled interlaced output. Without this setting the source is output as progressive, this makes interlaced source look jerky and display interlace lines (kinda ironic). Guess its not only a matter of encoding interlaced source right, but also displaying it right. These encodes all look fine on the monitor as well.

These were encoded at 5mbit. Keep in mind by encoding 29fps, you have to encode about 20% more information then 24fps. How is your final encode awful? Jerky, pixilated, etc?