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 21st February 2011, 22:47   #1  |  Link
list
Registered User
 
list's Avatar
 
Join Date: Sep 2010
Location: Argentina
Posts: 24
unsharpHQ

UnsharpHQ , v05 (updated)

This is a very strong and fast unsharp mask with some new features.
This version is the optimization of the last v03 (also more accurate).

UnsharpHQ is a video plugin for Avisytnh 2.5x.

REQUIRES
* YV12 colorspace input.
* SSE3 capable CPU.

USAGE
UnsharpHQ(int THRESHOLD,float SHARPSTR,float SMOOTH,bool SHOW)

PARAMETERS
(All parameters are optional).
* THRESHOLD: (Default = 20) The value to determine whether or not to sharp a pixel based on the luminance change between their neighbors. Any value >0 can be used.
* SHARPSTR : (Default = 4.0) The sharp strength for the pixels to be sharped. Values from 2 to 10 are recommended.
* SMOOTH : (Default = 0.5) The smooth strength to pixels not sharped. Use this with 0 if you don't want any smooth, or just leave it with default.
* SHOW : (Default = false) The debug or not parameter. Set this to true will show a green video showing the zones to be sharped or not, this is useful to adjust your threshold to your right value.

EXAMPLES
Unsharphq() #All by default, this is useful in most cases.
Unsharphq(20,15.0) #Very strong sharp.
Unsharphq(debug=true) #Run in debug mode.

x86 binary and source -> https://www.mediafire.com/download/1...harpHQ_v05.zip

Last edited by list; 19th January 2014 at 14:56. Reason: update
list is offline   Reply With Quote
Old 22nd February 2011, 00:12   #2  |  Link
leeperry
Kid for Today
 
Join Date: Aug 2004
Posts: 3,477
I wanna play, can you put it on mediafire.com please?
leeperry is offline   Reply With Quote
Old 22nd February 2011, 00:16   #3  |  Link
list
Registered User
 
list's Avatar
 
Join Date: Sep 2010
Location: Argentina
Posts: 24
Quote:
Originally Posted by leeperry View Post
I wanna play, can you put it on mediafire.com please?
sure, here it is http://www.mediafire.com/download.php?26622393msbo69v

Last edited by list; 22nd February 2011 at 11:58.
list is offline   Reply With Quote
Old 22nd February 2011, 01:05   #4  |  Link
Didée
Registered User
 
Join Date: Apr 2002
Location: Germany
Posts: 5,389
So, the HQ mode is using either some sort of edge-masking, or it surpresses very-small differences. I noticed that some "holes" can appear with HQ .... when there is a very thin line at a shallow angle, then some single pixels don't get sharpened, but their neighbors do.

On a sample that intentionally was blurred very strongly, the most pleasing result (for a given strength setting) to my eyes was

Merge( unsharpHQ(str=50,HQ=false), unsharpHQ(str=50,HQ=true) )
__________________
- 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 22nd February 2011, 02:18   #5  |  Link
list
Registered User
 
list's Avatar
 
Join Date: Sep 2010
Location: Argentina
Posts: 24
Quote:
Originally Posted by Didée View Post
I noticed that some "holes" can appear with HQ .... when there is a very thin line at a shallow angle, then some single pixels don't get sharpened, but their neighbors do.)
can you give some image sample? so i can improve it.
list is offline   Reply With Quote
Old 22nd February 2011, 03:01   #6  |  Link
henryho_hk
Registered User
 
Join Date: Mar 2004
Posts: 889
A 64bit version would be a big plus. ^__^
henryho_hk is offline   Reply With Quote
Old 22nd February 2011, 05:14   #7  |  Link
list
Registered User
 
list's Avatar
 
Join Date: Sep 2010
Location: Argentina
Posts: 24
thaks Didee, i could fix all these "holes" problem and improve the quality a lot.
now it's getting a real HQ filter
here is the version 3

Last edited by list; 22nd February 2011 at 12:01.
list is offline   Reply With Quote
Old 22nd February 2011, 05:50   #8  |  Link
Vitaliy Gorbatenko
viterra
 
Join Date: Feb 2003
Location: St. Peterburg, Russia
Posts: 142
Put on mediafire.com please!
Vitaliy Gorbatenko is offline   Reply With Quote
Old 22nd February 2011, 11:56   #9  |  Link
list
Registered User
 
list's Avatar
 
Join Date: Sep 2010
Location: Argentina
Posts: 24
Quote:
Originally Posted by Vitaliy Gorbatenko View Post
Put on mediafire.com please!
ok, link updated, see above
does the doom9 file server work? it works for me. If it doesn't for you, i will stop using it.

Last edited by list; 22nd February 2011 at 12:06.
list is offline   Reply With Quote
Old 24th February 2011, 10:13   #10  |  Link
kypec
User of free A/V tools
 
kypec's Avatar
 
Join Date: Jul 2006
Location: SK
Posts: 826
Quote:
Originally Posted by list View Post
does the doom9 file server work? it works for me. If it doesn't for you, i will stop using it.
Doom9's attachments work fine but sometimes (more often than not) it takes veeeery long time until they're approved by moderator -> thus made available for download to other users
kypec is offline   Reply With Quote
Old 26th February 2011, 14:02   #11  |  Link
list
Registered User
 
list's Avatar
 
Join Date: Sep 2010
Location: Argentina
Posts: 24
the optimized version is out =) , see above.
list is offline   Reply With Quote
Old 12th June 2011, 20:11   #12  |  Link
naoan
Registered User
 
