• RuntimesGodot
  • [4.4.1 GDExtension] How to enable auto batching?

Hi, we are moving to spine from spritesheet based animation, but it seems the auto batching is not working, while it was working with spritesheets.

There is a 'batch-test.tscn' in the demo project but I don't think batching is working in that scene neither as it got over 1700 draw calls with the spineboys just stand still. Is there anything special needs to be done in order to enable batching?

Related Discussions
...

In the context of using Spine with Godot, auto batching may not work as expected due to the way Spine animations are rendered. Spine animations are typically more complex than simple spritesheets, involving multiple textures and dynamic changes, which can interfere with Godot's automatic batching system.

To improve performance, you can try the following:

  1. Texture Atlases: Ensure that your Spine animations are using texture atlases efficiently. This means packing as many images as possible into a single atlas to reduce texture swaps.

  2. Optimize Draw Calls: Minimize the number of draw calls by reducing the number of separate materials and textures used in your animations.

  3. Use Binary Exports: Prefer using binary skeleton exports (.skel) over JSON exports, as they are smaller and faster to load.

  4. Check Godot Settings: Ensure that your Godot project settings are optimized for performance, such as enabling batching in the project settings if applicable.

  5. Manual Optimization: Consider manually optimizing your scenes and animations to reduce the number of draw calls, such as by combining static elements or simplifying animations.

Unfortunately, due to the complexity of Spine animations, achieving the same level of batching as with simple spritesheets may not always be possible.

Never mind, I found the answer from another post here.

Oh that's a much more clear answer than the source I found, thanks a lot🙂