Search Unity

Question Unlit material that receives shadows from other game objects

Discussion in 'Shader Graph' started by sandstedt, May 10, 2019.

  1. sandstedt

    sandstedt

    Joined:
    May 24, 2015
    Posts:
    67
    As a continuation from this question, are there a smart solution today with LWRP/HDRP and Shader Graph to accomplish this look?

    Here's my criterias, using an character as en example:
    * Character should cast shadows on the environment
    * Character should receives shadows from the environment
    * Character should NOT cast or receive its own shadows (like an unlit shader)

    As long as I can create a shader graph with an unlit material that can receive shadows, I guess I could solve it using a custom rendering pass where I duplicate the pass and replace the materials on the character to one that only cast shadows.

    The effect would me much like how a 2D sprite that can receive shadows from the environment looks.

    (Tried my best to illustrate the effect below)

    lightning-visualisation.png