Search Issue Tracker
By Design
Votes
0
Found in
2021.3.36f1
2022.3.22f1
2023.2.15f1
6000.0.0b12
Issue ID
UUM-67526
Regression
No
Custom shader is displayed incorrectly in the Play Mode when SRP Batcher is enabled
Reproduction steps:
1. Open the attached “repro_IN-71109“ project
2. Open the “SampleScene“
3. Select the “/Assets/Settings/URP-Balanced.asset“ and, under the “Rendering”, enable the “SRP Batcher“
4. Enter the Play Mode
5. Observe the Game view
Expected result: Half of the “Sphere“ GameObjects change their visual appearance
Actual result: All of the Sphere“ GameObjects change their visual appearance
Reproduced with: 2021.3.36f1, 2022.3.22f1, 2023.2.15f1, 6000.0.0b12
Reproducible on: Windows 10 (22H2)
Not reproducible on: No other environments tested
Notes:
- Reproducible in Player
- Making the Timer shader variable declaration be per material fixes the issue
- If you’re not able to see the “SRP Batcher“ parameter, make sure that the “Visibility“ is set to “All Visible“ in the “Edit → Preferences → Core Render Pipeline“
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
- “Remove Unused Overrides” available on not loaded Scene and throws “ArgumentException: The scene is not loaded” warning
- Adaptive Probe Volume occlusion edge is calculated incorrectly when viewing probes near geometry edges
- Sampling a texture using an HLSL file throws shader errors and the code does not compile
- "Graphics.CopyTexture called with null source texture" error when Base Camera of an Overlay Camera is removed with DX11 Graphics API and Compatibility Mode enabled
- WebGL sends wrong value with large numbers when SendMessage function is used
Resolution Note:
The custom shader is using a shader var "_Timer" that could be different per sphere (and each sphere is using its own material). This property "Timer" could have one different value per sphere. In ShaderGraph, the scope of this "Timer" var should be "Per Material" instead of "Global"