Search Issue Tracker
By Design
Votes
0
Found in
2019.4
2020.3
2020.3.11f1
2021.2
2022.1
2022.2
Issue ID
1379447
Regression
No
UGUI updates batches when every Camera.Render call is made
How to reproduce:
1. Open the user's attached project
2. Open scene Scene2
3. Go to Window -> Analysis -> Profiler
4. Enable recording profiling information while in Play mode
5. Press the Play button, then Pause
6. Go to the Profiler
7. In the Profiler Hierarchy, search for UGUI.Rendering.UpdateBatches, and observe the number of calls
Expected result: UGUI.Rendering.UpdateBatches is called once
Actual result: UGUI.Rendering.UpdateBatches is called 1+8 times
Reproducible with: 2019.4.34f1, 2020.3.26f1, 2021.2.8f1, 2022.1.0b4, 2022.2.0a2
-
AsherBurdickMohawk
Dec 15, 2022 17:43
This is highly undesirable when using Camera.Render() to do offscreen work for various rendering techniques that don't render UI. Perhaps this is better explained as a feature request: allow UI events to be optionally disabled when calling Camera.Render()
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
- Articulation Body with 'Revolute' Joint Type has erratic behavior when Upper Limit is set to above 360
- WebGL Player fails to render Scene when Terrain with Detail Mesh is added and WebGPU Graphics API is used
- Inconsistent errors are logged when different types are passed into the Query "Q<>" method in UIToolkit and the ancestor VisualElement is null
- Crash on GetMaterialPropertyByIndex when opening a specific Scene
- Discrepancies in the styling are present when using a TSS file instead of a USS file in custom EditorWindow
Resolution Note:
Calling Camera.Render forces the UI to update outside of its normal loop. It check to ensure things are updated not that its necessarily rebuilding that just the name of the function. It can early out.
As for emitting to camera that again is how it works in the back end. We need to emit the geometry to the camera as after each render the render queues are cleared.