Animation reuse for improved performance
Step 0.
A well-made game shows a lot of characters without losing the quality of the rendering.In general, fewer bone counts and proper LOD usage will help optimize character rendering performance. A closer look reveals that the animation is being reused. Undoubtedly it will be very helpful. This time, we will do a basic test for 'animation reuse' with Unreal engine 4.
Step 1.
'Set Master Pose Component' is the blueprint we were looking for. I've used it before in another article.https://gameenginebread.blogspot.com/2017/09/render-skeletal-mesh-with-different.html
Step 2.
Create many characters for testing. I used 21 * 21 characters.Step 3.
This is the result of reusing the animation. Type console command 'stat anim' to see detail.'AnimGameThreadTime' : 2.91ms
CPU i7 6700k and Geforce 1060 are installed in the test PC.
Step 4.
Remove link to 'Set Master Pose Component' node and test again.Conclusion and Remaining Issue.
There is definitely an improvement. This is not a final system for release and there is a difference in each system, we will not perform numerical comparison.Sadly, I will not implement the example here for actual use. Because actual usage is highly dependent on the game system or genre.
Consider the following items to further.
- Reuse of 'Idle' animation is common. 'Walking animation' also consider re-use as much as possible.
- Adjust the frequency of reuse according to the distance from the camera.
- Consider the nature of the herd (e.g. zombies)
Comments
Post a Comment