Stylized Grass Shader Documentation

Stylized Grass Shader

Stylized Grass Shader
Author: jonathan
Version: 1.1.9
Dated: 31 Aug 2019

10.Troubleshooting #

Grass only renders as shadows in Unity 2021.1

Right-click on the StylizedGrassShader folder and choose re-import to nudge things back into place. This likely only needs to be done once, after upgrading to this version.

The issues lies with the fact that the files are importing normally, but the URP is updated afterwards. As a result, the shaders fail to find the URP shader libraries, unless they’re forced to refresh, this is done by reimporting the files.

Shadows are flickering (fixed in Unity 2020.1+)

When using the Distance Fading or Perspective Correction feature, in conjunction with the terrain vegetation system shadows will appear to flicker.

This has been identified as a bug in the URP, and has been reported. It also occurs when placing the grass prefabs in the scene, and rendering *anything* using the terrain vegetation system. It is also reproducible in Shader Graph shaders.

A bug report has already been filed. If this affects you, please place a vote, which will bump up its priority:

Console errors

Assertion failed on expression: ‘0 == m_CurrentBuiltInBindMask’ UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

This is sometimes thrown when the shader recompiles, and appears to be a bug in Unity’s Async shader compiler. Fortunately, it’s harmless.

Yes No Suggest edit
Last updated on February 20, 2021
2 of 2 users found this section helpful
Suggest Edit