Godfall - Environment Shaders

Vert blend shader functionality - upvector masking, macro normal/albedo overlay, 4 blend layers, height lerp wetness painting, scale based tiling, top-down world space UVs for floors and iridescence. Rock by Noah Kobus - https://www.artstation.com/n_kobus

The 3rd layer supports an alpha mask to prevent certain areas ever getting painted in. Useful for lichen, vines etc that will respect underlying layers

The 4th layer supports up-vector masking, and moss fuzzy shading. Where moss is painted, the input normals for the fuzzy shading function can be spherized to reduce high frequency details and give a softer fuzz feeling

All layers have metal and non-metal albedo tinting with roughness and metalness tuning parameters. First and second layers also support tint mask inputs for further control. There is a couple controls for the height map blending as well.

There is also support for top-down projected world space UVs, useful to get consistency on ground floors. The WS projection can also be rotated - the shader will recalculate the normals to prevent broken shading.

This shader doesn't have opacity mask or world space UVs, it uses pixel depth offset, distance fields and POM to auto-mask based on intersecting geometry and the input height map.

Scale-based tiling in the X/Y coordinates allow for more flexibility and re-use when the artists are meshing their levels. These piles can blend seamlessly into the flat vert blend coins and provide more volume when needed.

High level overview of how I approached shader organization for this project. The vert blend shader is easily the most complex of all shaders for the game. No more spaghetti!

High level overview of how I approached shader organization for this project. The vert blend shader is easily the most complex of all shaders for the game. No more spaghetti!

Overview of the base library of master materials for the environment team. At first glance this looks like a lot but there is a lot of overlap by the way of material functions.

Overview of the base library of master materials for the environment team. At first glance this looks like a lot but there is a lot of overlap by the way of material functions.

Having consistent naming conventions and material function re-use allowed for the team to quickly make material variants with different core functionality without having to re-tune their entire material from scratch.

As the technical shader director for Godfall, I created the vast majority of shaders for the art team, providing support and troubleshooting throughout production. When applicable, I opted for more modular material functions, allowing me to stack and build shader variants quickly that are consistently organized for the artists. All shaders have quality switches throughout them as well.

There are a few main types of master materials:
- Prop
- Vert Blend
- Macro Mask
- Foliage/Trunk
- Decal
- Other more bespoke, but still common shaders like the water wall, lava, etc
And then there were variants of each of those archetypes (EnvPropSand/SSS, VertBlendSand/SSS and so on. This avoids having one monolithic uber shader - not feasible for our production - while still keeping things scalable but manageable.
Shout out to Evan McKnight for the feedback on the shader development, being a sounding board for practical usage of these features, and coordinating with the asset team to ensure that the material instance library was kept clean, and to the asset and level artists who put in requests throughout development and found all the bugs and had patience while I sorted them out :)
https://www.artstation.com/emcknight
https://www.artstation.com/enricot
https://www.artstation.com/anamrodriguez
https://www.artstation.com/alexbeddows
https://www.artstation.com/goodbyekitty137
https://www.artstation.com/robertgoldney
https://www.artstation.com/n_kobus