搜索插件、代码仓与 APP 分类

GitHub 代码仓hamzasidd3634/camera_filter

camera_filter

相机滤镜

camera_filter 项目封面
星标
10
复刻
12
最近推送(UTC)
2024年9月16日
项目状态
未归档

原始 README

以下为英文项目原文快照,最新内容请访问 GitHub。

Camera Filters

Realtime Camera Filters

Description

This package will use camera with dynamic color list of filters, crop your image, text on image , change the text color and you can also use emojis. You can use your own custom color list to change filters. In the end it will provide you an edited image in onDone listener

Features

  • Realtime Camera Filters.
  • Draw, add text change filters in camera.
  • Filters on video.
  • TextOverlay on video.

IOS

The camera_filters plugin compiles for any version of iOS, but its functionality requires iOS 10 or higher. If compiling for iOS 9, make sure to programmatically check the version of iOS running on the device before using any camera_filters plugin features.

Add two rows to the ios/Runner/Info.plist:

  • one with the key Privacy - Camera Usage Description and a usage description.
  • and one with the key Privacy - Microphone Usage Description and a usage description. If editing Info.plist as text, add:
    <key>NSCameraUsageDescription</key>
    <string>your usage description here</string>
    <key>NSMicrophoneUsageDescription</key>
    <string>your usage description here</string>

Android

  • Change the minimum Android sdk version to 24 (or higher) in your android/app/build.gradle file.
    minSdkVersion 24

Step 1. Ensure the following permission is present in your Android Manifest file, located in /android/app/src/main/AndroidManifest.xml:

    <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />

Step 2. Add the JitPack repository to your Android build file, located in /android/build.gradle:

    allprojects {
    repositories {
    maven { url 'https://jitpack.io' }
    }
}

Usage

Example

To use this package:

    dependencies:
      flutter:
        sdk: flutter
      camera_filters: <latest-version>

ScreenShots

1 2

3 4

Video

pack

!

How to use

    import 'package:camera_filters/camera_filters.dart';
    import 'package:flutter/material.dart';
    
    void main() {
      WidgetsFlutterBinding.ensureInitialized();
      runApp(MyApp());
    }
    
    class MyApp extends StatefulWidget {
      @override
      _MyAppState createState() => _MyAppState();
    }
    
    class _MyAppState extends State<MyApp> {
      @override
      Widget build(BuildContext context) {
        return MaterialApp(
          home: Scaffold(
            body: CameraScreenPlugin(onDone: (value) {
              /// value returns the picture path you can save here or navigate to some screen
              print(value);
            },


                /// time limit for video in seconds
                videoTimeLimit: 10,


                /// value returns the video path you can save here or navigate to some screen
                onVideoDone: (value) {
              print(value);
            }
    
                /// profileIconWidget: , if you want to add profile icon on camera you can your widget here
    
                ///filterColor: ValueNotifier<Color>(Colors.transparent),  your first filter color when you open camera
    
                /// filters: [],
                ///you can pass your own list of colors like this List<Color> colors = [Colors.blue, Colors.blue, Colors.blue ..... Colors.blue]
                ///make sure to pass transparent color to first index so the first index of list has no filter effect
                ),
          ),
        );
      }
    }
hamzasidd3634 GitHub avatar
GitHub 作者

hamzasidd3634 ↗

语言DartKotlinSwiftRubyObjective-CJava

此仓库发布的插件

使用的依赖

依赖清单 14 项

如何选择适合项目的代码仓?

先按使用场景筛选,再比较项目活跃情况,最后到原始仓库核对使用要求。

  1. 通过仓库名、作者或描述搜索,再按技术分类缩小范围。
  2. 结合星标、复刻与最近推送比较项目;星标反映社区关注,不代表质量保证。
  3. 使用前在 GitHub 核对 README、许可证与 Issues。

来源与维护

“A repository is the most basic element of GitHub.”

GitHub Docs — About repositories ↗