Hi, how are you?
frame animation about 100 pages using the image animation that wants to have a go. The size of about 750 1334.
Is there any other way to get out of memory?
android
An image of that size requires approximately 750 * 1334 * 4 = 4MB
of memory (assuming ARGB_8888). Frame animation is a method of loading all images into memory, so 100 sheets require about 400 MB of memory, which seems to cause out of memory because it cannot be allocated.
Since there are many images currently used for animation, I think it would be better to use an implementation other than the frame animation provided by Android.
The above library sequentially uploads and releases images to memory. Please refer to the link above to modify the code.
© 2024 OneMinuteCode. All rights reserved.