https://kotlinlang.org logo
#compose
Title
# compose
i

Icaro Temponi

10/11/2019, 6:38 PM
How can I create a Compose Image from a Bitmap? found this function
fun imageFromResource(res: Resources, resId: Int): Image
to create one from a resource and noticed that it uses an
AndroidImage
class that does exactly what I need, but it's internal. Is there a way to do this right now? Or should we copy paste the class or create our implementation of Image what uses a Bitmap?
a

Adam Powell

10/11/2019, 9:30 PM
There should be another effect-returning function you can use with the leading
+
like
+state
and friends
That doesn't require passing a
Resources
k

kioba

10/12/2019, 9:06 AM
I am having the same issues 😅 thanks Adam!
6 Views