Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refresh picture flicker #77

Closed
ghost opened this issue Sep 1, 2019 · 4 comments
Closed

Refresh picture flicker #77

ghost opened this issue Sep 1, 2019 · 4 comments
Labels
bug Something isn't working

Comments

@ghost
Copy link

ghost commented Sep 1, 2019

memoryCachePolicy(CachePolicy.DISABLED) after loading the same picture will cause flicker, glide has dontAnimate() can solve, the coil?

@ghost ghost added the bug Something isn't working label Sep 1, 2019
@0xMatthewGroves
Copy link

I've noticed the same flicker in ImageViews even when loading images from the cache.

@ghost
Copy link
Author

ghost commented Sep 3, 2019

即使从缓存中加载图像,我也注意到了ImageViews中的闪烁效果。

Me too! but i set crossfade(false) to temporarily solve this problem.

@colinrtwhite When setting the same picture, I hope he won't change anything.

@colinrtwhite
Copy link
Member

@isMeiying memoryCachePolicy(CachePolicy.DISABLED) will disable reading and writing to the memory cache. This will force Coil to load the image from disk, which can often take more than 16ms, which can cause the flickering.

The equivalent of Glide's dontAnimate() is crossfade(false) (and don't set memoryCachePolicy). Let me know if that solves your issue.

@ghost
Copy link
Author

ghost commented Sep 4, 2019

@isMeiying memoryCachePolicy(CachePolicy.DISABLED) will disable reading and writing to the memory cache. This will force Coil to load the image from disk, which can often take more than 16ms, which can cause the flickering.

The equivalent of Glide's dontAnimate() is crossfade(false) (and don't set memoryCachePolicy). Let me know if that solves your issue.

Thank you very much, it solved my problem!

@ghost ghost closed this as completed Sep 4, 2019
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants