Refraction shader for Unity's URP (Universal Render Pipeline).
Based on HDRP's ScreenSpaceRefraction.
This shader is created in Shader Graph, so you can easily modify it to add more features. (ex. NormalMap)
Please read the Documentation and Requirements before using this repository.
(Sample)
Dithered Transparent Shadows are available in URP 14 (Unity 2022.2) and above. (with high PCF shadow sampling)
Please refer to this.
- URP 12.1 and above. (URP 14 if using Dithered Transparent Shadow)
- Depth Texture Enabled in current URP Asset.
- Opaque Texture Enabled in current URP Asset.
- Set Material Type to Transparent.
- Enable Alpha Clipping in material if using Dithered Transparent Shadow.
- Perspective Camera (Orthographic Projection is not supported)
- Will not handle recursive refraction.
- Other transparent objects will not appear in refraction.
- Does not support rough refraction. (Color Pyramid Custom Renderer Feature needed)
Does not support transparent shadow. (Dithered Transparent Shadow in Shader Graph?)(Done)- Will not support transparent colored shadow.