View Full Version : Adaptive sharpen - Image sharpening shader
ts1
8th January 2016, 22:34
It's a pretty lightweight shader. Something wrong with your GPU drivers/setup. I tried it on Linux and it works fine with proprietary nVidia drivers, but with nouveau it's also not usable, very slow.
There is parameter to control sharpening strength.
BRM
9th January 2016, 10:23
It's a pretty lightweight shader. Something wrong with your GPU drivers/setup. I tried it on Linux and it works fine with proprietary nVidia drivers, but with nouveau it's also not usable, very slow.
There is parameter to control sharpening strength.
I know, I get similar results with the 2-pass shader.
As for my setup, it's radeon-git, xorg.conf and xorg.conf.d/20-radeon.conf are as follows: http://pastebin.com/raw/aE3e21Bn
Section "Device"
Identifier "radeonVGA"
Driver "radeon"
Option "AccelMethod" "Glamor" # See compatibility on features page
Option "DRI3" "on" # Compatibility not very well documented, remove it if it fails
Option "EnablePageFlip" "On"
EndSection
ts1
9th January 2016, 11:02
Can't help you with this, I never used Radeon and I use Linux (Sabayon, Gentoo based) from flash drive, it already includes proprietary drivers and mpv.
XMonarchY
13th January 2016, 23:01
How would I go about integrating your latest version downloads into ReShade? ReShade uses either .fx files or .h files. I assume I can just rename TWO-PASS .hlsl file to .h or .fx file because the content is identical, isn't it? When I open the file with WordPad, it shows identical info. I assume ReShade uses the TWO-PASS file because ATM it uses a 12KB file, which is closer to TWO-PASS 11KB then to ONE-PASS 4KB file.
aufkrawall
14th January 2016, 01:42
You have to port the HLSL shader to ReShade shading language.
bacondither or JPulowski will do it soon:
https://github.com/crosire/reshade-shaders/issues/8
BRM
19th January 2016, 18:41
Can't help you with this, I never used Radeon and I use Linux (Sabayon, Gentoo based) from flash drive, it already includes proprietary drivers and mpv.
New 1 pass shader causes a segfault.
LLVM triggered Diagnostic Handler: SIInstrInfo::storeRegToStackSlot - Can't spill VGPR!
[1] 9181 segmentation fault mpv https://www.youtube.com/watch\?v\=yqynPcFEL3U
ts1
19th January 2016, 19:47
Are you sure this is shader's fault? Is there any errors from a shader compiler?
I will test it with mesa later.
Edit: works with mesa, slow but without errors.
LLVM triggered Diagnostic Handler: SIInstrInfo::storeRegToStackSlot - Can't spill VGPR!
Seems like it's a LLVM's bug https://bugs.freedesktop.org/show_bug.cgi?id=75276#c50. Do you use latest LLVM 3.7?
BRM
27th January 2016, 01:18
Seems like it's a LLVM's bug https://bugs.freedesktop.org/show_bug.cgi?id=75276#c50. Do you use latest LLVM 3.7?
Yes, that one is super slow but works, and you were right, it was caused by using LLVM 3.5.
ts1
2nd February 2016, 15:40
nevermind
ts1
16th February 2016, 14:27
bacondither
I removed my previous comment, but there is still a problem in minim_satloss, there are cases when c0_Y==0.
Ok, this is only in glsl so.
foozoor
16th February 2016, 23:10
Thanks for the update ts1. ;)
XMonarchY
9th March 2016, 04:02
Could someone provide some images that compare LumaSharpen, AdaptiveSharpen, FineSharp, and or Crispen Edges using similar settings?
I usually apply a little bit of AdaptiveSharpen (0.1-0.15) and a little bit of LumaSharpen (0.50 - strength, 0.030 - clamp) in films and games, but I'd like to reduce ringing, noise, artifacts, overshoot, and other side-effects. What should I be using them - both AdaptiveSharpen and LumaSharpen OR just one of them? Which one?
bacondither
12th July 2016, 18:54
New version released! :cool:
bacondither
I removed my previous comment, but there is still a problem in minim_satloss, there are cases when c0_Y==0.
Ok, this is only in glsl so.
That's strange, i have done a glsl port of my own for testing so i could poke around with it in mpv a bit.
toniash
12th July 2016, 21:50
A guy (igv) ported and improved this shader for the mpv hook system:
https://gist.github.com/igv/8a77e4eb8276753b54bb94c1c50c317e
I don't really know what he improved but it looks amazingly on my sister's laptop with a weak intel hd3000 iGPU. The two-passes version is too intensive!
(From Madvr thread)
bob88
8th December 2016, 12:27
Hello,
I'm using latest version MPC-HC x64 1.7.10
I added the shaders in post-resize in the described order but I still get a green screen.
Could somebody please tell me how to fix it?
Thank you!
bacondither
8th December 2016, 14:08
Could somebody please tell me how to fix it?
Thank you!
If you are using madVR as video renderer untick "lose BTB and WTW if it improves performance" and "run custom pixel shaders in video levels instead of PC levels".
The settings can be found in madVR settings, rendering->trade quality for performance.
bob88
8th December 2016, 15:12
I am using the default 'enhanced video renderer (custom presenter)'
madVR is listed as unavailable, I guess it has to be installed additionally. Should I be using that? Is it better?
bacondither
8th December 2016, 15:30
Ok you are using EVR.
Go to View-> Renderer Settings -> Presentation and enable "Full floating point point processing" or "Half floating point point processing", then restart MPC-HC.
Hmm i should probably add this to the installation instructions.
BetA13
8th December 2016, 18:48
Ok you are using EVR.
Go to View-> Renderer Settings -> Presentation and enable "Full floating point point processing" or "Half floating point point processing", then restart MPC-HC.
Hmm i should probably add this to the installation instructions.
ha, and i was wondering why it didnt work in my normal MPCHC test player but did work with madvr etc..
Thanks for the tip with the "Full floating point point processing"
Just wondering, what does this function do anyway?
"Full floating point point processing", "Half floating point point processing"
Have a nice evening bacondither and thanks for teh lesson haha..
bob88
8th December 2016, 19:28
Ok you are using EVR.
Go to View-> Renderer Settings -> Presentation and enable "Full floating point point processing" or "Half floating point point processing", then restart MPC-HC.
Hmm i should probably add this to the installation instructions.
Enabling full or half floating point processing just results in completely black screen regardless of shaders.
shaolin95
25th December 2016, 04:49
A guy (igv) ported and improved this shader for the mpv hook system:
https://gist.github.com/igv/8a77e4eb8276753b54bb94c1c50c317e
I don't really know what he improved but it looks amazingly on my sister's laptop with a weak intel hd3000 iGPU. The two-passes version is too intensive!
(From Madvr thread)
Where do you place this file to work with mpv (SMPlayer)? I have been using it with MPC-HC but wanted to try mpv as it seems to be better for SVP.
Thanks
toniash
25th December 2016, 08:56
Where do you place this file to work with mpv (SMPlayer)? I have been using it with MPC-HC but wanted to try mpv as it seems to be better for SVP.
Thanks
vo=opengl-hq:backend=angle:scale=ewa_lanczossharp:cscale=ewa_lanczossoft:interpolation:tscale=mitchell:tscale-clamp:temporal-dither:user-shaders="~~/shaders/adaptive-sharpen.glsl"
shaolin95
25th December 2016, 17:20
vo=opengl-hq:backend=angle:scale=ewa_lanczossharp:cscale=ewa_lanczossoft:interpolation:tscale=mitchell:tscale-clamp:temporal-dither:user-shaders="~~/shaders/adaptive-sharpen.glsl"
Sorry for the dumb question but is my first time using mpv.
Will I add in the same section I add this line for SVP "--input-ipc-server=mpvpipe" as shown on this guide?
https://www.svp-team.com/wiki/SVP:SMPlayer
toniash
27th December 2016, 18:21
Sorry for the dumb question but is my first time using mpv.
Will I add in the same section I add this line for SVP "--input-ipc-server=mpvpipe" as shown on this guide?
https://www.svp-team.com/wiki/SVP:SMPlayer
yes:):)
shaolin95
27th December 2016, 18:32
yes:):)
I must be doing something wrong cause I just get an error. I was dropping the script file in the root directory of the mpv64 folder (inside of the SVP folder).
Is that what I am doing wrong? :)
toniash
27th December 2016, 20:00
I must be doing something wrong cause I just get an error. I was dropping the script file in the root directory of the mpv64 folder (inside of the SVP folder).
Is that what I am doing wrong? :)
Then I think you need "user-shaders="~~/adaptive-sharpen.glsl"
Good luck!
toniash
30th December 2016, 09:08
Then I think you need "user-shaders="~~/adaptive-sharpen.glsl"
Good luck!
Did it work?:confused:
shaolin95
30th December 2016, 14:47
Did it work?:confused:
I didn't get an error but I do not see any effect on the screen so is not working :(
Thanks though, I just didn't want to keep bugging you. :)
toniash
30th December 2016, 15:51
I didn't get an error but I do not see any effect on the screen so is not working :(
Thanks though, I just didn't want to keep bugging you. :)
#define curve_height .96
// Main sharpening strength, POSITIVE VALUE ONLY! // 0.3 <-> 1.5 is a reasonable range of values
what value do you use?
shaolin95
30th December 2016, 16:29
#define curve_height .96
// Main sharpening strength, POSITIVE VALUE ONLY! // 0.3 <-> 1.5 is a reasonable range of values
what value do you use?
I didn't change it at all just let the script untouched. I'm just not sure I'm putting the file in the right folder maybe.
I will take some screenshots of my config and post.
Thanks!
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.