Prod80's shader library

  • prod80
  • Topic Author
More
4 years 1 month ago #41 by prod80 Replied by prod80 on topic Prod80's shader library
Updates...!

-- Some minor OCD code changes in Magical Rectangle
-- Sharpening now uses screen blend mode (more subtle with highlights)
-- Film Grain now has option to apply the grain only against the luminosity of the pixel, keeping hue and saturation intact. Additionally can adjust for perceived luminosity (green noise is otherwise very visible)

Example image about new noise coloring method


All available on GitHub
Enjoy!
The following user(s) said Thank You: Marty, aaronth07, AssassinsDecree

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

  • prod80
  • Topic Author
More
4 years 1 month ago #42 by prod80 Replied by prod80 on topic Prod80's shader library
Updated

Film Grain
• Improved the new color noise by using a different blend mode with background
• Improved the way noise is applied in highlights by slowly shifting to negative values

Shadow Midtone Highlights / Color Gradients / Magical Rectangle / Sharpening / Depth Slicer
• All have new and vastly improved blend modes for Saturation, Color, Hue, and Luminosity
The following user(s) said Thank You: Marty, aaronth07

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

  • nikobellic
More
4 years 1 month ago #43 by nikobellic Replied by nikobellic on topic Prod80's shader library
Thank you very much for such a great collection of shaders. I can't wait to tinker with some of the shaders when I get a long holiday.

Now, I have been searching forums and almost everywhere for a nice VHS shader like this one

I have found a few retro style VHS shaders but not anything like this. The fact that I haven't found none as close as the video, it might be either super hard or I haven't looked hard enough. I also got a premier pro video tutorial but I have no knowledge on how to convert those filters to reshade shaders.

I hope you take a look it this, possibly have it in your to do list. Have a great day!

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

  • prod80
  • Topic Author
More
4 years 1 month ago #44 by prod80 Replied by prod80 on topic Prod80's shader library
Just looked over the Adobe video and most of those effects are directly available or close to available (comparable effect like the channel blur - comparable to chromatic aberration) in my shader repository.

Levels,
Curved Levels,
Brightness Contrast Saturation,
Chromatic Aberration,
Sharpening (Unsharp Mask),
Film Grain,

Should be able to allow you to recreate that effect as shown in the video.

I like the channel blur though, so I may create and include that separately into my repository.
The following user(s) said Thank You: nikobellic

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

  • prod80
  • Topic Author
More
4 years 1 month ago - 4 years 1 month ago #45 by prod80 Replied by prod80 on topic Prod80's shader library
Added option in Film Grain shader to apply a Gaussian Blur on the grain texture..

So this Film Grain now features
• Moving or still grain based on Simplex noise algorithm
• Configurable grain size ( 1 - 4 pixels )
• Grain smoothness NEW
• Grain color: random color / original background color NEW
• Grain amount ( controls the swing between -1 and +1 grain addition to the image )
• Grain color amount ( saturation control, only works on random color )
• Grain intensity ( controls the final mix between grain and no grain )
• Grain density ( controls the density of grain )
• Grain intensity highlights / lowlights ( controls the amount of grain added in highlights and lowlights )
• Grain depth controls ( allows you to apply different levels of grain in background and foreground )

:)

Exaggerated example of S m o o t h G r a i n


Gradient example, smooth on the bottom
Last edit: 4 years 1 month ago by prod80.
The following user(s) said Thank You: Marty, AssassinsDecree

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

  • Marty
More
4 years 1 month ago - 4 years 1 month ago #46 by Marty Replied by Marty on topic Prod80's shader library

prod80 wrote: Added option in Film Grain shader to apply a Gaussian Blur on the grain texture..

• Grain smoothness NEW


Nice. Certainly helps with the roughness a bit.
However I just wanted to report that in DX9 games I'm getting this error on compilation.
PD80_06_Film_Grain.fx(381,18-64): error X3526: can't use gradient instructions in loops with break
DX11 works fine, haven't tested DX12 yet.
Last edit: 4 years 1 month ago by Marty.

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

  • prod80
  • Topic Author
More
4 years 1 month ago #47 by prod80 Replied by prod80 on topic Prod80's shader library

Marty wrote:

prod80 wrote: Added option in Film Grain shader to apply a Gaussian Blur on the grain texture..

• Grain smoothness NEW


Nice. Certainly helps with the roughness a bit.
However I just wanted to report that in DX9 games I'm getting this error on compilation.
PD80_06_Film_Grain.fx(381,18-64): error X3526: can't use gradient instructions in loops with break
DX11 works fine, haven't tested DX12 yet.


Ah yes, forgot about that lovely thing in DX9.
I uploaded a new version just now, that has a preprocessor definition to enable/disable the smoothing (no need to waste fps when someone doesn't like it). Can you check if that one still does it?
The following user(s) said Thank You: aaronth07, AssassinsDecree

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

  • prod80
  • Topic Author
More
4 years 1 month ago #48 by prod80 Replied by prod80 on topic Prod80's shader library

prod80 wrote:

Marty wrote:

prod80 wrote: Added option in Film Grain shader to apply a Gaussian Blur on the grain texture..

• Grain smoothness NEW


Nice. Certainly helps with the roughness a bit.
However I just wanted to report that in DX9 games I'm getting this error on compilation.
PD80_06_Film_Grain.fx(381,18-64): error X3526: can't use gradient instructions in loops with break
DX11 works fine, haven't tested DX12 yet.


Ah yes, forgot about that lovely thing in DX9.
I uploaded a new version just now, that has a preprocessor definition to enable/disable the smoothing (no need to waste fps when someone doesn't like it). Can you check if that one still does it?


Updated now again, should resolve it in DX9. Please try.
The following user(s) said Thank You: Marty, aaronth07, AssassinsDecree

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

  • Marty
More
4 years 1 month ago - 4 years 1 month ago #49 by Marty Replied by Marty on topic Prod80's shader library

prod80 wrote: Updated now again, should resolve it in DX9. Please try.


Yes, seems to be working now, even with smoothing on. Thanks for quick fix.
Last edit: 4 years 1 month ago by Marty.
The following user(s) said Thank You: prod80

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

  • prod80
  • Topic Author
More
4 years 1 month ago - 4 years 1 month ago #50 by prod80 Replied by prod80 on topic Prod80's shader library
Updates!

Correct Color & Correct Contrast
- Made the code more robust to avoid some rare issues
- Added improved method for tint detection using auto-tone to take better care with 'pure' colors besides only looking at max intensity
- Added improved fade function to avoid flickering and added slider to configure the speed in UI
- Improved the created textures to ignore screen size and AR and create 32x32 textures regardless, helps some oddities out of the way when changing resolutions on the fly (SRWE or else)
- Changed a some comparison math to max() / min() for neatness
- Improved method of color correction

Game image


Corrected for color and adjusted contrasts/brightness afterwards


Posterize / Pixelate
- Updated code, no performance cost on the pixelate now

Film Grain
- Did various updates to improve the visual aspects of the grain

Various shaders: Bloom, Sharpening, Chromatic Aberration, Film Grain
- Fixed compatibility with DX9 when using gradient function within a loop (forgot DX9 can't handle that)
Last edit: 4 years 1 month ago by prod80.
The following user(s) said Thank You: klotim, Apocalypso, Tojkar, Marty, aaronth07, AssassinsDecree, YF

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

  • prod80
  • Topic Author
More
4 years 1 month ago - 4 years 1 month ago #51 by prod80 Replied by prod80 on topic Prod80's shader library
Update to

PD80_02_Bloom.fx

Added new anti banding/dithering which is a lot faster and a whole lot cheaper. At this point requires an additional texture so take care when updating that you add the gaussian noise texture.

Banding in the blur (common issue due to precision)


New dithering (always on, no settings in UI)
Last edit: 4 years 1 month ago by prod80.
The following user(s) said Thank You: klotim, Marty, AssassinsDecree

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

  • gamehancer
More
4 years 1 month ago #52 by gamehancer Replied by gamehancer on topic Prod80's shader library
hi please help me I would like to deactivate IN THE SHADER PD80_06_Chromatic_Aberration the rgb channel of chromatic aberration just keep the effect sharp which line deactivate please ?

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

  • prod80
  • Topic Author
More
4 years 1 month ago #53 by prod80 Replied by prod80 on topic Prod80's shader library

gamehancer wrote: hi please help me I would like to deactivate IN THE SHADER PD80_06_Chromatic_Aberration the rgb channel of chromatic aberration just keep the effect sharp which line deactivate please ?


Sorry but what do you mean, I don't understand? Chromatic Aberration will always have a slight blurring effect because it moves the colors around. If you look for Sharpening, why not use PD80_05_Sharpening.fx
The following user(s) said Thank You: gamehancer

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

  • klotim
More
4 years 1 month ago - 4 years 1 month ago #54 by klotim Replied by klotim on topic Prod80's shader library
is it possible to further improve performance for the bloom shader? On black mesa ( source engine ) it uses 20% according to statistics from the reshade gui.

I have a RTX 2080 Ti.
Game resolution is 1440p

The quality is set to 2 and CA is enabled for the bloom shader.
Deband is disabled.
Last edit: 4 years 1 month ago by klotim.

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

  • prod80
  • Topic Author
More
4 years 1 month ago #55 by prod80 Replied by prod80 on topic Prod80's shader library

klotim wrote: is it possible to further improve performance for the bloom shader? On black mesa ( source engine ) it uses 20% according to statistics from the reshade gui.

I have a RTX 2080 Ti.
Game resolution is 1440p

The quality is set to 2 and CA is enabled for the bloom shader.
Deband is disabled.


Hi klotim,
While I know the bloom shader isn’t particularly light, it’s also not extremely heavy. You would notice it on a 2080Ti as performance is about 1.6ms (have 2080S myself) but shouldn’t push FPS down to unplayable. I can try and shave off a little more, but doing more than that will degrade quality visually, which I’m not that willing to compromise on. Also the UI indication is not a great guideline to see which shader impacts the performance the most. Best to check FPS with/without shaders on. Other effects like MXAO have a much greater impact on performance.

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

  • prod80
  • Topic Author
More
4 years 1 month ago - 4 years 1 month ago #56 by prod80 Replied by prod80 on topic Prod80's shader library
@klotim

Added new version, now has super high performance mode. This is now Quality = 2 and runs the shader at 0.6ms at 1/16th screen size. The old mode 2 is now quality 1 (1/4th screen size), and quality 0 is full screen (slow but accounts for each individual pixel).

Enjoy :)

On github.
Last edit: 4 years 1 month ago by prod80.
The following user(s) said Thank You: AssassinsDecree

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

  • gamehancer
More
4 years 1 month ago - 4 years 1 month ago #57 by gamehancer Replied by gamehancer on topic Prod80's shader library
I can send you an example in image I push the values for maximum to give you an idea my by decreasing the values it looks like sharp

the idea would be to remove only the chromatic aberration side and keep the sharp effect of the image > two link

shutterpulse.com/hdr-photoshop-actions/


https://www.facebook.com/photo.php?fbid=185569756229925&set=a.104522227668012&type=3&theater
Last edit: 4 years 1 month ago by gamehancer.

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

  • gamehancer
More
4 years 1 month ago - 4 years 1 month ago #58 by gamehancer Replied by gamehancer on topic Prod80's shader library
look link please
Last edit: 4 years 1 month ago by gamehancer.

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

  • prod80
  • Topic Author
More
4 years 1 month ago - 4 years 1 month ago #59 by prod80 Replied by prod80 on topic Prod80's shader library
FB link not working, other link wants to sell me sharpening filter but not explain what it does. Not sure what you're looking for? High pass sharpen? High pass creates lots of halo effects... good for photo's (per image adjustment in strength and options for masking) not good for motion. Unsharp mask is a lot better for that.

I know what you mean with using CA filter for sharpening... but that is not going to work.

Example:


And with heavy CA applied in a very small radius


But if you take out the CA, you end with the image without it.

The effect is just looking like that because you massively enhance the edges, but it's not actually useful.

Have a look at my sharpening shader. It does an Unsharp Mask and uses a Luminosity blend mode.

If you apply that heavily, you can get a better effect, likely. Please see example: imgsli.com/MTMzMzQ
Last edit: 4 years 1 month ago by prod80.
The following user(s) said Thank You: gamehancer

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

  • gamehancer
More
4 years 1 month ago #60 by gamehancer Replied by gamehancer on topic Prod80's shader library
thank you for all this explanation really I'm sorry if the link does not work I think I have a good idea because I would really like to find a shader for reshade that really looks like the hdr function as in photoshop sorry for the inconvenience

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

We use cookies
We use cookies on our website. Some of them are essential for the operation of the forum. You can decide for yourself whether you want to allow cookies or not. Please note that if you reject them, you may not be able to use all the functionalities of the site.