Crash when levels containing speedtrees get streamed out
We've setup our level using the world composition system. As we move around levels get loaded and unloaded. If a level that has a speed tree in it is unloaded we get a crash on the render thread in FScene::UpdateSpeedTreeWind.
The problem seems to be that a UStaticMesh can be GC'ed before the UStaticMeshComponents that use it are GC'ed. Because the speed tree wind data is only cleaned up by the UStaticMeshComponent::OnUnregister, if the UStaticMesh is GC'ed before the component it seems possible that the render thread can wake up and try to update the speed tree wind data that is now referenced by a dead UStaticMesh pointer.
I've currently fixed this by putting an instances of each of our speed trees under the ground in our persistent level, so that the UStaticMesh object never gets GC'ed.
asked Dec 15 '14 at 03:10 AM in Bug Reports
I've tried to reproduce this but have not been able to to get a crash with this. In my test setup everything loads and unloads properly for the levels.
Here is my setup. Let me know if I'm missing something or not doing it the same and I'll adjust to your method and see if I can get the same issue.
This is the gist of my setup. Is this how you've set yours up as well?
answered Dec 15 '14 at 09:04 PM
Tim Hobson ♦♦ STAFF
Follow this question
Once you sign in you will be able to subscribe for any updates here