-
Notifications
You must be signed in to change notification settings - Fork 10
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
Ability to use Bitmap instead of ImageBitmap #257
Comments
Which function are you using? The androidx Palette API does things differently, and is probably faster than the implementation in MCU. |
Here's my full ViewModel, as commented, creating a Palette from a bitmap is instantaneous compared to generating a seed color. I may have led to un-necessary confusion, as it may be the process of generating a seed color that is slow as opposed to converting to an ImageBitmap |
Yeah so For a better/faster approach you can use my KMP port of android.palette: [kmpalette](https://github.com/jordond/kmpalette]. But I will warn you, it's in the process of being updated as it's been awhile since I've given it some love. It currently doesn't have WASM support if you need that, but I'm working on implementing it. |
Thanks ! I'll wait for an update, my endgoal is achieved and works correctly so it's not a rush ^^ |
Hello !
So I've found out that using .asImageBitmap() to convert Bitmap to ImageBitmap kinda slow making the theme switch 3 seconds after image change compared to instant when using Google's Palette API which takes in a Bitmap.
Could it be possible to directly Bitmaps ?
Thanks in advance ^^
The text was updated successfully, but these errors were encountered: