Skip to content

VKev/Unity-URP-Shaders-Code

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

59 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

URP shader project

Using shader code, Non-shader graph

Unity 2023.2.0b1

How to use

For all shader:

-Download and copy the VkevShaderLib.hlsl file in your assets folder (Impotant)
-The directory of the VkevShaderLib should be assets/VkevShaderLib.hlsl

For Outline post process:

-Add outline render feature to your universal render data

-Add outline override to global volume

drawing

For Grass shader:

-Blend grass color with terrain feature need the texture map of terrain, you can create a render texture that render terrain color or simply use terrain texture map.

-Blend grass color with terrain feature can be turned off by set the Blend intensity in material inspector to 0

For Tessellated water shader:

-Reflection feature need a reflection cubemap - which you can bake using unity reflection probe.

For any shader with interact with player feature:

-Set shader global property _PlayerWpos to player position in update().

-Only work with 1 player.

Show case

Toon Shader:

-Color, texture customizable.
-All light support.
-All shadow support.
-Shadow quality customizable with URP asset.

Youtube: watch here

drawing

Outline Shader:

-Using scriptable renderer feature.
-Outline color customizable.
-Can toggle see through wall on/off.
-Specify which layer is outline.
-Depth, Normal outline customizable.
-Support volume setting, camera postprocess.

Youtube: watch here

drawing

Stylized Grass Shader:

-Blend grass color with terrain.
-Interactive grass.
-Wind Local/world direction, randomize wind or sync wind.
-All light support.
-Color, texture customizable.

Optimization: GPU instancing, Occlusion culling, Frustum culling, LOD.

Youtube: watch here

drawing drawing

Water Shader:

-Water distortion.
-Wave by noise.
-Foam customizable.
-Reflection with reflection probe.

Youtube: watch here

drawing

drawing

About

Some shader code project for URP

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published