Skip to content

Commit 65a10b3

Browse files
committed
Merge branch 'development'
2 parents 9c154c8 + d13a75f commit 65a10b3

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+3234
-0
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Ver-ID Registry App
2+
3+
<img src="./app/src/main/res/drawable-mdpi/selfie.png" align="right" alt="Phone with face" />
4+
5+
Android app that shows how to use Ver-ID libraries to build a biometric sign-in system.
6+
7+
The app captures a face and registers it under a user's name. Once registered, the user can sign in to the app using their face.

app/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/build

app/build.gradle.kts

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
2+
3+
plugins {
4+
alias(libs.plugins.android.application)
5+
alias(libs.plugins.kotlin.android)
6+
alias(libs.plugins.kotlin.compose)
7+
alias(libs.plugins.room)
8+
}
9+
10+
android {
11+
namespace = "com.appliedrec.veridregistry"
12+
compileSdk = 36
13+
14+
defaultConfig {
15+
applicationId = "com.appliedrec.veridregistry"
16+
minSdk = 26
17+
targetSdk = 36
18+
versionCode = 1
19+
versionName = "1.0"
20+
21+
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
22+
}
23+
24+
buildTypes {
25+
release {
26+
isMinifyEnabled = false
27+
proguardFiles(
28+
getDefaultProguardFile("proguard-android-optimize.txt"),
29+
"proguard-rules.pro"
30+
)
31+
}
32+
}
33+
compileOptions {
34+
sourceCompatibility = JavaVersion.VERSION_11
35+
targetCompatibility = JavaVersion.VERSION_11
36+
}
37+
kotlin {
38+
compilerOptions {
39+
jvmTarget.set(JvmTarget.JVM_11)
40+
}
41+
}
42+
buildFeatures {
43+
compose = true
44+
}
45+
}
46+
47+
dependencies {
48+
49+
implementation(libs.androidx.core.ktx)
50+
implementation(libs.androidx.lifecycle.runtime.ktx)
51+
implementation(libs.androidx.activity.compose)
52+
implementation(platform(libs.androidx.compose.bom))
53+
implementation(libs.androidx.ui)
54+
implementation(libs.androidx.ui.graphics)
55+
implementation(libs.androidx.ui.tooling.preview)
56+
implementation(libs.androidx.material3)
57+
implementation(libs.androidx.datastore.preferences)
58+
implementation(libs.material.icons.extended)
59+
implementation(libs.verid.face.capture)
60+
implementation(libs.verid.face.detection.retinaface)
61+
implementation(libs.verid.face.recognition.arcface.cloud)
62+
implementation(libs.verid.face.template.registry)
63+
implementation(libs.verid.serialization)
64+
implementation(libs.spoof.device.detection.cloud)
65+
implementation(libs.room.runtime)
66+
implementation(libs.room.ktx)
67+
implementation(libs.androidx.navigation.compose)
68+
implementation(libs.androidx.foundation.layout)
69+
ksp(libs.room.compiler)
70+
testImplementation(libs.junit)
71+
androidTestImplementation(libs.androidx.junit)
72+
androidTestImplementation(libs.androidx.espresso.core)
73+
androidTestImplementation(platform(libs.androidx.compose.bom))
74+
androidTestImplementation(libs.androidx.ui.test.junit4)
75+
debugImplementation(libs.androidx.ui.tooling)
76+
debugImplementation(libs.androidx.ui.test.manifest)
77+
}

app/proguard-rules.pro

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Add project specific ProGuard rules here.
2+
# You can control the set of applied configuration files using the
3+
# proguardFiles setting in build.gradle.
4+
#
5+
# For more details, see
6+
# http://developer.android.com/guide/developing/tools/proguard.html
7+
8+
# If your project uses WebView with JS, uncomment the following
9+
# and specify the fully qualified class name to the JavaScript interface
10+
# class:
11+
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12+
# public *;
13+
#}
14+
15+
# Uncomment this to preserve the line number information for
16+
# debugging stack traces.
17+
#-keepattributes SourceFile,LineNumberTable
18+
19+
# If you keep the line number information, uncomment this to
20+
# hide the original source file name.
21+
#-renamesourcefileattribute SourceFile

app/src/main/AndroidManifest.xml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
3+
xmlns:tools="http://schemas.android.com/tools">
4+
5+
<application
6+
android:allowBackup="true"
7+
android:dataExtractionRules="@xml/data_extraction_rules"
8+
android:fullBackupContent="@xml/backup_rules"
9+
android:icon="@mipmap/ic_launcher"
10+
android:label="@string/app_name"
11+
android:roundIcon="@mipmap/ic_launcher_round"
12+
android:supportsRtl="true"
13+
android:theme="@style/Theme.VerIDRegistry">
14+
<activity
15+
android:name=".MainActivity"
16+
android:exported="true"
17+
android:label="@string/app_name"
18+
android:theme="@style/Theme.VerIDRegistry">
19+
<intent-filter>
20+
<action android:name="android.intent.action.MAIN" />
21+
22+
<category android:name="android.intent.category.LAUNCHER" />
23+
</intent-filter>
24+
</activity>
25+
</application>
26+
27+
</manifest>
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
package com.appliedrec.veridregistry
2+
3+
import androidx.room.Database
4+
import androidx.room.RoomDatabase
5+
import androidx.room.TypeConverters
6+
7+
@Database(entities = [TaggedFaceEntity::class], version = 1, exportSchema = false)
8+
@TypeConverters(DatabaseTypeConverters::class)
9+
abstract class AppDatabase : RoomDatabase() {
10+
abstract fun taggedFaceDao(): TaggedFaceDao
11+
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
package com.appliedrec.veridregistry
2+
3+
import android.content.Context
4+
import androidx.room.Room
5+
6+
object AppDatabaseProvider {
7+
@Volatile
8+
private var INSTANCE: AppDatabase? = null
9+
10+
fun getDatabase(context: Context): AppDatabase {
11+
return INSTANCE ?: synchronized(this) {
12+
val instance = Room.databaseBuilder(
13+
context.applicationContext,
14+
AppDatabase::class.java,
15+
"tagged_faces.db"
16+
).build()
17+
INSTANCE = instance
18+
instance
19+
}
20+
}
21+
}
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
package com.appliedrec.veridregistry
2+
3+
import androidx.compose.runtime.getValue
4+
import androidx.compose.runtime.mutableStateOf
5+
import androidx.compose.runtime.setValue
6+
import androidx.lifecycle.ViewModel
7+
import com.appliedrec.verid3.facecapture.CapturedFace
8+
9+
class CapturedFaceViewModel : ViewModel() {
10+
var capturedFace by mutableStateOf<CapturedFace?>(null)
11+
}

0 commit comments

Comments
 (0)