fix: add flush() to skybox/IBL destroy methods to ensure that textre upload callbacks are completed to avoid stalling
This commit is contained in:
@@ -394,6 +394,7 @@ class ThermionViewerFFI extends ThermionViewer {
|
||||
}
|
||||
|
||||
if (_skyboxTextureUploadComplete != null) {
|
||||
await FilamentApp.instance!.flush();
|
||||
await _skyboxTextureUploadComplete;
|
||||
_skyboxTextureUploadComplete = null;
|
||||
}
|
||||
@@ -414,6 +415,7 @@ class ThermionViewerFFI extends ThermionViewer {
|
||||
await ibl.destroy();
|
||||
}
|
||||
if (_iblTextureUploadComplete != null) {
|
||||
await FilamentApp.instance!.flush();
|
||||
await _iblTextureUploadComplete!;
|
||||
_iblTextureUploadComplete = null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user