Search Issue Tracker
Fixed in 2018.3.X
Fixed in 2019.1.X
Votes
8
Found in
2018.2.0b10
Issue ID
1053476
Regression
No
Crash on ScreenCapture.CaptureScreenshotAsTexture when it is called before the Frame has ended
How to reproduce:
1. Open the attached project
2. Set Game window resolution to "Standalone (1024x768)"
3. Enter Play mode
4. Click the 'Crash' button
Expected result: Editor does not crash, there is a warning that ScreenCapture.CaptureScreenshotAsTexture should only be called once the frame has ended.
Actual result: Editor crashes.
Reproducible with - 2017.3.0b1, 2017.4.6f1, 2018.1.7f1, 2018.2.0b11, 2018.3.0a3
Notes:
- Could not be tested on 2017.1 and 2017.2, since the above-mentioned method was introduced on 2017.3.
- The issue was not reproducible with OpenGL, or when rendering using integrated Intel graphics card.
Stack trace:
(Unity) ScreenCapture::CaptureScreenshotAsTexture
(Unity) ScreenCapture_CUSTOM_CaptureScreenshotAsTexture
(Mono JIT Code) (wrapper managed-to-native) UnityEngine.ScreenCapture:CaptureScreenshotAsTexture (int)
(Mono JIT Code) [C:\Users\UnityQA\Desktop\1053476_\Assets\SomeImgui.cs:9] SomeImgui:OnGUI ()
(Mono JIT Code) (wrapper runtime-invoke) object:runtime_invoke_void__this__ (object,intptr,intptr,intptr)
(mono) [c:\buildslave\mono\build\mono\mini\mini.c:4937] mono_jit_runtime_invoke
(mono) [c:\buildslave\mono\build\mono\metadata\object.c:2623] mono_runtime_invoke
(Unity) scripting_method_invoke
(Unity) ScriptingInvocation::Invoke
(Unity) MonoBehaviourDoGUI
(Unity) IMGUIModule::MonoBehaviourDoGUI
<...>
Comments (3)
-
Hecolo
Mar 31, 2019 18:23
Hi guys,
I tried with:
Unity 2018.3.11f1
Unity 2019.1.0b9
Unity 2019.2.0a9Still buging for
ScreenCapture.CaptureScreenshotAsTexture();
-
Menion-Leah
Feb 07, 2019 11:12
reproducible on 2018.3.2f1
-
misterHallodri
Sep 28, 2018 17:43
reproducible on 2018.2.3f1
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
- Uninitialized variable warning appears in the Inspector of a custom shader when the variable is initialized
- "Failed creating toolbar element from ID..." error is thrown when resetting the Scene view Overlay layout while an Asset Transformer Toolbox overlay is active
- Entity ID for Font Assets is serialized twice which throws an error when using Debug Inspector
- Play Mode can be entered when disabling Adaptive Performance and pressing either the Play Mode button or the keyboard shortcut to enter Play Mode before recompilation leading to errors and warnings thrown
- Parent ListView element also becomes selected when inner ListView element is selected
Resolution Note (fix version 2018.3):
Fixed in 2019.2.0a5
Backported to 2018.3.12f1, 2019.1.0b9