パッケージ、リポジトリ、アプリカテゴリを検索

flutter_gif のカバー
パッケージ詳細v0.0.4

flutter_gif

GIF画像ウィジェットは、GIFの進行状況、スピード、繰り返しフレームを制御するのに役立ちます。

30日間ダウンロード
669
いいね数
56
Pub ポイント
70

パッケージをインストール

flutter pub add flutter_gif

パッケージ概要

公開情報に基づく選定ガイドです。参考としてご利用ください。

flutter_gif パッケージは、Flutter アプリケーションで GIF アニメーションを表示および制御するためのウィジェットを提供します。プログレス、スピード、フレームの繰り返しといった GIF 再生に対する細かい制御が可能です。動的でインタラクティブなアニメーションコンテンツが必要なアプリに最適であり、スムーズなレンダリングと効率的なメモリ使用をサポートしています。このパッケージは軽量で簡単に統合できるように設計されており、シンプルな用途から複雑なアニメーション要件まで対応できます。

用途

  • アニメーションバナーの表示
  • インタラクティブな読み込みインジケーターの作成
  • 動的なビジュアルでユーザーインターフェースを強化する
  • カスタム GIFプレイヤーの実装
  • アプリの要素に遊び心のあるアニメーションを追加する

主な機能

  • GIF再生速度の制御
  • 調整可能なアニメーション進行状況
  • フレームの繰り返し設定
  • 軽量で効率的なレンダリング
  • 既存のFlutterプロジェクトとの簡単な統合

適している対象

  • メディア豊富なアプリを構築する開発者
  • アニメーション要素が必要なUIデザイナー
  • カスタマイズ可能なGIFを必要とするアプリ
  • パフォーマンスとスムーズなアニメーションに焦点を当てたプロジェクト

注意事項

  • GIF形式のみに制限
  • 他のアニメーション形式のサポートなし
  • 大きな GIF に対して最適化が必要になる可能性があります
  • プラットフォーム固有の動作は異なる場合があります

元の README

関連するソースリポジトリの README 原文のスナップショットです。最新の内容はリポジトリをご覧ください。

flutter_gif

We should know that in order to achieve Gif in flutter, we can use Image, but we have no way to manipulate Gif, for example: change its speed, control it has been playing in a frame, in which frame range loop. These problems can be solved by this widget,it also help you contain gif cache,avoid load frame every time.

Screenshots

Usage(Simple)

add in pubspec


     flutter_gif: any // or the latest version on Pub

simple usage

    FlutterGifController controller= FlutterGifController(vsync: this);


    GifImage(
         controller: controller,
         image: AssetImage("images/animate.gif"),
    )

list the most common operate in FlutterGifController:

// loop from 0 frame to 29 frame
controller.repeat(min:0, max:29, period:const Duration(millseconds:300));

// jumpTo thrid frame(index from 0)
controller.value = 0;

// from current frame to 26 frame
controller.animateTo(26);

If you need to preCache gif,try this

// put imageProvider
fetchGif(AssetImage("images/animate.gif"));

Support the package (optional)

If you find this package useful, you can support it for free by giving it a thumbs up at the top of this page. Here's another option to support the package:

Thanks

License

MIT License

Copyright (c) 2019 Jpeng

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

カテゴリー

ソースリポジトリ

このパッケージを使用しているプロジェクト

データはまだありません。