Sprite Skin Script low performance

When I have about 20 or 30 objects with sprite skin scripts generated from the skinning editor, I get some serious performance issues. 15fps from 100. Is this expected? Is there a way to improve performance? I was really looking forward to using this to animate all my enemies and objects, but now I might have to resort to using an external editor, and importing the images frame by frame :frowning:

2 Likes

Hi, we have improved performance of skinning in the latest version 3.0.5
More info here : https://discussions.unity.com/t/725306 page-7#post-4978613

same problem here!
the performance cut is huge!!!
and I have already upgraded to latest version 3.0.5;

On latest version of 19.3, still horrible horrible performance with just 1 sprite skin in the scene. The profiler says its eating up 60% usage!!

2 Likes

I was running into the same issues. Make sure you guys have both the Collections and Burst packages installed as well from Package Manager. The performance improvement for SpriteSkin is dependent on having these packages installed.

I find it a bit ironic as without these "optional" packages the performance of SpriteSkin makes it pretty much unusable in what I've seen at least :(. Also, if you're on a platform that doesn't yet support burst (such as WebGL, see support here: https://docs.unity3d.com/Packages/com.unity.burst@1.3/manual/index.html#standalone-player-support) then you sadly can't benefit from this performance boost either and so SpriteSkin is kinda unusable there too. I hope they improve the performance of it via the non-burst route because apart from this I really like the 2D Animation stuff.

6 Likes

@cyanryanlion 's answer helped me enormously. My FPS quadrupled after downloading both Packages.

For anyone having problems: for me, the latest version of Collections didn’t work. I had to downgrade to Collections Version 0.8.0.

2 Likes

Why can't i find Collections in Package Manager?

Oh found it! Just click advanced > show preview packages

Just wanted to say that my project saw a DRAMATIC performance improvement on Android from installing Burst+Collections. Sprite mesh deformation was previously taking 40ms per frame (!), down to just several ms. This should really be documented somewhere...

Thanks for letting us know [mention|saWRnfxLHS5o/T61tJB2Vw==]! We are happy that you enjoy the speed ups. Like I wrote in another thread , we have also published this information in YouTube videos, blog posts and on the front page of the package documentation. But it seems that we still have quite the way to go until it is well known. I’ll take this with me to the team to see how we can improve the message out to the rest of the dev community.

We are also aiming to make Burst and Collections packages dependencies of the 2D Animation package in a future release of 2D Animation. This will enable all users to get the performance boost by default.

1 Like

Does this performance boost also work on 2021.1? I can't find Collections in the Package Manager even with preview packages enabled.

Yes, it works in Unity 2021.1 but requires a few new steps. We explain these steps in this post . Have a look and let us know how it goes!

a pain to add it in Unity 2020.3.14
I had to “add by git URL” with “com.unity.collections@0.17.0-preview.18” or “com.unity.collections@1.0.0-pre.5” after looking up the packages names here

Thank you for flagging this @jwho303
Since the Collections package is a preview package, I saw that the install section in 2D Animation 5.x (Unity 2020.3) documentation is lacking the additional steps which are now required. We have these steps listed in
- 2D Animation 6.x (Unity 2021.1)
- 2D Animation 7.x (Unity 2021.2)
I'll make a note that we should backport this information to 2D Animation 5.x and 2D Animation 3.x to reduce the confusion.