Search Issue Tracker
By Design
Votes
0
Found in [Package]
10.0.0-preview.27
Issue ID
1277644
Regression
No
[HDRP] Objects with Custom Pass Layer Mask does not becomes invisible when hiding the layer in Layers dropdown
How to reproduce:
1. Open the attached project "case1277644" and scene "SampleScene"
2. In the top right click on Layers dropdown
4. Hide the "UI" layer
3. Observe the Scene window
Expected result: Objects with the "UI" layer are not rendered in the Scene view
Actual result: Objects with the "UI" layer are rendered in the Scene view
Reproducible with: 7.5.1(2019.4.12f1), 9.0.0-preview.54(2020.1.8f1), 10.0.0-preview.27(2020.2.0b6)
Could not test with: 2018.4.27f1(No Custom Pass)
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
- Texture Import Warnings are obscured by other Terrain Layer options in the Inspector
- Active Targets section text in Graph Inspector is truncated despite available space
- Burst Inspector middle divider is jittering when resized with the Burst Inspector window docked
- Shader Graph Node information is briefly displayed in Graph Inspector when clicking on Category in the Blackboard
- JsonConvert conversion fails trying to call GetCallbackMethodsForType when [OnDeserialized] is used in a class
Resolution Note:
This is the expected behavior of the custom pass.
Changing the layer visibility in the editor directly affects the scene camera culling mask and removes certain objects from the camera, but the DrawRenderers custom pass has a separated custom culling so it can render objects that are not visible in the camera. This is why you can still see objects rendered by the custom pass even when hiding the layer.
This is an essential feature to allow rendering objects only in the custom pass (for example in another buffer) and then composing the image later on. There are a lot of systems/effects that rely on this feature so we can't change it.
Note that from HDRP 10.1.0 and above, you can use the scene visibility tools to hide the custom pass volume which will disable the effects in the scene view.