tentative#852
Closed
sindharta-tanuwijaya wants to merge 5 commits into
Closed
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates Unity Toon Shader’s URP lighting variant handling by renaming the Forward+ keyword/macro usage to the newer Cluster Light Loop naming, aligning shader variants and conditional code paths.
Changes:
- Replace
USE_FORWARD_PLUSconditionals withUSE_CLUSTER_LIGHT_LOOPin URP HLSL code. - Replace
#pragma multi_compile _ _FORWARD_PLUSwith#pragma multi_compile _ _CLUSTER_LIGHT_LOOPin shader templates and generated shaders. - Update subtractive-light handling usage in the Cluster Light Loop directional light path (but currently missing the corresponding macro definition).
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| com.unity.toonshader/Runtime/Shaders/URP/UniversalToonBodyShadingGradeMap.hlsl | Switch directional-light loop guard from Forward+ to Cluster Light Loop. |
| com.unity.toonshader/Runtime/Shaders/URP/UniversalToonBodyDoubleShadeWithFeather.hlsl | Switch directional-light loop guard and subtractive check macro name to Cluster Light Loop. |
| com.unity.toonshader/Runtime/Shaders/URP/UniversalToonBody.hlsl | Remove Forward+ subtractive check macro block; update GI conditional to Cluster Light Loop. |
| com.unity.toonshader/Runtime/Shaders/UnityToonTessellation.shader | Update generated URP pass keyword from _FORWARD_PLUS to _CLUSTER_LIGHT_LOOP (and regen timestamp). |
| com.unity.toonshader/Runtime/Shaders/UnityToon.shader | Update generated URP pass keyword from _FORWARD_PLUS to _CLUSTER_LIGHT_LOOP (and regen timestamp). |
| com.unity.toonshader/Runtime/Shaders/Common/Parts/UnityToonTessellation.shadertemplate | Update URP pass multi-compile keyword to _CLUSTER_LIGHT_LOOP. |
| com.unity.toonshader/Runtime/Shaders/Common/Parts/UnityToon.shadertemplate | Update URP pass multi-compile keyword to _CLUSTER_LIGHT_LOOP. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| @@ -21,14 +21,6 @@ | |||
| # endif | |||
| #endif | |||
|
|
|||
|
|
||
| #if USE_FORWARD_PLUS | ||
| #if USE_CLUSTER_LIGHT_LOOP | ||
| // directional lights in Forward Plus |
|
|
||
| #if USE_FORWARD_PLUS | ||
| #if USE_CLUSTER_LIGHT_LOOP | ||
| // directional lights in Forward Plus |
Collaborator
|
Replaced by #853 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.