`
yhz61010
  • 浏览: 552314 次
  • 来自: -
博客专栏
63c13ecc-ef01-31cf-984e-de461c7dfde8
libgdx 游戏开发
浏览量:11999
社区版块
存档分类
最新评论

How to play gif with Fresco

阅读更多
原文地址:https://stackoverflow.com/a/34892610

Put your gif in res/raw folder.
In this example res/raw/splash.gif
ImageRequest imageRequest = ImageRequestBuilder.newBuilderWithResourceId(R.raw.splash).build();
SimpleDraweeView draweeView = new SimpleDraweeView(this);
DraweeController controller = Fresco.newDraweeControllerBuilder()
    .setUri(imageRequest.getSourceUri())
    .setAutoPlayAnimations(true)
    .build();
draweeView.setController(controller);
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics