Use Curves Twice?

  • Posts: 12
4 years 10 months ago #1 by RAmbO
I want to use the Parabola curve (9) for the Chroma channel to achieve nice colors but I also want to use a lower strength Sine curve (1) for the Luma channel to add contrast. I was wondering what the best method would be to achieving the curves effect twice?

Do I try put the Curves shader into Custom.h? If so, this would equal another pass and would reduce performance, right? Maybe the Curves.h file can be modified for best performance? Can someone lead me on the right path, thanks.

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

  • Posts: 790
4 years 10 months ago - 4 years 10 months ago #2 by Ganossa
If you mean the SweetFX curves shader, its not as simple to duplicate cause this is a shared shader. Unless you know your way around HLSL :)

However, if you still want to try, copy the curves content below the #if (USE_CUSTOM == 1) in the Custom.h.
For an easy start copy the required variables from the SweetFX.cfg also below #if (USE_CUSTOM == 1) and make sure to add an #undef <variableName> for each added #define <variableName> before the #endif.
Change return tex2D(RFX_backbufferColor, texcoord); in the PS_Custom function
to return CurvesPass( tex2D(RFX_backbufferColor, texcoord) );

Enabling Custom shader/effect in the Pipeline tab should now enable curves with the settings in the Custom.h. :side:

Hope it works for you with the first try (did not try it myself its just out of the head) :silly:
The following user(s) said Thank You: RAmbO

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

  • Posts: 3741
4 years 10 months ago #3 by crosire
Alternativly create the settings you would like in some tool like Photoshop, apply them to the LUT table in "ReShade\CustomFX\Textures" and use the so called "TUNINGPALETTE" shader instead to get the results in-game.
The following user(s) said Thank You: RAmbO

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

  • Posts: 12
4 years 10 months ago #4 by RAmbO
I may go this route since I'm already using the tuning palette LUT for darkening cyans for skyboxes. I'm just not sure how to replicate the curves formulas in photoshop. Also not sure how to seperate chroma and luma. I'll experiment and see what I come up with since this will be better performance than using an extra pass for custom.h.

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

  • Posts: 12
4 years 10 months ago #5 by RAmbO
Thanks for the help guys. I've gone and done most of the color corrections in the LUT so I'm just using the LUT and Lumasharpen now instead of like 10 different things lol.

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

  • Posts: 790
4 years 10 months ago - 4 years 10 months ago #6 by Ganossa
Crosire is absolutly right and since you seem already to know about how to use LUT.

If you are not familiar with photoshop I suggest the following.

Run the preview feature in the mediator and apply all color correction/contrast effects that you need plus one of the curve passes.

Now press L+prtscr to generate the LUT within a ReShade screenshot.

Disable all effects and only apply the just created LUT to the preview feature.

Now you have the choice to apply another curve pass and be done or even create another LUT to get rid of all color correction/contrast performance impact :)

EDIT: sorry, read your post too late, good you solved it the way its most efficient :)
The following user(s) said Thank You: RAmbO

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

  • Posts: 12
4 years 10 months ago #7 by RAmbO
Wow you can generate LUT? Thanks for the heads up. I'm satisfied with my current results but now I'm itching to make a new LUT using the Curves formulas for the contrast since I just did random curves in Photoshop.

This is the results of my current LUT
Off: sfx.thelazy.net/static/media/presetscree...scompare/eso-off.png
On: sfx.thelazy.net/static/media/presetscreenshots/eso_HfFJxVi.png

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