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 2nd January 2008, 13:42   #1  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
Using mt_edge for pre-filtering? possible?

Hello, I was wonderin' if it'd be possible to use mt_edge for edge cleaning (not for dehaloing ), and if so, will minblur play a part in this process? Asking because I think perhaps minblurx will be more efficient than the standard minblur, but maybe i'm wrong (like usual -P.) mt_edge seems to need helper functions, as the default just makes a mask of the areas to be affected (in what looks like, uv.)
Basically what i'm asking for, is mt_edge's edged areas to be included in my filter chain, without the uv mask.

Last edited by Terranigma; 2nd January 2008 at 14:11. Reason: added a sentence for clarification
Terranigma is offline   Reply With Quote
Old 2nd January 2008, 14:17   #2  |  Link
Didée
Registered User
 
Join Date: Apr 2002
Location: Germany
Posts: 5,394
Edge detectors on their own are not that awfully useful for edge cleaning. The cruical point is the "what" and "how" to do, not the "where".

The most "obvious" concept for edge cleaning probably is bilateral filtering. Try TBilateral, with some sort of minblur/x for the "ppClip" analysis clip.

In any case, you'll find that if you try to remove artefacts around edges, you will necessarily lose weak detail that happens to be located around prominent edges, too.


Quote:
perhaps minblurx will be more efficient than the standard minblur
minblurX was just a quick hack, lazy of fully parametrizing the minblur function.
And it's the other way round: the X version is more defensive than the old one, and they differ only if r=2. For r=1 and r=3 they're fully identical.
__________________
- 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!)
Didée is offline   Reply With Quote
Old 2nd January 2008, 14:33   #3  |  Link
Terranigma
*Space Reserved*
 
Terranigma's Avatar
 
Join Date: May 2006
Posts: 953
Quote:
Originally Posted by Didée View Post
The most "obvious" concept for edge cleaning probably is bilateral filtering. Try TBilateral, with some sort of minblur/x for the "ppClip" analysis clip.

In any case, you'll find that if you try to remove artefacts around edges, you will necessarily lose weak detail that happens to be located around prominent edges, too.
Oh I already noticed this with that script you whipped up for dehaloing; it can also cause some aliasing too (on uneven edges), but I thought that was only the downside of that script in particular, not edge-cleaning in whole. Well thanks for clearing that up.
Terranigma is offline   Reply With Quote
Old 2nd January 2008, 19:11   #4  |  Link
Didée
Registered User
 
Join Date: Apr 2002
Location: Germany
Posts: 5,394
I'd think of a filter like basically this:

SmartBlur( radius, sensitivity )

1. Calculate the span [max-min] in the window of [radius] around [current pixel]

2. Apply blurring. To blur the current pixel, take into account only pixels that differ from [current pixel] by no more than [max-min]*[sensitivity]

In plain english: Blur each pixel by averaging it with those pixels which difference to the current pixel is not more than, say, 20% of the local min/max gradient.

Possible extensions:
- kind of blurring / radius2 for blurring window
- split sensitivity into sens_low & sens_high to avoid harsh boundaries between "filtered" and "not filtered"

That's kind of a "full-fledged version" of what HQDering is doing (or trying to do).
Strictly speaking, this kind of filtering can not be "scripted". It has to be implemented in a plugin. With scripted implementations, only overly slow and very rough piecewise approximations are possible.
__________________
- 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!)
Didée 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 17:30.


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