Stylized Grass Shader Documentation

Stylized Grass Shader

Stylized Grass Shader
Version: 1.3.0
Review

8.Controlling wind #

Setup

Normally, the wind settings are controlled on a per-material basis. The related settings can be found under the “Wind” section:

All the parameters have tooltips. Mouse over to view a description

It is however possible to use a Wind Zone to influence the strength/speed values for wind. On a Stylized Grass Renderer component, you’ll find the option to assign one:

If you do not have an GameObject with a Stylized Grass Renderer component, be sure to add it somewhere.

Once a Wind Zone has been assigned,

  • The “Main” parameter value will act as a multiplier for the Ambient Strength and Gusting Strength parameters on all grass materials.
  • The “Turbulence” parameter is a multiplier for just the Gusting Strength.
  • The wind direction will be set based on the Wind Zone’s forward vector (blue arrow)

Because the wind gusting animation is based on a panning texture map, it’s not possible to dynamically change wind direction. If you intend to do this, set the Turbulence parameter to 0!

If in effect, a notification is also displayed in the material UI:

Usage notes

If you’re using a weather system like Enviro, you can assign the Wind Zone object is has created. Should it be necessary, you can also use the static StylizedGrass.StylizedGrassRenderer.SetWindZone() function to assign a specific Wind Zone reference.

It is recommend to now set the wind to its maximum strength (or activate a storm-like weather profile), then fine tune the wind strength on all grass materials to look right for this situation. This is to ensure that you know how the grass will behave under extreme circumstances.

Vegetation Studio

If you are using Vegetation Studio, ensure that the same Wind Zone is also assigned on the Vegetation System, under the “Environment” tab:

All systems should use the same Wind Zone object, to ensure they’re synchronized.

Yes No Suggest edit
Last updated on October 17, 2022
0 of 0 users found this section helpful
Suggest Edit