cvzi / darkmodewallpaper

🌓 A live wallpaper for Android that respects dark theme mode 🌇
https://f-droid.org/packages/com.github.cvzi.darkmodewallpaper/
GNU General Public License v3.0
171 stars 11 forks source link

[bug]: animate lock screen wallpaper to home screen wallpaper doesn't work after opening a heavy app/games #202

Open Bobbydew1 opened 1 month ago

Bobbydew1 commented 1 month ago

The animation transition to lock screen wallpaper to home screen wallpaper stop working after opening a heavy app/game

cvzi commented 1 month ago

I guess this is expected behavior. When the Android system asks the app to free up memory, then the wallpaper images are removed from memory. Loading the images again takes too much time and the animation is skipped.

Not sure what's a good solution to this. Obviously this could be solved by not removing the images from memory, but that could impact performance of heavy apps, since the images can be quite large depending on wallpaper size and screen size.

Bobbydew1 commented 1 month ago

I guess this is expected behavior. When the Android system asks the app to free up memory, then the wallpaper images are removed from memory. Loading the images again takes too much time and the animation is skipped.

Not sure what's a good solution to this. Obviously this could be solved by not removing the images from memory, but that could impact performance of heavy apps, since the images can be quite large depending on wallpaper size and screen size.

I mean smartphones nowadays have enough ram, and I'm not that worried about the performance of my phone, I'm just a casual user so yea🤷

cvzi commented 1 month ago

I guess I could add an option in the settings, that forces the lock screen image to be kept in memory

Bobbydew1 commented 1 month ago

I guess I could add an option in the settings, that forces the lock screen image to be kept in memory

Sounds like a very good idea

cvzi commented 1 month ago

I added the option.

Also I made some improvement to the memory management. The images should be kept a little bit longer in memory now, so possibly this option is not needed.