Skip to content

Commit

Permalink
Update HDRSaturation.fx
Browse files Browse the repository at this point in the history
- Gamut Expansion clipping limit is now using softer version limiter
- Defaults edit
  • Loading branch information
MaxG2D authored Aug 27, 2024
1 parent 6896d60 commit c4f8e1b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Shaders/HDRSaturation.fx
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ uniform float UI_SATURATION_COLORS_LIMIT <
ui_tooltip = "Avoid clipping out color details.";
ui_step = 0.01;
ui_type = "slider";
> = 0.50;
> = 0.70;

uniform float UI_SATURATION_GAMUT_EXPANSION_CLIPPING_LIMIT <
ui_category = "Saturation - Advanced";
Expand All @@ -103,7 +103,7 @@ uniform float UI_SATURATION_GAMUT_EXPANSION_CLIPPING_LIMIT <
ui_tooltip = "How much Gamut Expansion is controlled by image luminance";
ui_step = 0.01;
ui_type = "slider";
> = 0.85;
> = 0.90;

float3 SaturationAdjustment(float4 vpos : SV_Position, float2 texcoord : TEXCOORD) : SV_Target
{
Expand Down Expand Up @@ -184,7 +184,7 @@ float3 SaturationAdjustment(float4 vpos : SV_Position, float2 texcoord : TEXCOOR
ProcessedColor = ExpandGamut
(
ProcessedColor,
(UI_SATURATION_GAMUT_EXPANSION / 5) * saturate(smoothstep(1, 1.0 - Chroma, UI_SATURATION_GAMUT_EXPANSION_CLIPPING_LIMIT))
(UI_SATURATION_GAMUT_EXPANSION / 5) * saturate(smoothstep(1, 1.0 - OKlabLuminanceSoft, UI_SATURATION_GAMUT_EXPANSION_CLIPPING_LIMIT))
);
ProcessedColor = GamutMapping(ProcessedColor);
}
Expand All @@ -207,4 +207,4 @@ ui_label = "HDRSaturation";>
}

//Namespace
}
}

0 comments on commit c4f8e1b

Please sign in to comment.