From 642f3ea8e77aaa9a9bebebbc325a7c2647a7e895 Mon Sep 17 00:00:00 2001 From: Alexandre Coirier Date: Wed, 10 Jun 2026 00:42:20 +0200 Subject: [PATCH] wip: Sand shader remive unused lines --- .../HouseOfLeaves/Shaders/Sand.hlsl | 29 ------------------- 1 file changed, 29 deletions(-) diff --git a/Assets/_Content/Models/Environments/HouseOfLeaves/Shaders/Sand.hlsl b/Assets/_Content/Models/Environments/HouseOfLeaves/Shaders/Sand.hlsl index db866ad4..6d29776a 100644 --- a/Assets/_Content/Models/Environments/HouseOfLeaves/Shaders/Sand.hlsl +++ b/Assets/_Content/Models/Environments/HouseOfLeaves/Shaders/Sand.hlsl @@ -14,24 +14,11 @@ void Sand_float out float Alpha ) { - //float t = frac(_Time.y / 20); float t = Progression; t -= RidgedNoise3D(PositionWS, .3, 1, 2, .5) * .3; float depth = length(PositionWS - _WorldSpaceCameraPos.xyz); - //Light mainLight = GetMainLight(0); - //float3 mainLightDir = normalize(mainLight.direction); - //float lightGradient = dot(normalize(NormalWS), normalize(mainLightDir)); - //lightGradient = smoothstep(-.5, 1, lightGradient); - //float ao = GetScreenSpaceAmbientOcclusion(ScreenUV).directAmbientOcclusion; - - // Arks - - /*float arkMask = abs(frac(PositionWS.z * .5) * 2 - 1); - arkMask = pow(smoothstep(.7, 0, arkMask), 2); - arkMask += smoothstep(2.8, 3.2, abs(PositionWS.x)); - arkMask = saturate(arkMask);*/ float arkMask = 0; // Sand @@ -40,9 +27,6 @@ void Sand_float float sandDirection = cos(t * sandLayers * 3.14); - //float sandDensity = smoothstep(1.5, 0, abs(PositionWS.x)); - //sandDensity = saturate(sandDensity + arkMask); - float sandPatern = RidgedNoise3D(PositionWS + float3(sandDirection, 0, 0), .6, 1, 2, .5) * .8; sandPatern += 1 - RidgedNoise3D(PositionWS + float3(0, 0, t * sandLayers * 2), .8, 2, 2, .5) * .2; @@ -57,18 +41,6 @@ void Sand_float float sandMask = sandFlow * 1.5 - t * .8 + (sandPatern * 2 - 1) * sandDensity * t * .3; sandMask *= sandDensity * .7 + .3; - // Test - - //float test = ValueNoise3D(PositionWS, 40); - //float test = PerlinNoise3D(PositionWS, 40); - //float test = PerlinNoise3DLOD(PositionWS, 100, 3.5); - //float test = SimplexNoise3D(PositionWS, 40); - //float test = WorleyNoise3D(PositionWS, 40, 1); - //float id; - //float test = VoronoiNoise3D(PositionWS, 10, 1, .05, id); - //float test = FBMNoise3D(PositionWS, 10, 2, 2, .5); - //float test = RidgedNoise3D(PositionWS, 10, 2, 2, .5); - // Output Position = PositionWS; @@ -77,7 +49,6 @@ void Sand_float Height = sandMask; Alpha = smoothstep(1, .5, abs(smoothstep(-20, 20, PositionWS.x) * 2 - 1)); - //Debug = sandFlow; } #endif