Search Issue Tracker
By Design
Votes
0
Found in
2017.4
2020.1
2020.1.0a19
Issue ID
1213749
Regression
No
Shader properties are ignored when SetReplacementShader method is invoked
How to reproduce:
1. Open the attached '1213749.zip' project
2. Open 'SampleScene' Scene
3. Enter Play Mode
4. Notice that 'Cube' GameObject is red
5. Open 'Unlit_Modified.shader' shader
6. In 44 line, change fixed4 data type's red value from '1.0' to 'RedVal'
7. Enter Play Mode
Expected result: 'Cube' GameObject is red
Actual result: 'Cube' GameObject is black
Reproducible with: 2017.4.36f1, 2018.4.17f1, 2019.2.20f1, 2019.3.1f1, 2020.1.0a22
Notes:
1. Project and video of reproduction is attached in Edit
2. Reproducible on macOS
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- "Draw Additional Lights Shadowmap" calls increase when custom MaterialBlockProperty is used
- Crash on _platform_memmove when importing the "Dragon Crashers - URP 2D Sample Project" to a new 2D project
- "Shader is not supported on this GPU" warnings and and shaders are not loading when building the project for non-Chromium browsers
- [iOS][URP] The screen flickers and the "Execution of the command buffer was aborted due to an error during execution" error is thrown continuously
- Shortcut Manager shows empty conflict filter when resolving runtime conflicts involving different contexts
Resolution Note:
The script is missing Shader.SetGlobalFloat("RedVal",1.0f);
Add this so that RedVal has the value.