top of page

Shaders

  • Writer: Good Good Games
    Good Good Games
  • May 6, 2019
  • 2 min read

This post comes from one of our programmers and describes a recurring issue we had with shaders in the game:


"The shader issue that we kept running into had to deal with custom shaders communicating with shaders created from the Shader Graph. The goal was to create a "toon" shader that would be applied to all the assets in the game. This became a priority late in development, so a lot of assets using a PBR (physically based rendering) pipeline already existed. The basic toon shader was developed in a custom scene with just Ember's model and a couple of props. After a while we were able to get a basic toon shader on Ember that took in an albedo texture and a toon lighting LUT (a LUT is a 1x256 pixel texture that controls how the model gets shaded in regard to the lighting direction) that gave a cartoony-feeling effect, similar to Wind Waker. In order to avoid adding this custom texture to every object in the scene manually, we tried to use it as a "replacement shader" in the camera. This would take the existing materials on objects and render them using their existing textures, but with the code of the toon shader. We were able to get the system working with standard materials in a new project, but after more than a week of fighting with it we were unable to get the replacement shader to work in our project. The goal became to get the toon shader to work with existing materials and shaders, so the artists wouldn't have to recreate or edit their existing textures. After getting the toon shader to use the textures already present in the Shader Graphs, the shader was modified to use a work-around in which the textures could be accessed with a bit of work, however many of the existing models and textures had so much detail that the toon shader looked flat and frankly, awful, on them—even though it worked perfectly with Ember and the design we wanted for her. In the end we decided the shader would only be used on Ember, because it would help to give her a more "warm" feel, and help her model stand out. Perhaps, given more development time, the shader could be improved to work well with the existing PBR shaders."

Recent Posts

See All
End of the Semester

The semester is coming to an end and for most of us that means college graduation. "Ember" has essentially been a year-long project, but...

 
 
 

Comments


bottom of page