Fix: Workbench: Incomplete commit 5231f0c02a

The commit didn't include the other part of the fix and
included an invalid changed line.
This commit is contained in:
Clément Foucault
2025-07-01 12:41:02 +02:00
parent 5231f0c02a
commit c49e9e1773
2 changed files with 2 additions and 2 deletions

View File

@@ -428,7 +428,7 @@ void dof_gather_init(float base_radius,
/* TODO(fclem) Seems like the default lod selection is too big. Bias to avoid blocky moving out
* of focus shapes. */
constexpr float lod_bias = -2.0f;
lod = max(floor(log2(base_radius * unit_sample_radius) + 1.0f) + lod_bias, 0.0f);
lod = max(floor(log2(base_radius * unit_sample_radius) + 0.5f) + lod_bias, 0.0f);
if (no_gather_mipmaps) {
lod = 0.0f;

View File

@@ -21,7 +21,7 @@ void main()
/* Clamp infinite inputs (See #112211). */
color = clamp(color, float4(0.0f), float4(1e10f));
/* Use log2 space to avoid highlights creating too much aliasing. */
color = log2(color + 0.5f);
color = log2(color + 1.0f);
frag_color += color * samplesWeights[i];
}