Search Unity

[URP] Shadergraph material goes black in android build

Discussion in 'Universal Render Pipeline' started by Raul_T, Nov 26, 2019.

  1. Raul_T

    Raul_T

    Joined:
    Jan 10, 2015
    Posts:
    363
    Hello!

    I've been working on a personal project lately, on URP, to familiarize with the new pipeline and the shadergraph, and I've stumbled across an issue that has been driving me crazy for the past days.

    Basically I have this shader from a low-poly tutorial that I adapted for my terrains needs, made with shadergraph, which goes black in builds (running on android, tried both opengl and vulkan, same result) and I don't know exactly why. I already tried to add the shader to the always included shaders in the graphics settings of the projects, it didn't changed anything.

    Am I using some node/value which is not supported on mobile devices - making it fall back? Or is it by any chance a bug which may be worth reporting?

    Running on Unity 2019.3.0b12, URP v 7.1.5
    The material is assigned to a unity terrain (not sure if this might be an issue).



    Result in editor


    Result in build (Samsung Galaxy S8, Vulkan API, Android 9)
     
  2. Andre_Mcgrail

    Andre_Mcgrail

    Unity Technologies

    Joined:
    Dec 9, 2016
    Posts:
    244
    Hey,

    Currently Shader Graph does not support creating shaders for terrain, it does not generate all the required passes and data for correct terrain rendering. This work is being looked at by the Shader Graph team.

    Regards
     
    Jokonut and Raul_T like this.
  3. Fressbrett

    Fressbrett

    Joined:
    Apr 11, 2018
    Posts:
    97
    Bump, is this added by now? This seems like a big missing feature.

    I only want to make a triplanar URP terrain shader, which is not possible with ShaderGraph and the default URP terrain shader is not triplanar :(
     
    Jokonut and pokruchin like this.
  4. luminator

    luminator

    Joined:
    Jun 24, 2016
    Posts:
    7
    Hey, I have the same exact problem with shader applied to regular object. In preview it's alright, on android build (Oculus Quest) it's black. Shader's not on terrain, just a bunch of different fbx models. Specifically nodes connected to smoothness are causing the problem
     
  5. AlexHogan

    AlexHogan

    Joined:
    Oct 8, 2010
    Posts:
    7
    Were you using a Triplanar node? I'm experiencing this right now and it appears to be because of my use of a triplanar node. =(