How to save a much big scene

when a scene is much big, the serialized scene is also a much big Object. When it came to the " JSON.stringify()" , an error occurred…How can i avoid this?

Are you saving it through the editor, like your previous question? How to save the fbx file - Questions - Babylon.js (babylonjs.com) If both are on the editor, please keep the conversation on only one thread for organization purposes.

Not exactly. They are two different questions.
I wanted to save a much big scene without the fbx format.
In fact,I want to save the big scene to the MInio server through my low-code platform Not through the Babylon Editor. The point key is if the scene was so big that the V8 of js couldn’t accept, how could we save it?

You’re trying to save this scene in a .babylon format? Can you show an example of this error in the Playground? Babylon.js Playground (babylonjs.com)

1 Like

Yes, of course. save a much big scene | Babylon.js Playground (babylonjs.com).
You need to Uncomment the line 24 to 30 to test saving the scene.


As shown in the image,the error occurred by “JSON.stringify()”
If the error can not be avoided, does it mean that the BJS do not support to save a much big scene?

The problem isn’t with BJS here, it’s with Javascript itself. There seem to be some methods to stringify a huge json like this, you could check them out here: javascript - JSON.stringify throws RangeError: Invalid string length for huge objects - Stack Overflow