概要
アニメーションGIFに対応したAndroidのImageView
デザイン・メディア計測したスター増加
- 24時間
- 0
- 7日間
- 0
- 15日間
- -1
- 1か月
- -1
期間ごとの純増数です。期間は重複しており、日別の値ではありません。未計測の値は空欄です。スター数は注目度の指標であり、品質の保証ではありません。
README.md
オリジナルGifImageView
Android ImageView that handles Animated GIF images
Usage
In your build.gradle file:
dependencies {
implementation 'com.felipecsl:gifimageview:2.2.0'
}
In your Activity class:
@Override protected void onCreate(final Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
gifView = findViewById(R.id.gifImageView);
gifView.setBytes(bitmapData);
}
@Override protected void onStart() {
super.onStart();
gifView.startAnimation();
}
@Override protected void onStop() {
super.onStop();
gifView.stopAnimation();
}
If you need to post-process the GIF frames, you can do that via GifImageView.setOnFrameAvailable().
You can see an example of that in the sample app included on the repository.
gifImageView.setOnFrameAvailable(new GifImageView.OnFrameAvailable() {
@Override public Bitmap onFrameAvailable(Bitmap bitmap) {
return blurFilter.blur(bitmap);
}
});
You can also reset an animation to play again from the beginning gifImageView.resetAnimation(); or show a specific frame of the animation gifImageView.gotoFrame(3);
Demo

Be sure to also check the demo project for a sample of usage!
Snapshots of the development version are available in Sonatype's snapshots repository.
Contributing
- Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet
- Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it
- Fork the project
- Start a feature/bugfix branch
- Commit and push until you are happy with your contribution
- Make sure to add tests for it. This is important so I don't break it in a future version unintentionally.
Copyright and license
Code and documentation copyright 2011- Felipe Lima. Code released under the MIT license.
関連プロジェクトを探す
読み込み中…