资源简介
虹软离线识别Android 源码,下载即可运行,包含aar包,不需要越墙下载,可运行
代码片段和文件信息
package com.arcsoft.sdk_demo;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Matrix;
import android.media.ExifInterface;
import android.net.Uri;
import android.util.Log;
/**
* Created by gqj3375 on 2017/4/28.
*/
public class Application extends android.app.Application {
private final String TAG = this.getClass().toString();
FaceDB mFaceDB;
Uri mImage;
@Override
public void onCreate() {
super.onCreate();
mFaceDB = new FaceDB(this.getExternalCacheDir().getPath());
mImage = null;
}
public void setCaptureImage(Uri uri) {
mImage = uri;
}
public Uri getCaptureImage() {
return mImage;
}
/**
* @param path
* @return
*/
public static Bitmap decodeImage(String path) {
Bitmap res;
try {
ExifInterface exif = new ExifInterface(path);
int orientation = exif.getAttributeInt(ExifInterface.TAG_ORIENTATION ExifInterface.ORIENTATION_NORMAL);
BitmapFactory.Options op = new BitmapFactory.Options();
op.inSampleSize = 1;
op.inJustDecodeBounds = false;
//op.inMutable = true;
res = BitmapFactory.decodeFile(path op);
//rotate and scale.
Matrix matrix = new Matrix();
if (orientation == ExifInterface.ORIENTATION_ROTATE_90) {
matrix.postRotate(90);
} else if (orientation == ExifInterface.ORIENTATION_ROTATE_180) {
matrix.postRotate(180);
} else if (orientation == ExifInterface.ORIENTATION_ROTATE_270) {
matrix.postRotate(270);
}
Bitmap temp = Bitmap.createBitmap(res 0 0 res.getWidth() res.getHeight() matrix true);
Log.d(“com.arcsoft“ “check target Image:“ + temp.getWidth() + “X“ + temp.getHeight());
if (!temp.equals(res)) {
res.recycle();
}
return temp;
} catch (Exception e) {
e.printStackTrace();
}
return null;
}
}
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
.CA.... 87 2018-05-10 02:05 .gitignore
.CA.... 102 2018-05-10 02:05 .gitmodules
.CA.... 895 2018-08-21 01:07 ArcFaceDemo-master.iml
.CA.... 610 2018-08-15 10:15 build.gradle
.CA.... 730 2018-05-10 02:05 gradle.properties
.CA.... 4971 2018-05-10 02:05 gradlew
.CA.... 2314 2018-05-10 02:05 gradlew.bat
.CA.... 439 2018-08-15 10:03 local.properties
.CA.... 30 2018-05-10 02:05 settings.gradle
.CA.... 1 2018-08-25 21:18 .gradle\4.4\fileChanges\last-build.bin
.CA.... 17 2018-08-25 21:18 .gradle\4.4\fileContent\fileContent.lock
.CA.... 70065 2018-08-25 21:18 .gradle\4.4\fileHashes\fileHashes.bin
.CA.... 17 2018-08-25 21:18 .gradle\4.4\fileHashes\fileHashes.lock
.CA.... 18973 2018-08-15 16:56 .gradle\4.4\fileHashes\resourceHashesCache.bin
.CA.... 87981 2018-08-25 12:06 .gradle\4.4\javaCompile\classAnalysis.bin
.CA.... 45076 2018-08-15 16:56 .gradle\4.4\javaCompile\jarAnalysis.bin
.CA.... 17 2018-08-25 13:44 .gradle\4.4\javaCompile\javaCompile.lock
.CA.... 59029 2018-08-25 13:44 .gradle\4.4\javaCompile\taskHistory.bin
.CA.... 19839 2018-08-25 13:44 .gradle\4.4\javaCompile\taskJars.bin
.CA.... 289984 2018-08-25 21:18 .gradle\4.4\taskHistory\taskHistory.bin
.CA.... 17 2018-08-25 21:18 .gradle\4.4\taskHistory\taskHistory.lock
.CA.... 17 2018-08-25 21:18 .gradle\buildOutputCleanup\buildOutputCleanup.lock
.CA.... 51 2018-08-15 11:56 .gradle\buildOutputCleanup\cache.properties
.CA.... 21395 2018-08-25 21:18 .gradle\buildOutputCleanup\outputFiles.bin
.CA.... 553 2018-08-15 17:38 .idea\caches\build_file_checksums.ser
.CA.... 1803 2018-08-15 10:03 .idea\codest
.CA.... 641 2018-08-15 17:37 .idea\gradle.xm
.CA.... 591 2018-08-15 17:39 .idea\libraries\Gradle____local_aars___C__Users_ElanHP__gradle_caches_transforms_1_files_1_1_android_extend_1_0_5_aar_95615590506cb4192371e196f7747ef4_unspecified_jar.xm
.CA.... 350 2018-08-15 17:39 .idea\libraries\Gradle____local_aars___F__workspace_github_ArcFaceDemo_master_ArcFaceDemo_master_libs_ageestimation_jar_unspecified_jar.xm
.CA.... 350 2018-08-15 17:39 .idea\libraries\Gradle____local_aars___F__workspace_github_ArcFaceDemo_master_ArcFaceDemo_master_libs_facedetection_jar_unspecified_jar.xm
............此处省略85个文件信息
相关资源
- 人脸识别考勤系统
- android-extend-1.0.5.aar依赖库com.guo.andro
- Docker离线安装手册
- 腾讯身份证验证人脸识别代码java
- 腾讯人脸识别demo
- Android+OpenCV+人脸识别源码(完整)2
- 基于java的人脸识别系统+源码---百度
- 科大讯飞SDK语言人脸识别Demo,Androi
- opencv_3.4.1_android_sdk+android studio+人脸检
- android人脸识别——HowOld测测你的年龄
- 基于javaweb人脸识别
- face++ 人脸识别javaweb完整工程(有fa
- 离线语音评测语音评价及语音识别中
- Eclipse+Java+OpenCV246人脸识别
- 人脸识别检测opencv简单java实现
- javaCV+openCV+FFmpeg实现视频帧转为图像并
- Android 人脸识别源码
- elasticsearch java api 离线文档
- javacv配置+javacv人脸识别代码
- java实现人脸识别
- java人脸识别培训视频完整版,用于就
- 人脸识别张张嘴眨眨眼jar、css、js
- Java调用百度人脸识别
- 通过JNA调用虹软年龄和性别估计SDK的
- JavaEE实现人脸识别登录54325
- javaEE实现人脸识别登录
- Android中的人脸识别代码
- Android人脸识别之显示性别与年龄Fac
- 在线人脸识别完整版源码
- 离线OJ判题系统
评论
共有 条评论