Which performs better? Manipulating rigging bones manually at runtime or an animation

Hello,

Which performs better?

  1. Manipulating rigging bones manually at runtime in LateUpdate (i.e. make character head tilt up)
CharacterHead.transform.localEulerAngles = Vector3(0,0,30);
  1. Import an animation which you have to setup, etc, etc …

I’m finding I am “enjoying” the process of manipulating bones at runtime to create some interesting animations (as opposed to creating animations and importing them). However, I don’t want to head down the path too far if it kills performance.

Thanks!

I’m not 100% sure, but animation will probably be faster since it’s being handled under the hood. If the speed difference is actually big enough to matter would just require careful benchmarking I think. Obviously it also depends on the overhead of the calculations you’re using.

Hmm… actually there’s an IK asset in the store I was reading about, it’s doing quite a bit of procedural animation with pretty minimal overhead, so I think that as long as your calculations aren’t crazy and you’re not scaling the number of animation characters into something crazy you should be fine.