Help scripting

This forum is for questions and discussion of all the aspects of handling and cleaning up your footage with Avisynth.
Locked
User avatar
Qyot27
Surreptitious fluffy bunny
Joined: Fri Aug 30, 2002 12:08 pm
Status: Creepin' between the bullfrogs
Location: St. Pete, FL
Contact:
Org Profile

Re: Help scripting

Post by Qyot27 » Sun May 10, 2009 3:46 pm

I'm just copying from the 'Sampling' page on the AviSynth Wiki, but it seems that the only way to minimize it is to blur the chroma channel.
Chroma Upsampling Error (or CUE)

As previously stated, the Chroma Upsampling Error occurs when you convert from (truly) interlaced YV12 to mostly any other format and the converter thinks the video is progressive. Or, the other way around, if material is progressive (or interlaced encoded as progressive), and upsampled as interlaced. This is however not as bad as the other way around.

When VDub previews your video, it will need to convert it to RGB. Since AviSynth delivers YV12, it asks the codec (for example XviD or DivX) to convert YV12 to RGB. The codec however ALWAYS upsamples progressively. Hence you will get artifacts in VDub preview on interlaced YV12 material. This is however not present in the YV12 video (or in the resulting encoding). To confirm this, let AviSynth do the conversion by adding ConvertToRGB(interlaced=true) at the end of your script.
Correct me if I'm wrong here, but that almost reads like they're saying the error may simply be a problem with VDub's display, similar to but not exactly like not having the display bit depth correctly set to 24bits. And therefore that if it is an issue at all, letting AviSynth resample the colorspace may be the way to solve it.
Correcting video having the Chroma Upsampling Error

You will have to blur the chroma in some way (leaving the luma intact).

For example (using TomsMoComp):

Code: Select all

AviSource(...)
MergeChroma(TomsMoComp(-1,5,0))
Theoretical Aspects

In this section, the chroma placement will be explained, how this is related to subsampling (RGB -> YUY2 -> YV12) and how the upsampling is done in AviSynth.

It should also explain in detail why the CUE occurs. To summarize the latter, the problem is that there is a difference between YV12 progressive and YV12 interlaced, because the chroma is shared vertically between neighboring pixels.

See also this doom9 thread.
http://forum.doom9.org/showthread.php?s ... upsampling
My profile on MyAnimeList | Quasistatic Regret: yeah, yeah, I finally got a blog

Locked

Return to “AviSynth Help”