Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lib_base
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
sikang
lib_base
Commits
3df08c76
Commit
3df08c76
authored
Aug 14, 2019
by
sikang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add liveness motion
parent
6b8c77af
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
57 additions
and
3 deletions
+57
-3
app_build.gradle
+12
-1
script/code/choose_liveness.sh
+17
-0
src/main/java/com/common/bean/DisplayBean.java
+19
-0
src/main/java/tech/starwin/mvp/presenter/UploadPresenter.java
+9
-2
No files found.
app_build.gradle
View file @
3df08c76
...
@@ -38,7 +38,7 @@ android {
...
@@ -38,7 +38,7 @@ android {
ndk
{
ndk
{
if
(
"${tongdun_parent_key}"
.
size
()
>
5
)
{
if
(
"${tongdun_parent_key}"
.
size
()
>
5
)
{
abiFilters
'armeabi-v7a'
abiFilters
'armeabi-v7a'
}
else
{
}
else
{
abiFilters
'armeabi-v7a'
,
'arm64-v8a'
//,'armeabi'//, 'arm64-v8a', 'x86'
abiFilters
'armeabi-v7a'
,
'arm64-v8a'
//,'armeabi'//, 'arm64-v8a', 'x86'
}
}
}
}
...
@@ -59,6 +59,17 @@ dependencies {
...
@@ -59,6 +59,17 @@ dependencies {
executable
'sh'
args
"-c"
,
"./sdk_manager.py close TD"
executable
'sh'
args
"-c"
,
"./sdk_manager.py close TD"
}
}
}
}
exec
{
//活体选择
workingDir
=
"../lib_base/script/code"
try
{
executable
'sh'
args
"-c"
,
"./choose_liveness.sh ${liveness}"
}
catch
(
Exception
e
)
{
executable
'sh'
args
"-c"
,
"./choose_liveness.sh yitu"
}
}
// def startParams = getGradle().getStartParameter().getTaskRequests()[0]
// def startParams = getGradle().getStartParameter().getTaskRequests()[0]
// if(startParams!=null && startParams.getArgs().toString().contains("Website")){
// if(startParams!=null && startParams.getArgs().toString().contains("Website")){
...
...
script/code/choose_liveness.sh
0 → 100755
View file @
3df08c76
cd
..
if
[[
${
1
}
==
'motion'
]]
;
then
./sdk_manager.py open MOTION
./sdk_manager.py close ADVANCE
./sdk_manager.py close YITU
elif
[[
${
1
}
==
'advance'
]]
;
then
./sdk_manager.py open ADVANCE
./sdk_manager.py close MOTION
./sdk_manager.py close YITU
else
./sdk_manager.py open YITU
./sdk_manager.py close MOTION
./sdk_manager.py close ADVANCE
fi
\ No newline at end of file
src/main/java/com/common/bean/DisplayBean.java
View file @
3df08c76
...
@@ -22,6 +22,9 @@ public class DisplayBean implements Serializable {
...
@@ -22,6 +22,9 @@ public class DisplayBean implements Serializable {
private
String
advancePictureQualitySecretKey
;
private
String
advancePictureQualitySecretKey
;
private
String
restUrlSignKey
;
private
String
restUrlSignKey
;
private
String
motionAppKey
;
private
String
motionSecret
;
private
AccountKitInfo
accountKitInfo
;
private
AccountKitInfo
accountKitInfo
;
...
@@ -153,4 +156,20 @@ public class DisplayBean implements Serializable {
...
@@ -153,4 +156,20 @@ public class DisplayBean implements Serializable {
public
void
setTongDunFlag
(
boolean
tongDunFlag
)
{
public
void
setTongDunFlag
(
boolean
tongDunFlag
)
{
this
.
tongDunFlag
=
tongDunFlag
;
this
.
tongDunFlag
=
tongDunFlag
;
}
}
public
String
getMotionAppKey
()
{
return
motionAppKey
;
}
public
void
setMotionAppKey
(
String
motionAppKey
)
{
this
.
motionAppKey
=
motionAppKey
;
}
public
String
getMotionSecret
()
{
return
motionSecret
;
}
public
void
setMotionSecret
(
String
motionSecret
)
{
this
.
motionSecret
=
motionSecret
;
}
}
}
src/main/java/tech/starwin/mvp/presenter/UploadPresenter.java
View file @
3df08c76
...
@@ -95,14 +95,21 @@ public class UploadPresenter extends BasePresenter<UploadApi> {
...
@@ -95,14 +95,21 @@ public class UploadPresenter extends BasePresenter<UploadApi> {
/**
/**
* 上传依图
截取得帧图
片
* 上传依图
活体照
片
*/
*/
public
void
faceVerify
(
final
String
action
,
Context
context
,
double
amount
,
int
day
,
long
productId
)
{
public
void
faceVerify
(
final
String
action
,
Context
context
,
double
amount
,
int
day
,
long
productId
)
{
faceVerify
(
action
,
AppInfoUtils
.
getAndroidID
(
context
),
PreferencesManager
.
get
().
getVerificationData
(),
amount
,
day
,
productId
,
"yitu"
);
faceVerify
(
action
,
AppInfoUtils
.
getAndroidID
(
context
),
PreferencesManager
.
get
().
getVerificationData
(),
amount
,
day
,
productId
,
"yitu"
);
}
}
/**
/**
* 上传advance 活体图片
* 上传motion 活体照片
*/
public
void
faceVerifyMotion
(
final
String
action
,
Context
context
,
String
faceData
,
double
amount
,
int
day
,
long
productId
)
{
faceVerify
(
action
,
AppInfoUtils
.
getAndroidID
(
context
),
faceData
,
amount
,
day
,
productId
,
"motion"
);
}
/**
* 上传advance 活体照片
*/
*/
public
void
advanceFaceVerify
(
final
String
action
,
String
androidId
,
String
faceData
,
double
amount
,
int
day
,
long
productId
)
{
public
void
advanceFaceVerify
(
final
String
action
,
String
androidId
,
String
faceData
,
double
amount
,
int
day
,
long
productId
)
{
String
livenessId
=
new
Gson
().
fromJson
(
faceData
,
JsonObject
.
class
).
get
(
"livenessId"
).
toString
().
replace
(
"\""
,
""
);
String
livenessId
=
new
Gson
().
fromJson
(
faceData
,
JsonObject
.
class
).
get
(
"livenessId"
).
toString
().
replace
(
"\""
,
""
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment