Search Issue Tracker
By Design
Votes
0
Found in [Package]
11.0.0
Issue ID
1226313
Regression
No
RenderTexture is silently released during project builds
How to reproduce:
1. Open the attached project named "render_texture_build_issue.zip"
2. Check if the Scene window is active and the Game window is hidden
3. Try building the project
Expected results: The project is built successfully
Actual results: "MissingReferenceException: The object of type 'RenderTexture' has been destroyed but you are still trying to access it." error is thrown
Reproducible with: 7.5.2(2019.4.16f1), 8.3.1(2020.1.17f1), 10.2.2(2020.2.1f1), 11.0.0(2021.1.0a10)
Could not test with: 2018.4(SRP was in early preview)
Notes:
1. The build is completed successfully despite the thrown errors
2. Reseting the Layout does not resolve the issue
3. If both Scene and Game windows are active, the issue does not occur
4. If both Scene and Game windows are hidden, the issue does not occur
5. Project is using a custom SRP
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:
The issue could not be reproduced with the High Definition Render Pipeline template. The problem seems to originate from the custom SRP solution used in the project which was not considering a requirement when writing a custom SRP. HDRP is using GetTemporaryRT() and this will always return a valid RenderTexture. Maybe this requirement was not clear in the Documentation while the project's custom SRP solution was developed