Samsung / rlottie

A platform independent standalone library that plays Lottie Animation.
Other
1.15k stars 223 forks source link

Performance issue when lottie has png #452

Open sonphan12 opened 3 years ago

sonphan12 commented 3 years ago

blend_image_xform executing time is too long.

Lottie resource: performance.zip

Test device: Huawei GR5 mini

Benchmarked on this lottie resource, it took about ~70ms each time for blend_image_xform to be done. Airbnb's lottie-android is a lot faster.

smohantty commented 3 years ago

@sonphan12 , yes the image implementation is not optimal. it was using Qt version before but was removed because of license issue. So i just added a simple version for feature completeness. I need to find out if there is some optimal implementation which is MIT license then we can make use of that. If you have some idea you can contribute as well :)

sonphan12 commented 3 years ago

@smohantty Thanks for your response.

Can you please tell me why do you need to use Qt before? I can't figure out why, what is it for?

As a library user with very little experiences in C++, I have no idea how to improve this :( But thank to your response, I'm gonna revert to the old pieces of code that use Qt to improve my app's performance of png lottie.

I'm gonna leave this issue open for now since it's still a known-but-not-solved-yet problem.

sonphan12 commented 3 years ago

@smohantty I tried to revert to before commit removing Qt's code. It is still too slow.