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) {
|
if (_skyboxTextureUploadComplete != null) {
|
||||||
|
await FilamentApp.instance!.flush();
|
||||||
await _skyboxTextureUploadComplete;
|
await _skyboxTextureUploadComplete;
|
||||||
_skyboxTextureUploadComplete = null;
|
_skyboxTextureUploadComplete = null;
|
||||||
}
|
}
|
||||||
@@ -414,6 +415,7 @@ class ThermionViewerFFI extends ThermionViewer {
|
|||||||
await ibl.destroy();
|
await ibl.destroy();
|
||||||
}
|
}
|
||||||
if (_iblTextureUploadComplete != null) {
|
if (_iblTextureUploadComplete != null) {
|
||||||
|
await FilamentApp.instance!.flush();
|
||||||
await _iblTextureUploadComplete!;
|
await _iblTextureUploadComplete!;
|
||||||
_iblTextureUploadComplete = null;
|
_iblTextureUploadComplete = null;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user