Unity Issue Tracker - Shader Graph "use of undeclared identifier" error when using a custom function that references a graph property
Closed
UUM-75808
Shader Graph "use of undeclared identifier" error when using a custom function that references a graph property
Unity: ShaderGraph
Won't Fix
6.0.X
2022.3.X
Recommend creating and input port and linking the material property via the graph. Custom function nodes are not intended around supporting global access to the entire shader (though many things will work), so we likely won't fix this.
How to reproduce:
1. Open the attached “IN-80312“ project
2. From the “Project” window select the “GeneratedFromGraph-Test“ file
3. See the “Imported Object“ section in the Inspector window
Expected result: The shader compiles successfully
Actual result: Error message "use of undeclared identifier" is shown
Reproducible in: 2022.3.38f1, 6000.0.11f1
Could not test with: 2021.3.40f1(Could not resolve package errors)
Reproduced on: Windows 11 Pro
Not reproduced on: No other environment tested
Prioritise and Follow this issue
Have a workaround or additional info about this issue?