Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > Avisynth Usage

Reply
 
Thread Tools Search this Thread Display Modes
Old 17th June 2006, 17:52   #1  |  Link
DrScotsman
Registered User
 
Join Date: May 2005
Posts: 11
Dealing with compression-killing interlaced luma variations

So I have the R2 Family Guy Season 3 DVDs. Unlike the first two Seasons, the quality of this is astounding. Not a single blend anywhere, PAL speedup with pitch correction, etc.

However, while the episodes are progressive, they're encoded interlaced. I'm aware that usually this means nothing and it should just be treated as progressive. However when I view it with Histogram(mode="luma"), you can see that there are differences between fields (there's no problem with the chroma for the record). Putting a Bob() afterwards proves this; Bob.SelectEven and Bob.SelectOdd look fine (well, better), but Bob doesn't.

M2V sample, 20MB

And a sample histogrammed image:



I've tried an x264 encode, and this issue seems to kill compression. In addition, I'd like to resize it to 720x540 (to make it square pixel), and a vertical resize is never good for interlacing.

So, are there any filters that can solve this?

Thanks in advance.

Last edited by DrScotsman; 17th June 2006 at 18:06.
DrScotsman is offline   Reply With Quote
Old 17th June 2006, 19:15   #2  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,413
Try using a denoiser. frfun7+degrainmedian warms my heart for mild or moderate noise, and a slight sharpening (limitedsharpen or seesaw) to remove the softness it'll cause. If the combing is normally too faint to notice, that'll completely get rid of it, and if not, at least mitigate it.

Or you actually could try resizing, because the variations should be small enough that resizing will mix them back together in an eye-pleasing instead of disruptive way. (Since they're supposed to be together anyway, unlike combing.) But you probably can't resize down far enough to make a noticeable difference, and it'd be best to keep the original DVD resolution.
__________________
There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order.
foxyshadis is offline   Reply With Quote
Old 17th June 2006, 19:28   #3  |  Link
Didée
Registered User
 
Join Date: Apr 2002
Location: Germany
Posts: 5,394
Try the following - it's not the definite solution, but it improves very much on the problem, while impact on actual detail is very little.

BTW, basically this is just good old "Blur(1.0).Sharpen(1.0)" ... but done correctly.


Edit 26 Oct '06: Function updated (hopefully all inconsistencies eliminated).
Code:
# Vinverse: a small, but effective Function against (residual) combing, by Didée
# sstr: strength of contra sharpening
# amnt: change no pixel by more than this (default=255: unrestricted)
# uv  : chroma mode, as in MaskTools: 1=trash chroma, 2=pass chroma through, 3=process chroma

function Vinverse(clip clp, float "sstr", int "amnt", int "uv")
{
uv   = default(uv,3)
sstr = default(sstr,2.7)
amnt = default(amnt,255)
uv2  = (uv==2) ? 1 : uv
STR  = string(sstr)
AMN  = string(amnt)
vblur  = clp.mt_Convolution("1","50 99 50",U=uv,V=uv)
vblurD = mt_MakeDiff(clp,vblur,U=uv2,V=uv2)
Vshrp  = mt_LutXY(vblur,vblur.mt_Convolution("1","1 4 6 4 1",U=uv2,V=uv2),expr="x x y - "+STR+" * +",U=uv2,V=uv2)
VshrpD = mt_MakeDiff(Vshrp,vblur,U=uv2,V=uv2)
VlimD  = mt_LutXY(VshrpD,VblurD,expr="x 128 - y 128 - * 0 < x 128 - abs y 128 - abs < x y ? 128 - 0.25 * 128 + x 128 - abs y 128 - abs < x y ? ?",U=uv2,V=uv2)
mt_AddDiff(Vblur,VlimD,U=uv,V=uv)
(amnt>254) ? last : (amnt==0) ? clp : mt_LutXY(clp,last,expr="x "+AMN+" + y < x "+AMN+" + x "+AMN+" - y > x "+AMN+" - y ? ?",U=uv,V=uv) 
return(last)
}
Should deal well with most forms of residual combing.
__________________
- We´re at the beginning of the end of mankind´s childhood -

My little flickr gallery. (Yes indeed, I do have hobbies other than digital video!)

Last edited by Didée; 26th October 2006 at 13:08.
Didée is offline   Reply With Quote
Old 17th June 2006, 21:10   #4  |  Link
Fizick
AviSynth plugger
 
Fizick's Avatar
 
Join Date: Nov 2003
Location: Russia
Posts: 2,183
I remember my first plugin Equlines
__________________
My Avisynth plugins are now at http://avisynth.org.ru and mirror at http://avisynth.nl/users/fizick
I usually do not provide a technical support in private messages.
Fizick is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 16:42.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2019, vBulletin Solutions Inc.