skydoves / landscapist

🌻 A pluggable, highly optimized Jetpack Compose and Kotlin Multiplatform image loading library that fetches and displays network images with Glide, Coil, and Fresco.
https://skydoves.github.io/landscapist/
Apache License 2.0
2.18k stars 113 forks source link

Support animated-WebP for FrescoImage #44

Closed Notsfsssf closed 3 years ago

Notsfsssf commented 3 years ago

Hi, Fresco's animated-webp support is impl with SimpleDraweeView Is there any way to support dynamic pictures for FrescoImage? https://frescolib.org/docs/animations.html https://frescolib.org/docs/webp-support.html

skydoves commented 3 years ago

Hi @Notsfsssf, Thanks for your issue! Here is a new SNAPSHOT dependency for showing the webp.

implementation "com.github.skydoves:landscapist-fresco-websupport:1.3.4-SNAPSHOT"

You can use FrescoWebImage for showing a webp file.

FrescoWebImage(
      controllerBuilder = Fresco.newDraweeControllerBuilder()
        .setUri("asset:///test.webp")
        .setAutoPlayAnimations(true),
      modifier = Modifier.size(250.dp)
    )
skydoves commented 3 years ago

Released a new stable 1.3.4. Thank you for your issue!