Search Issue Tracker
Fixed in 8.1.0
Votes
0
Found in [Package]
8.0.0
Issue ID
1211754
Regression
No
[URP] Some tests fail due to Destroy being called at the wrong time
In IL2CPP, effects that rely on TextureCurve.Finalize in Universal Render Pipeline throw errors due to Destroy being called at the wrong time.
Reproduction Steps:
1. Clone the SRP repo: https://github.com/Unity-Technologies/ScriptableRenderPipeline
2. Open the project in TestProjects/UniversalGraphicsTest
3. Open Build Settings and disable all scenes except for 081_GradingColorCurvesLDR and 083_GradingLiftGammaGainLDR (these are the minimum required, but all scenes between 076-093 can trigger this failure)
4. Open Player Settings and change Scripting Backend to IL2CPP
5. Go to Window > General > Test Runner
6. Press "Play Mode" and then "Run all in player"
7. Wait for the build to complete, run on target, and then fail with the following error:
UnityException: Destroy can only be called from the main thread.
Constructors and field initializers will be executed from the loading thread when loading a scene.
Don't use this function in the constructor or field initializers, instead move initialization code to the Awake or Start function.
at UnityEngine.Rendering.TextureCurve.Finalize () [0x00000] in <00000000000000000000000000000000>:0
System.UnhandledExceptionEventHandler:Invoke(Object, UnhandledExceptionEventArgs)
Reproducible in versions 2020.1.0a18, 2020.1.0a22.
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Crash on memcpy_repmovs when selecting NavMesh Agent objects while in Play Mode in a specific scene
- Console shows Exception: {"error":"not found","detail":["not found"]} after opening Build History window
- [HDRP] Volumetric cloud shadows disappear when there is no directional light shadows
- “Selector” column names in the Search window are lowercase when added
- Install List Project Counter Panel can be right clicked through and Install Context Menu can be opened disabling Project Counter Panel's buttons
Add comment