Rasagar/Assets/TerrainDemoScene_URP/Notes/WaterShader.txt

4 lines
588 B
Plaintext
Raw Permalink Normal View History

2024-08-26 13:07:20 -07:00
The water shader here uses the Shader Graph [Scene_Depth](https://docs.unity3d.com/Packages/com.unity.shadergraph@13.1/manual/Scene-Depth-Node.html) and [Scene_Color](https://docs.unity3d.com/Packages/com.unity.shadergraph@13.1/manual/Scene-Color-Node.html) nodes to create a simple animated refraction effect. A low-resolution mask adds some noise to the edges of the water to simulate the algae and debris that accumulate near the edge of the lake.
Click [here](Assets/TerrainDemoScene_URP/ShaderGraphs/WaterDepthBased.shadergraph) to open the shader and see how the illusion works.