Search Issue Tracker
By Design
Votes
0
Found in
2018.4
2019.4
2020.2
2020.2.1f1
2021.1
Issue ID
1302246
Regression
No
Mesh is drawn in the Inspector preview window when drawing with Graphics or GL class
Reproduction steps:
1. Open the user's attached project and Scenes/OnRenderObjectDebug scene
2. In the Project window, select Materials/OnRenderObjectDebug material
3. In the Inspector, rotate the preview object
Expected result: Only the preview of the selected object is drawn
Actual result: Additional Mesh is drawn
Reproducible with: 2018.4.30f1, 2019.4.18f1, 2020.2.2f1, 2021.1.0b2
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
- [iOS] Touch input is not clocked and UI is unresponsive when the application is paused mid-drag without lifting the finger
- [sw-unity-6-1] Scene view renders any light differently when more than one camera exists and neither have the "MainCamera" tag
- Project tab navigates to the previous folder when undoing (CTRL+Z) GameObject placement in the Scene
- Blue lines appear on the sides of the "Fit Canvas" or "Fit viewport" button when it's clicked in the UI Builder.
- PlayableDirector's state remains set to Playing even when the timeline's time property exceeds its duration.
Resolution Note (2021.2.X):
This behaviour is by design. OnRenderObject will run for any camera, and ExecuteInEditMode makes this run for preview cameras as well. Users can test the camera type in the code and skip drawing in the preview (which uses regular camera drawing).