Skip to content

Commit 53d665a

Browse files
svc-reach-platform-supportEvergreen
authored andcommitted
[Port] [6000.4] [SRP] Fix Water SSR
1 parent e76f7aa commit 53d665a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Packages/com.unity.render-pipelines.high-definition/Runtime/Material/Water/Water.hlsl

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -415,9 +415,6 @@ PreLightData GetPreLightData(float3 V, PositionInputs posInput, inout BSDFData b
415415
// Grab the water profile of this surface
416416
WaterSurfaceProfile profile = _WaterSurfaceProfiles[bsdfData.surfaceIndex];
417417

418-
// Make sure to apply the smoothness fade
419-
EvaluateSmoothnessFade(posInput.positionWS, profile, bsdfData);
420-
421418
// Profile data
422419
preLightData.tipScatteringHeight = profile.tipScatteringHeight;
423420
preLightData.bodyScatteringHeight = profile.bodyScatteringHeight;

Packages/com.unity.render-pipelines.high-definition/Runtime/Water/Shaders/ShaderPassWaterGBuffer.hlsl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ void Frag(PackedVaryingsToPS packedInput,
5151

5252
// Compute the BSDF Data
5353
BSDFData bsdfData = ConvertSurfaceDataToBSDFData(input.positionSS.xy, surfaceData);
54+
WaterSurfaceProfile profile = _WaterSurfaceProfiles[bsdfData.surfaceIndex];
55+
EvaluateSmoothnessFade(posInput.positionWS, profile, bsdfData);
56+
5457

5558
// If the camera is in the underwater region of this surface and the the camera is under the surface
5659
#if defined(SHADER_STAGE_FRAGMENT)

0 commit comments

Comments
 (0)