diff --git a/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo.xcodeproj/project.pbxproj b/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo.xcodeproj/project.pbxproj index 9356ab1..4f148c3 100644 --- a/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo.xcodeproj/project.pbxproj +++ b/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo.xcodeproj/project.pbxproj @@ -244,6 +244,7 @@ DC1F946C234ED6F400EDB465 /* Frameworks */, DC1F946D234ED6F400EDB465 /* Resources */, FCF4F7082E0DAF8F90EDAD89 /* [CP] Copy Pods Resources */, + 65975CCEBD4261ACC2ADF5B8 /* [CP] Embed Pods Frameworks */, ); buildRules = ( ); @@ -308,6 +309,23 @@ /* End PBXResourcesBuildPhase section */ /* Begin PBXShellScriptBuildPhase section */ + 65975CCEBD4261ACC2ADF5B8 /* [CP] Embed Pods Frameworks */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-NTESLiveDetectPublicDemo/Pods-NTESLiveDetectPublicDemo-frameworks-${CONFIGURATION}-input-files.xcfilelist", + ); + name = "[CP] Embed Pods Frameworks"; + outputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-NTESLiveDetectPublicDemo/Pods-NTESLiveDetectPublicDemo-frameworks-${CONFIGURATION}-output-files.xcfilelist", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-NTESLiveDetectPublicDemo/Pods-NTESLiveDetectPublicDemo-frameworks.sh\"\n"; + showEnvVarsInLog = 0; + }; A1806712F627D0BAF961EFDF /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; @@ -510,10 +528,10 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_CXX_LANGUAGE_STANDARD = "compiler-default"; CLANG_CXX_LIBRARY = "compiler-default"; - CODE_SIGN_IDENTITY = "iPhone Developer"; - CODE_SIGN_STYLE = Manual; - DEVELOPMENT_TEAM = XB333SWTAF; - ENABLE_BITCODE = YES; + CODE_SIGN_IDENTITY = "Apple Development"; + CODE_SIGN_STYLE = Automatic; + DEVELOPMENT_TEAM = 79CE9GGQBE; + ENABLE_BITCODE = NO; FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", "$(PROJECT_DIR)", @@ -532,7 +550,7 @@ ); PRODUCT_BUNDLE_IDENTIFIER = com.netease.NTESLiveDetectPublicDemo; PRODUCT_NAME = "活体检测Demo"; - PROVISIONING_PROFILE_SPECIFIER = wildcardProfile; + PROVISIONING_PROFILE_SPECIFIER = ""; TARGETED_DEVICE_FAMILY = 1; }; name = Debug; @@ -544,10 +562,10 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_CXX_LANGUAGE_STANDARD = "compiler-default"; CLANG_CXX_LIBRARY = "compiler-default"; - CODE_SIGN_IDENTITY = "iPhone Developer"; - CODE_SIGN_STYLE = Manual; - DEVELOPMENT_TEAM = XB333SWTAF; - ENABLE_BITCODE = YES; + CODE_SIGN_IDENTITY = "Apple Development"; + CODE_SIGN_STYLE = Automatic; + DEVELOPMENT_TEAM = 79CE9GGQBE; + ENABLE_BITCODE = NO; FRAMEWORK_SEARCH_PATHS = ( "$(inherited)", "$(PROJECT_DIR)", @@ -566,7 +584,7 @@ ); PRODUCT_BUNDLE_IDENTIFIER = com.netease.NTESLiveDetectPublicDemo; PRODUCT_NAME = "活体检测Demo"; - PROVISIONING_PROFILE_SPECIFIER = wildcardProfile; + PROVISIONING_PROFILE_SPECIFIER = ""; TARGETED_DEVICE_FAMILY = 1; }; name = Release; diff --git a/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo/NTESBaseComponent.framework/Info.plist b/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo/NTESBaseComponent.framework/Info.plist new file mode 100644 index 0000000..2936fc1 Binary files /dev/null and b/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo/NTESBaseComponent.framework/Info.plist differ diff --git a/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo/NTESLiveDetect.framework/Info.plist b/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo/NTESLiveDetect.framework/Info.plist new file mode 100644 index 0000000..5cb0dcd Binary files /dev/null and b/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo/NTESLiveDetect.framework/Info.plist differ diff --git a/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo/View/NTESLiveDetectView.m b/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo/View/NTESLiveDetectView.m index f004bb8..45bde87 100644 --- a/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo/View/NTESLiveDetectView.m +++ b/NTESLiveDetectPublicDemo/NTESLiveDetectPublicDemo/View/NTESLiveDetectView.m @@ -264,15 +264,17 @@ - (void)__initActivityIndicator { - (void)__initImageView { self.cameraImage = [[UIImageView alloc] init]; + self.cameraImage.layer.cornerRadius = imageViewWidth/2; + self.cameraImage.layer.masksToBounds = YES; [self addSubview:self.cameraImage]; [self.cameraImage mas_makeConstraints:^(MASConstraintMaker *make) { make.centerX.equalTo(self); - make.top.equalTo(self).mas_offset(IS_IPHONE_X ? 50+statusBarHeight : 4+statusBarHeight); + make.top.equalTo(self).mas_offset(100); make.width.equalTo(@(imageViewWidth)); - make.height.equalTo(@(imageViewHeight)); + make.height.equalTo(@(imageViewWidth)); }]; - _progressView = [[NTESDottedLineProgress alloc] initWithFrame:CGRectMake((SCREEN_WIDTH - imageViewWidth) / 2, IS_IPHONE_X ? 50+statusBarHeight + imageViewHeight/8 : 4+statusBarHeight + imageViewHeight/8, imageViewWidth, imageViewHeight) startColor:[UIColor ntes_colorWithHexString:@"#7C49F2"] endColor:[UIColor ntes_colorWithHexString:@"#7C49F2"] startAngle:90 strokeWidth:4 strokeLength:20]; + _progressView = [[NTESDottedLineProgress alloc] initWithFrame:CGRectMake((SCREEN_WIDTH - imageViewWidth) / 2 -20, 80, imageViewWidth + 40, imageViewWidth + 40) startColor:[UIColor ntes_colorWithHexString:@"#7C49F2"] endColor:[UIColor ntes_colorWithHexString:@"#7C49F2"] startAngle:90 strokeWidth:4 strokeLength:20]; // _progressView.backgroundColor = [UIColor blackColor]; _progressView.roundStyle = YES; // _progressView.colorGradient = NO; @@ -411,31 +413,6 @@ - (void)showFrontImage { self.actionImage.hidden = YES; } -//圆形裁剪区域 --(void)transparentCutRoundArea{ - - // 圆形透明区域 - UIBezierPath *alphaPath = [UIBezierPath bezierPathWithRect:CGRectMake(0, 0, imageViewWidth, imageViewHeight)]; - UIBezierPath *arcPath = [UIBezierPath bezierPathWithArcCenter:CGPointMake(imageViewWidth/2, imageViewHeight/2) radius:cameraViewRadius-1 startAngle:0 endAngle:2*M_PI clockwise:NO]; - [alphaPath appendPath:arcPath]; - CAShapeLayer *layer = [CAShapeLayer layer]; - layer.fillColor = [UIColor whiteColor].CGColor; - layer.strokeColor = [UIColor whiteColor].CGColor; - layer.path = alphaPath.CGPath; - layer.fillRule = kCAFillRuleEvenOdd; - layer.zPosition = 1.0f; - [self.cameraImage.layer addSublayer:layer]; - - // 圆形裁剪框 - UIBezierPath *cropPath = [UIBezierPath bezierPathWithArcCenter:CGPointMake(imageViewWidth/2, imageViewHeight/2) radius:cameraViewRadius startAngle:0 endAngle:2*M_PI clockwise:NO]; - CAShapeLayer *cropLayer = [CAShapeLayer layer]; - cropLayer.path = cropPath.CGPath; - cropLayer.strokeColor = [UIColor whiteColor].CGColor; - cropLayer.fillColor = [UIColor clearColor].CGColor; - cropLayer.zPosition = 2.0f; - [self.cameraImage.layer addSublayer:cropLayer]; -} - - (void)openVoiceButton { self.shouldPlay = !self.shouldPlay; if (self.shouldPlay) { diff --git a/NTESLiveDetectPublicDemo/Podfile b/NTESLiveDetectPublicDemo/Podfile index 2f7ca3c..76809c1 100644 --- a/NTESLiveDetectPublicDemo/Podfile +++ b/NTESLiveDetectPublicDemo/Podfile @@ -5,8 +5,10 @@ source 'https://github.com/CocoaPods/Specs.git' target 'NTESLiveDetectPublicDemo' do pod 'Masonry', '~> 1.0.2' pod 'WHToast' -pod 'NTESLiveDetect', '3.1.2' +pod 'NTESLiveDetect', '3.1.9' pod 'AFNetworking' pod 'MBProgressHUD' +#pod 'NERtcSDK', '4.2.147' +#pod 'NIMSDK_LITE', '~> 9.9.0' end diff --git a/NTESLiveDetectPublicDemo/Podfile.lock b/NTESLiveDetectPublicDemo/Podfile.lock index 60f874d..b7309a0 100644 --- a/NTESLiveDetectPublicDemo/Podfile.lock +++ b/NTESLiveDetectPublicDemo/Podfile.lock @@ -16,8 +16,14 @@ PODS: - AFNetworking/NSURLSession - Masonry (1.0.2) - MBProgressHUD (1.2.0) - - NTESBaseComponent (1.7) - - NTESLiveDetect (3.1.2): + - NTESBaseComponent (1.8) + - NTESLiveDetect (3.1.9): + - NTESBaseComponent + - NTESLiveDetect/Basic (= 3.1.9) + - NTESLiveDetect/Nenn (= 3.1.9) + - NTESLiveDetect/Basic (3.1.9): + - NTESBaseComponent + - NTESLiveDetect/Nenn (3.1.9): - NTESBaseComponent - WHToast (0.0.7) @@ -25,7 +31,7 @@ DEPENDENCIES: - AFNetworking - Masonry (~> 1.0.2) - MBProgressHUD - - NTESLiveDetect (= 3.1.2) + - NTESLiveDetect (= 3.1.9) - WHToast SPEC REPOS: @@ -41,10 +47,10 @@ SPEC CHECKSUMS: AFNetworking: 3bd23d814e976cd148d7d44c3ab78017b744cd58 Masonry: 7c429b56da9d4ee0bbb3ed77a5ea710d6a5df39e MBProgressHUD: 3ee5efcc380f6a79a7cc9b363dd669c5e1ae7406 - NTESBaseComponent: b1cdf3ac1e0b303dbba9d7099ddaff7960acdb03 - NTESLiveDetect: 11d03f95eb9f72b476ab3a0c6aab6eca55b8eda9 + NTESBaseComponent: 7b310e7e80bb6c27183176188b98356d200dbbc5 + NTESLiveDetect: 6adbb0fa0ca052de04226ad609b0832b87372fb3 WHToast: 11a17a3f09f5f733e32bd6f3338919a448cbb719 -PODFILE CHECKSUM: 7c7bc272c60b6bd668dd25b91a2485713ff01271 +PODFILE CHECKSUM: c93f5f8035535a30a9075ff4495c99cf8c13622a -COCOAPODS: 1.11.3 +COCOAPODS: 1.13.0