Search Issue Tracker
By Design
By Design in 2023.1.X
Votes
0
Found in
2021.3.14f1
2022.1.23f1
2022.2.0b15
2023.1.0a19
Issue ID
UUM-21094
Regression
No
Custom Pass makes Scene view flicker when viewing an Instanced Terrain
How to reproduce:
1. Open the attached user project
2. Open Scene “SampleScene“ (Assets/Scenes)
3. Observe the “Terrain“ GameObject in the Scene view
Expected result: There is no flickering
Actual result: The Scene view is flickering
Reproducible with: 2021.3.14f1, 2022.1.23f1, 2022.2.0b15, 2023.1.0a19
Can’t test with: 2020.3.42f1 (Everything is white)
Reproduced on: macOS (12.5 Intel)
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
- Assets are created in the Package folders when creating assets via custom buttons in the Inspector window or other windows
- “Select” windows are named differently on Windows and macOS
- [Windows] No minimum “Select” window size
- Enabling “Editor Extension Authoring” in UI Builder doesn’t dirty the document and saving with shortcut doesn’t persist the state
- WebRequest.Create() function fails with "URI prefix is not recognized" errors when the project is built for Linux Standalone or Windows Dedicated Server
Resolution Note:
In your repro project, you're trying to render the terrain with an HDRP/Lit shader in your custom pass. This is not supported, only HDRP/TerrainLit shader can be used to render terrain at the moment.
Also, note that due to how the terrain system works, Material replacement is not supported. This is because internally the terrain system sets properties on a copy of the material that is not available in the public API.
As a possible workaround, you could use the replacement shader mode in custom passes introduced in HDRP 14.0. If you provide a modified copy of the HDRP terrain lit shader it should work.
We'll also update the documentation regarding terrain compatibility and custom passes
Resolution Note (2023.1.X):
In your repro project, you're trying to render the terrain with an HDRP/Lit shader in your custom pass. This is not supported, only HDRP/TerrainLit shader can be used to render terrain at the moment.
Also, note that due to how the terrain system works, Material replacement is not supported. This is because internally the terrain system sets properties on a copy of the material that is not available in the public API.
As a possible workaround, you could use the replacement shader mode in custom passes introduced in HDRP 14.0. If you provide a modified copy of the HDRP terrain lit shader it should work.
We'll also update the documentation regarding terrain compatibility and custom passes