搜尋套件、儲存庫與 APP 分類

scanning_effect 封面
套件詳情v1.0.11

scanning_effect

使用 CustomPainter 實現可自訂邊框的環繞相機檢視掃描效果。

AndroidiOSWebmacOSWindowsLinux
近 30 天下載
440
喜歡數
42
Pub 分數
140

安裝套件

flutter pub add scanning_effect

套件介紹

根據套件公開資料產生的選型評估,僅供參考。

scanning_effect 套件提供可自訂的掃描動畫,適用於相機檢視,特別適合 QR 碼與文件掃描應用。使用 CustomPainter,它會包覆相機畫面並加上動畫邊框,模擬掃描效果。開發者可調整邊框顏色、粗細與動畫速度,以符合應用程式設計。此套件支援多個平台,包括 Android、iOS、Web、macOS、Windows 與 Linux,讓跨平台開發更具彈性。它透過在掃描過程中提供視覺反饋,提升使用者體驗。

適用情境

  • 二維碼掃描介面
  • 文件掃描儀使用者介面
  • 移動庫存追蹤應用
  • 條碼讀取工具
  • 互動式相機疊加
  • 數位收據捕獲

主要特色

  • 可自訂邊框樣式
  • 動畫掃描效果
  • 跨平台相容性
  • 相機視圖整合
  • 可設定的動畫速度
  • 可擴展的,帶有 CustomPainter

適合對象

  • 開發掃描應用的開發者
  • 尋求動態攝影機效果的UI設計師
  • 跨平台移動應用
  • 需要即時掃描回饋的應用程式
  • 使用基於攝像頭輸入的專案

使用建議

  • 需要相機訪問權限
  • 可能影響低階裝置的效能
  • 自定義需要了解 CustomPainter
  • 僅限視覺效果,不包含掃描邏輯
  • 不適用於非相機使用情境

原始 README

以下為關聯原始碼儲存庫的 README 原文快照,最新內容請造訪原始碼儲存庫。

Scanning Effect

License: MIT

Scanning Effect to wrap around the camera

Demo Image Alt Text

Demo Code

Wrap the ScanningEffect widget around your widget

@override
Widget build(BuildContext context) {
  return ScanningEffect(
    scanningColor: Colors.red,
    borderLineColor: Colors.green,
    delay: Duration(seconds: 1),
    duration: Duration(seconds: 2),
    child: Container(
      child: SizedBox(),
    ),
  );
}

You can set the custom config base on these param:

  • scanningColor: The color of the scanning animation
  • borderLineColor: The color of the border line
  • scanningHeightOffset: The percent of scanning animation with the view height
  • delay: The delay between each animation
  • duration: The length of time this animation should last.
  • scanningLinePadding: The padding of the scanning animation

所屬分類

原始碼儲存庫

使用此套件的專案

暫無相關資料。