Skip to content

invincible0918/CustomShader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

Optimize Unity's default PBR shader for our mobile game

We use shader lod to switch between high/low end devices.

  1. Remove additive forward pass (one light per pass) and deferred renderring pass to reduce shader variants.

  2. Unity default PBR shaders are very important aspects in 3D space. It enhances spatial awareness of objects in 3D space and give better user experience for players. However, it rendering is GPU intensive process. For low-end mobile devices, it will slow down our games.

    So we use custom shading model (standard blinn/phong shading model) instead of PRB in mobile device.

  3. Use custom shadow method.

    3.1 We choose a useful mesh search tree called “Mesh Tree” which is used to search for polygons which are receiving shadows. picture

3.2 Use a R8 texture format to render shadow map from main light view. Then blur it with 3 draw calls.

picture

3.3 Final image.

picture

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published