Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Shadergraph Reflection Probe Node Compilation Errors?

Discussion in 'Shaders' started by stackdynamic, Sep 13, 2018.

  1. stackdynamic

    stackdynamic

    Joined:
    Mar 18, 2018
    Posts:
    13
    Hi, apologies for the probably obvious question, but I'm getting compilation errors when using the reflection probe node in shadergraph (version 3.0.0 on HDRP).

    Here are the relevant parts of my graph as shown below:

    upload_2018-9-12_20-56-54.png

    As you can see, I supplied the necessary inputs (view direction, normals and LOD) and am outputting directly to emission in my master node. I have my reflection probe component attached to the child of the plane using this shader, set to real time (I doubt this matters, adding for comprehensiveness). Anyways, I'm getting these errors when I save my shadergraph:
    upload_2018-9-12_21-3-22.png
    Could someone tell me what I might be doing wrong? I looked at the documentation for the reflection probe node already at https://github.com/Unity-Technologies/ShaderGraph/wiki/Reflection-Probe-Node which is unfortunately a bit sparse. I barely know any GLSL (hence why I'm using shadergraph) but some googling tells me that unity_SpecCube0 is the skybox cube map and should be defined in UnityShaderVariables.

    Sorry in advance for being stupid, would really appreciate some help. Thanks!
     

    Attached Files:

    Last edited: Sep 14, 2018
    C06 and Timato0 like this.
  2. C06

    C06

    Joined:
    Jun 18, 2017
    Posts:
    2
    I have the same issue
     
  3. YuriyPopov

    YuriyPopov

    Joined:
    Sep 5, 2017
    Posts:
    235
    I too have the same issue and would like to know how to get around it.
     
  4. stackdynamic

    stackdynamic

    Joined:
    Mar 18, 2018
    Posts:
    13
    Quick note: post-update (am on latest version of 2018.2) the error message changed to line 247, 249 and 250. My show generated code option doesn't seem to be working for some reason, but the message is the same as the one above.

    Again, sorry for the newby question, but I'm not sure what I'm doing wrong. Thanks!
     
  5. Tristan-Moore

    Tristan-Moore

    Joined:
    Aug 22, 2014
    Posts:
    18
    For anyone looking this up, the errors have gone away but the current version of Shader Graph (6.9.2) only supports the lightweight render pipeline. https://docs.unity3d.com/Packages/com.unity.shadergraph@6.9/manual/Reflection-Probe-Node.html

    This will likely change in the future, but if you are wondering why the node doesn't work in HDRP, it's because it's just a placeholder and is not implemented yet. It will still produce black anytime you try to use it outside LWRP/URP.