Mesh count, skinned vertices and attached to bones... whats the performance cost?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Santiago
:warning: Old Version Published before Godot 3 was released.

Hi people!

I’m on a project at the part of design, but in order to advance with a better character design I would like to know a little more about the performance costs of different character setups… so here we go:

First and foremost, I’m designing a mobile game, that’s why I’m really concerned about mesh and vertex count (it wouldn’t be that important on desktop), and I’m planning on using the same material for all characters with the exception of the main character.

Now, since I know skinned meshes are more expensive performance-wise, I plan to make the enemy characters of several non deformable “pieces” of mesh, (eg. the head would be separated from the body and both will have a single bone each for the animation).

My question is, performance-wise, would it be better to have the characters be made of separated nodes attached to their respective bone, increasing the number of nodes (or separated meshes) but getting rid of any skinning process, or have a single mesh with all the parts and skinned (with no pair of bones sharing the same vertex)?

…I’m assuming that skinned meshes have an extra cost over non-skinned meshes.

So what do you say? would I have a better performance splitting the characters and attaching the parts to the bones?

Thanks in advance!

[EDIT]
For anyone interested, I’ve made a simple performance test.
Here is the post on Godot Developers Forum: https://godotdevelopers.org/forum/discussion/18557/simple-performance-test-skinned-meshes-vs-attached-meshes?new=1

Would it be too much work for you to implement both on some small test model and benchmark the two approaches? I don’t feel like this question has come up before. It’s only been a few minutes since you posted this though, so maybe someone else has something more useful to say.

raymoo | 2017-07-08 22:50

I was thinking to do it, the thing is, I was kind of busy doing other things on my game, and I wanted to know if someone already knew about this, with more background knowledge and stuff… hehe.
But of course if I make a test I’ll let you know. :smiley:

Santiago | 2017-07-09 12:58