You can traverse through the scene, remove all objects and dispose the respective geometries, material and textures. Example code for this looks like so:
Mugen87
2
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
| When to dispose: How to completely clean up a Three.js scene | 21 | 46137 | August 23, 2024 | |
| Can't properly clear scene | 8 | 1780 | April 20, 2021 | |
| Dispose things correctly in three.js | 22 | 22874 | May 23, 2021 | |
| Performance issues ThreeJS & ReactJS | 3 | 4133 | December 8, 2020 | |
| Three.js dispose things so hard | 16 | 4526 | January 14, 2023 |