top of page
HLSL Grass Shader
Studio
Solo Project
Year
2021
Engine
Unity
Location
Burlington, Vermont
This grass shader was developed in Unity using HLSL. The shader takes any form of mesh input and operates directly on the geometry with no external input mesh needed. Using a combination of fragment, vertex, and geometry shaders (as well as some custom tesselation), grass blades are constructed. This is accomplished by locating each specific vertex on the outer face of the mesh and constructing a blade of grass on it defined by several constant points which are then adjusted for any vertex's given tangent and normal. The wind affect is achieved via scrolling a map over the mesh with data stored in the map of how much "bend" to apply to the blades of grass. Based off grass by Roystan.



bottom of page