Search Issue Tracker
Third Party Issue
Votes
0
Found in
6000.0.47f1
6000.1.12f1
6000.2.0b10
6000.3.0a3
Issue ID
UUM-112741
Regression
No
Crash on IMGUI::GUIWindow::OnGUI when rendering scene view window in play mode in a specific project
Reproduction steps:
1. Open the attached project "CrashRepro"
2. Focus scene view window
3. Click on “Main“ and “MainCamera“ in the Hierarchy window
4. Enter Play mode
5. Focus scene view window
Expected result: Scene view window is focused
Actual result: Editor crashes
Reproducible with: 6000.0.47f1, 6000.1.12f1, 6000.2.0b10, 6000.3.0a3
Reproducible on: Windows 11
Not reproducible on: No other environment tested
First few lines of stack trace:
{noformat}0x00007FFC4B04743C (Unity) IMGUI::GUIWindow::OnGUI
0x00007FFC4B045D61 (Unity) IMGUI::EndWindows
0x00007FFC49EB88CB (Unity) GUI_CUSTOM_Internal_EndWindows
0x0000020FA89EFD17 (Mono JIT Code) (wrapper managed-to-native) UnityEngine.GUI:Internal_EndWindows ()
0x0000020FA89EFC4B (Mono JIT Code) UnityEngine.GUI:EndWindows ({noformat}
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
- Out-of-bounds memory access with multiple CanvasRenderers under a Canvas when using Mesh API
- Inspector tries to access file after it was deleted when the file was locked in Inspector window
- Changing Transform values in Search window Inspector loses focus while dragging and stopping mouse without releasing dragging action
- Saving changes on the dirty VFX Graph during the Play mode throws "The referenced script (Unknown) on this Behaviour is missing!" warnings
- VFX Graph Debug Info overlaps the "Initialize" block debug info by default
Resolution Note:
Issue seems to be stemming from a third party asset's (tk2d) compatibility issues with U6. The crash originates from the tk2dCameraEditor.cs file, specifically PreviewWindowFunc's previewCamera.Render() call.
The current recommended practice would be to get a temporary render texture using RenderTexture.GetTemporary, set it as the target of the preview camera, render the preview camera and finally use Graphics.DrawTexture to output the render texture to the preview window. We've tested this approach within PreviewWindowFunc and it does not crash the editor.
For an example on how to do camera previews in Scene View, please take a look at: https://github.com/Unity-Technologies/UnityCsReference/blob/master/Modules/SceneView/CameraOverlay.cs