|
|
@@ -1,14 +1,58 @@
|
|
|
-# fltbdface
|
|
|
+# 百度人脸采集SDK Flutter版本
|
|
|
|
|
|
Baidu's face recognition SDK encapsulates the flutter version, calls native SDK and interface operations, and returns data to flutter
|
|
|
|
|
|
-## Getting Started
|
|
|
+## 安装
|
|
|
|
|
|
-This project is a starting point for a Flutter
|
|
|
-[plug-in package](https://flutter.dev/developing-packages/),
|
|
|
-a specialized package that includes platform-specific implementation code for
|
|
|
-Android and/or iOS.
|
|
|
+```
|
|
|
+//pub方式
|
|
|
+dependencies:
|
|
|
+ flt_bd_face: ^0.0.4
|
|
|
|
|
|
-For help getting started with Flutter, view our
|
|
|
-[online documentation](https://flutter.dev/docs), which offers tutorials,
|
|
|
-samples, guidance on mobile development, and a full API reference.
|
|
|
+//导入方式
|
|
|
+dependencies:
|
|
|
+ flt_video_player:
|
|
|
+ git:
|
|
|
+ url: https://github.com/RandyWei/flt_bd_face.git
|
|
|
+```
|
|
|
+
|
|
|
+### Android
|
|
|
+android/app/build.gradle配置如下
|
|
|
+```
|
|
|
+android {
|
|
|
+
|
|
|
+ ....
|
|
|
+
|
|
|
+ //将签名配置完整
|
|
|
+ signingConfigs {
|
|
|
+ Release {
|
|
|
+ keyAlias 'keyAlias'
|
|
|
+ keyPassword 'keyPassword'
|
|
|
+ storeFile file('storeFile')
|
|
|
+ storePassword 'storePassword'
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ ....
|
|
|
+
|
|
|
+ buildTypes {
|
|
|
+ release {
|
|
|
+ signingConfig signingConfigs.Release
|
|
|
+ //开启混淆。新版Flutter默认将混淆打开了,所以要配置混淆规则,否则release版本会有问题
|
|
|
+ useProguard true
|
|
|
+ proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
|
|
+ }
|
|
|
+ debug {
|
|
|
+ signingConfig signingConfigs.Release
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+```
|
|
|
+
|
|
|
+混淆规则,也可以直接copy example中的规则文件
|
|
|
+
|
|
|
+```
|
|
|
+-keep class com.baidu.** {*;}
|
|
|
+-keep class vi.com.** {*;}
|
|
|
+-dontwarn com.baidu.**
|
|
|
+```
|