Search Unity

Changing the default tree billboard shader Universal RP, URP

Discussion in 'World Building' started by jacobfnl, Feb 26, 2021.

  1. jacobfnl

    jacobfnl

    Joined:
    Jan 18, 2018
    Posts:
    4
    I have need to replace the standard Tree billboard shader to provide a second clip apart from the Tree Distance using world space (positionWS).
    However, I can not seem to find the shader responsible for the tree billboarding in the Universal RP 7.3.1 package. I've tried turning the fog a truly garish red to see the effect of MixFog(), which apparently has none on the tree billboards, but It does on the terrain. Somehow it takes on fog, but does not use that particular function. Does anyone know which shader is responsible for the tree billboards as their instances are composited?

    2021-02-25 (8).png
     
  2. jacobfnl

    jacobfnl

    Joined:
    Jan 18, 2018
    Posts:
    4
    Looping back to close this.

    In general, you can replace the billboard shader with a custom one. My custom BillboardTree.shader started by downloading the default Unity shaders for the editor version I used. Then, modifying the BillboardTree.shader, and including it in the projects Assets.

    Ultimately, there was a problem with this particular terrain which would not use my billboard tree shader. I instead had to use a fresh terrain. I still don't understand the underlying issue with that particular terrain.