Medianfilter + depth view range +Fine dither as Mask + range sliders = de-noise

1 year 1 month ago - 1 year 1 month ago #1 by Gotthemshaders
I'd really love if someone could make this happen !
Hopefully this makes sense. Since my last post did not give any details .
Here i will put a little effort into this description :
( help give me suggestions to better word this . Or ideas )

This new shader I hope to be a very fine tuned de-noiser . to blend away game film grain, with No blurring of game textures.
Or at least minimal loss . I will List at least Three Shaders that have settings that should be combined in this effort.

This will add a threshold slider to radiate The Median de-noise effect from a film grain itself acting like a porous mask.
Since we cant target in game film grain itself . we can maybe match it with super fine grain shader, and use that as a mask to apply the median .
A threshold or area of effect to radiate the median effect from every single point of a super fine grain .
This way we have more control the median is not being applied to everything but only this grain.
ideally this will match as close as possible in game film grain to be masked or blended away.

To further add targeting options, we could apply the lighting and colors to target, that only apply to the grain itself.
And depth buffer view, to target exactly what we want, ranging from far to near, as a fade start, end.
If the grain we use as a de-noise mask can apply to shapes in the depth view, then this further preserves details; outlines, game textures,
and gives us even more targeting options .

I'll use three shaders as examples that already apply some effects we need to combined .

PD80_05_Sharpening.fx :
This shader uses Depth based adjustments -

The New shader should have these options :

1. change depth start plane
2. change depth end plane
3. depth curve adjustment
4 ( reverse depth effect ) .

This will help further target area of effect.

Now The second aspect ; of the new shader, should use
apply a super-fine small dither or film grain
( example as found in PD80_04_Contrast_Brightness_Saturation.fx )
and have option to apply to depth buffer itself and reasonably account for shapes and background in game.
Again we do Not want to add grain to the game, since this is meant to be de-noise shader. I noticed a need for finer targeting of in game grain. To do this, we could use a dither or grain ourselves, in the shader to act as a controlled mask when applying Midianfilter fx. or bilateral as example . So its not blanketing the game with a blurry mess. we want to preserve game texture. so we need good targeting or application method .

Last aspect should apply
MedianFilter.fx ( Median control ) or some very light application of bilateral our grain dither itself. with mask adjustment .
I dont know the right words

MedianFilter 3x3 i use to blur out noise .

But again its too wide. We need to further reduce its area of effect. By having it apply Only to the dither we use . from there, we add a threshold or radiate slider, to expand or contain the median from every point of grain dither. so it does not go past that .

Coupled with depth application view ranges, this would aim to be the ultimate game de-noiser . to remove pesky film grain.

If there is a better way to improve targeting of the grain then please contribute .

I have no experience with reshade nor coding .so hope someone here can make this a reality .
Last edit: 1 year 1 month ago by Gotthemshaders.

Please Log in or Create an account to join the conversation.