Join Date: Oct 2009
Posts: 151
I really like this sharpener but there's seem to be slight distortion on the right and left most frame when this filter is used, more noticeably on sd material. Any plan to fix this?
naoan is offline   Reply With Quote
Old 13th June 2011, 22:49   #13  |  Link
list
Registered User
 
list's Avatar
 
Join Date: Sep 2010
Location: Argentina
Posts: 24
Quote:
Originally Posted by naoan View Post
I really like this sharpener but there's seem to be slight distortion on the right and left most frame when this filter is used, more noticeably on sd material. Any plan to fix this?
thanks, i made a new improved version , but with a different behavior and new parameters, so a will release it in a new filter soon
list is offline   Reply With Quote
Old 15th June 2011, 18:05   #14  |  Link
Mounir
Registered User
 
Join Date: Nov 2006
Posts: 773
Trying the V0.4 now, getting an error

Merge( unsharpHQ(str=50,HQ=false), unsharpHQ(str=50,HQ=true) ) >>> UnsharpHQ does not have a named argument "HQ"


Nice eh ? Solution please

Last edited by Mounir; 15th June 2011 at 18:09.
Mounir is offline   Reply With Quote
Old 16th June 2011, 21:42   #15  |  Link
list
Registered User
 
list's Avatar
 
Join Date: Sep 2010
Location: Argentina
Posts: 24
Quote:
Originally Posted by Mounir View Post
Trying the V0.4 now, getting an error

Merge( unsharpHQ(str=50,HQ=false), unsharpHQ(str=50,HQ=true) ) >>> UnsharpHQ does not have a named argument "HQ"
as i wrote: v0.4 Usage: unsharpHQ(float STR = 5.0)
it does not have a HQ argument
list is offline   Reply With Quote
Old 27th January 2014, 22:25   #16  |  Link
list
Registered User
 
list's Avatar
 
Join Date: Sep 2010
Location: Argentina
Posts: 24
Version 05 released with source.
__________________
UnsharpHQ Avisynth plugin
list is offline   Reply With Quote
Old 18th July 2014, 16:23   #17  |  Link
Francois76l
Registered User
 
Join Date: Oct 2013
Location: France - Paris
Posts: 19
Hello list!
Thanks for this great update!
I remarked a small bug with this new version. On the image frame, there is "double contour" on the horizontal lower part. I tried with a very small sharp but the problem is still present.
If you could correct this, it would be amazing!
Thanks!

Last edited by Francois76l; 18th July 2014 at 16:23. Reason: subscription
Francois76l is offline   Reply With Quote
Old 18th July 2014, 22:03   #18  |  Link
list
Registered User
 
list's Avatar
 
Join Date: Sep 2010
Location: Argentina
Posts: 24
Quote:
Originally Posted by Francois76l View Post
Hello list!
Thanks for this great update!
I remarked a small bug with this new version. On the image frame, there is "double contour" on the horizontal lower part. I tried with a very small sharp but the problem is still present.
If you could correct this, it would be amazing!
Thanks!
Hi Francois. Thanks for reporting the bug. I am aware of it.
I can not give a new release right now. Anyway you can manually fix it adding borders. An example script adding overlap in the left and right side would look like this:
Code:
#right overlay
AddBorders(2,0,0,0)
overlay(last,x=-1)overlay(last,x=-1)
#left overlay
AddBorders(0,0,2,0)
overlay(last,x=1)overlay(last,x=1)
#apply the filter
UnsharpHQ(20,99,0)
#cut off borders
crop(2,0,-2,0)
I hope this helps you.
__________________
UnsharpHQ Avisynth plugin
list is offline   Reply With Quote
Old 18th July 2014, 23:23   #19  |  Link
Francois76l
Registered User
 
Join Date: Oct 2013
Location: France - Paris
Posts: 19
OK great!
Does it mean you are aware of this problem?
++
Francois76l is offline   Reply With Quote
Old 6th March 2021, 21:19   #20  |  Link
Reel.Deel
Registered User
 
Join Date: Mar 2012
Location: Texas
Posts: 1,664
If it's not a lot of trouble, can someone compile a 64-bit version of UnsharpHQmod? I opened an issue on GitHub but it may be the author is no longer active.

Here's some of the info that is on GitHub but translated:

Added and changed parameters
Code:
MODE:
    0 - default(equivalent to previous mode)
    1 - addded in mod(threshold, sharpstr, smooth parameter effects are little bit changed in this mode), at this mode, SMOOTH=0 is good choice!
        
SHOW:
    may not work... I don't know how to use it properly, so HBD doesn't support it properly, only when opt=1.
    
OPT:
    optimization - 0=auto, 1=C, 2:SSE2, 3:AVX2
Changelog (translated)
Code:
mod 200816
    Changed to Avisynth2.6+.
    HBD (8-16 YUV only) support + AVX2 optimization, opt added to parameters.
    Intrinsic asm.
mod 190119
    Fixed loop range.
    Changed correction weights from 4 to 8 (this will slightly change the output even in mode0)
    Modify correction weights in mode1 so that they become 1 when the difference between the center point and the neighborhood of 8 is THRESHOLD.
mod 181224 
    Added MODE=1, which modifies something that seems to be wrong (MODE=0 is compatible with the previous version).
    Note that MODE1 is not parameter compatible with the previous version.
    Don't worry about errors related to MODE, as I didn't do it properly.

    Also, I just rebuilt it with VS2017 and it's 10% faster for some reason.
Reel.Deel is offline   Reply With Quote
Reply

Tags
unsharphq filter avisynth

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 10:19.


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