URP_ShaderGraphCustomLighting icon indicating copy to clipboard operation
URP_ShaderGraphCustomLighting copied to clipboard

[Unity 6] APV

Open Cyanilux opened this issue 9 months ago • 3 comments

Unity 6 has a new light probe system https://docs.unity3d.com/6000.0/Documentation/Manual/urp/probevolumes-concept.html

ShaderLibrary code here suggests that the Baked GI node that URP provides should support APV, provided the graph defines the appropriate keywords. Lit Graphs should already include them (but for custom lighting you'd typically use an Unlit Graph)

For an Unlit Graph, should be able to use an Enum Keyword in the blackboard :

  • Reference : PROBE_VOLUMES and Entries : OFF, L1 & L2
  • Set to Global/IsOverridable and untick Exposed/GenerateMaterialProperty
Image

Alternatively, could use a Custom Function with :

  • #pragma multi_compile _ PROBE_VOLUMES_L1 PROBE_VOLUMES_L2 or
  • #include_with_pragmas "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ProbeVolumeVariants.hlsl"

Those may also avoid shadergraph keyword limits.

Cyanilux avatar Jun 23 '25 15:06 Cyanilux