From 3d43a8985995f7a844301741d8c30cc7697c611c Mon Sep 17 00:00:00 2001 From: croath Date: Fri, 26 Aug 2016 10:15:40 +0800 Subject: [PATCH 1/7] A fix for UIImage category --- bf/bf.xcodeproj/project.pbxproj | 15 +++-- bf/bf/Base.lproj/Main.storyboard | 62 +++++++++++------ bf/bf/BetterFaceClass/UIImage+BetterFace.m | 67 +++++++++++++------ .../AppIcon.appiconset/Contents.json | 15 +++++ bf/bf/Launch Screen.storyboard | 50 ++++++++++++++ bf/bf/ViewController.m | 7 -- bf/bf/bf-Info.plist | 4 +- bf/bfTests/bfTests-Info.plist | 2 +- 8 files changed, 164 insertions(+), 58 deletions(-) create mode 100644 bf/bf/Launch Screen.storyboard diff --git a/bf/bf.xcodeproj/project.pbxproj b/bf/bf.xcodeproj/project.pbxproj index 9969dfa..622aaa0 100644 --- a/bf/bf.xcodeproj/project.pbxproj +++ b/bf/bf.xcodeproj/project.pbxproj @@ -31,6 +31,7 @@ 2783FE381816ADF600F3F6E9 /* up2.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 2783FE2D1816ADF600F3F6E9 /* up2.jpg */; }; 2783FE391816ADF600F3F6E9 /* up3.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 2783FE2E1816ADF600F3F6E9 /* up3.jpg */; }; 2783FE3E1816B80000F3F6E9 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 2783FE3D1816B80000F3F6E9 /* QuartzCore.framework */; }; + 27A3C2681D5D5DA100EF6666 /* Launch Screen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 27A3C2671D5D5DA100EF6666 /* Launch Screen.storyboard */; }; 27C77B4F181707E300F3F073 /* up4.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 27C77B4E181707E300F3F073 /* up4.jpg */; }; 27C77B51181708BF00F3F073 /* l4.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 27C77B50181708BF00F3F073 /* l4.jpg */; }; 27C77B53181709F000F3F073 /* m2.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 27C77B52181709F000F3F073 /* m2.jpg */; }; @@ -78,6 +79,7 @@ 2783FE2D1816ADF600F3F6E9 /* up2.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = up2.jpg; sourceTree = ""; }; 2783FE2E1816ADF600F3F6E9 /* up3.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = up3.jpg; sourceTree = ""; }; 2783FE3D1816B80000F3F6E9 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; + 27A3C2671D5D5DA100EF6666 /* Launch Screen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = "Launch Screen.storyboard"; sourceTree = ""; }; 27C77B4E181707E300F3F073 /* up4.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = up4.jpg; sourceTree = ""; }; 27C77B50181708BF00F3F073 /* l4.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = l4.jpg; sourceTree = ""; }; 27C77B52181709F000F3F073 /* m2.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = m2.jpg; sourceTree = ""; }; @@ -151,6 +153,7 @@ 2783FDF8181697D200F3F6E9 /* AppDelegate.h */, 2783FDF9181697D200F3F6E9 /* AppDelegate.m */, 2783FDFB181697D200F3F6E9 /* Main.storyboard */, + 27A3C2671D5D5DA100EF6666 /* Launch Screen.storyboard */, 2783FDFE181697D200F3F6E9 /* ViewController.h */, 2783FDFF181697D200F3F6E9 /* ViewController.m */, 2783FE01181697D200F3F6E9 /* Images.xcassets */, @@ -284,7 +287,7 @@ 2783FDDE181697D200F3F6E9 /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 0500; + LastUpgradeCheck = 0730; ORGANIZATIONNAME = Croath; TargetAttributes = { 2783FE06181697D200F3F6E9 = { @@ -322,6 +325,7 @@ 2783FE341816ADF600F3F6E9 /* l2.jpg in Resources */, 2783FE381816ADF600F3F6E9 /* up2.jpg in Resources */, 2783FE02181697D200F3F6E9 /* Images.xcassets in Resources */, + 27A3C2681D5D5DA100EF6666 /* Launch Screen.storyboard in Resources */, 27C77B51181708BF00F3F073 /* l4.jpg in Resources */, 2783FE371816ADF600F3F6E9 /* up1.jpg in Resources */, 2783FDF4181697D200F3F6E9 /* InfoPlist.strings in Resources */, @@ -405,7 +409,6 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; - ARCHS = "$(ARCHS_STANDARD_INCLUDING_64_BIT)"; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; @@ -420,6 +423,7 @@ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; + ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; GCC_OPTIMIZATION_LEVEL = 0; @@ -444,7 +448,6 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; - ARCHS = "$(ARCHS_STANDARD_INCLUDING_64_BIT)"; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; @@ -481,6 +484,7 @@ GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = "bf/bf-Prefix.pch"; INFOPLIST_FILE = "bf/bf-Info.plist"; + PRODUCT_BUNDLE_IDENTIFIER = "com.croath.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = "$(TARGET_NAME)"; WRAPPER_EXTENSION = app; }; @@ -494,6 +498,7 @@ GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = "bf/bf-Prefix.pch"; INFOPLIST_FILE = "bf/bf-Info.plist"; + PRODUCT_BUNDLE_IDENTIFIER = "com.croath.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = "$(TARGET_NAME)"; WRAPPER_EXTENSION = app; }; @@ -502,7 +507,6 @@ 2783FE1C181697D300F3F6E9 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_INCLUDING_64_BIT)"; BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/bf.app/bf"; FRAMEWORK_SEARCH_PATHS = ( "$(SDKROOT)/Developer/Library/Frameworks", @@ -516,6 +520,7 @@ "$(inherited)", ); INFOPLIST_FILE = "bfTests/bfTests-Info.plist"; + PRODUCT_BUNDLE_IDENTIFIER = "com.croath.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = "$(TARGET_NAME)"; TEST_HOST = "$(BUNDLE_LOADER)"; WRAPPER_EXTENSION = xctest; @@ -525,7 +530,6 @@ 2783FE1D181697D300F3F6E9 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { - ARCHS = "$(ARCHS_STANDARD_INCLUDING_64_BIT)"; BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/bf.app/bf"; FRAMEWORK_SEARCH_PATHS = ( "$(SDKROOT)/Developer/Library/Frameworks", @@ -535,6 +539,7 @@ GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = "bf/bf-Prefix.pch"; INFOPLIST_FILE = "bfTests/bfTests-Info.plist"; + PRODUCT_BUNDLE_IDENTIFIER = "com.croath.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = "$(TARGET_NAME)"; TEST_HOST = "$(BUNDLE_LOADER)"; WRAPPER_EXTENSION = xctest; diff --git a/bf/bf/Base.lproj/Main.storyboard b/bf/bf/Base.lproj/Main.storyboard index ecee14f..eecd998 100644 --- a/bf/bf/Base.lproj/Main.storyboard +++ b/bf/bf/Base.lproj/Main.storyboard @@ -1,20 +1,25 @@ - + - + + + + + + + - + - @@ -68,31 +73,49 @@ - - - + + + + + + - - - + + + + + + - - + + + + + + + + + + + + + + + @@ -104,9 +127,4 @@ - - - - - - \ No newline at end of file + diff --git a/bf/bf/BetterFaceClass/UIImage+BetterFace.m b/bf/bf/BetterFaceClass/UIImage+BetterFace.m index f776f71..33b609a 100644 --- a/bf/bf/BetterFaceClass/UIImage+BetterFace.m +++ b/bf/bf/BetterFaceClass/UIImage+BetterFace.m @@ -37,56 +37,79 @@ - (UIImage *)_subImageForFaceFeatures:(NSArray *)faceFeatures size:(CGSize)size { CGRect fixedRect = CGRectMake(MAXFLOAT, MAXFLOAT, 0, 0); CGFloat rightBorder = 0, bottomBorder = 0; - for (CIFaceFeature *faceFeature in faceFeatures){ + CGSize imageSize = self.size; + + for (CIFaceFeature * faceFeature in faceFeatures){ CGRect oneRect = faceFeature.bounds; - oneRect.origin.y = size.height - oneRect.origin.y - oneRect.size.height; + // Mirror the frame of the feature + oneRect.origin.y = imageSize.height - oneRect.origin.y - oneRect.size.height; + // Always get the minimum x & y fixedRect.origin.x = MIN(oneRect.origin.x, fixedRect.origin.x); fixedRect.origin.y = MIN(oneRect.origin.y, fixedRect.origin.y); + // Calculate the faces rectangle rightBorder = MAX(oneRect.origin.x + oneRect.size.width, rightBorder); bottomBorder = MAX(oneRect.origin.y + oneRect.size.height, bottomBorder); } + // Calculate the size of rectangle of faces fixedRect.size.width = rightBorder - fixedRect.origin.x; fixedRect.size.height = bottomBorder - fixedRect.origin.y; CGPoint fixedCenter = CGPointMake(fixedRect.origin.x + fixedRect.size.width / 2.0, fixedRect.origin.y + fixedRect.size.height / 2.0); CGPoint offset = CGPointZero; - CGSize finalSize = size; - if (size.width / size.height > self.size.width / self.size.height) { + CGSize finalSize = imageSize; + if (imageSize.width / imageSize.height > size.width / size.height) { //move horizonal - finalSize.height = self.size.height; - finalSize.width = size.width/size.height * finalSize.height; - fixedCenter.x = finalSize.width / size.width * fixedCenter.x; - fixedCenter.y = finalSize.width / size.width * fixedCenter.y; + finalSize.height = size.height; + finalSize.width = imageSize.width/imageSize.height * finalSize.height; + + // Scale the fixed center with image scale(scale image to adjust image view) + fixedCenter.x = finalSize.width/imageSize.width * fixedCenter.x; + fixedCenter.y = finalSize.width/imageSize.width * fixedCenter.y; - offset.x = fixedCenter.x - self.size.width * 0.5; + offset.x = fixedCenter.x - size.width * 0.5; if (offset.x < 0) { + // Move outside left offset.x = 0; - } else if (offset.x + self.size.width > finalSize.width) { - offset.x = finalSize.width - self.size.width; + } else if (offset.x + size.width > finalSize.width) { + // Move outside right + offset.x = finalSize.width - size.width; } - offset.x = - offset.x; + + // If you want the final image is fit to the image view, you should set the width adjust the image view. + finalSize.width = size.width; } else { //move vertical - finalSize.width = self.size.width; - finalSize.height = size.height/size.width * finalSize.width; - fixedCenter.x = finalSize.width / size.width * fixedCenter.x; - fixedCenter.y = finalSize.width / size.width * fixedCenter.y; + finalSize.width = size.width; + finalSize.height = imageSize.height/imageSize.width * finalSize.width; - offset.y = fixedCenter.y - self.size.height * (1-GOLDEN_RATIO); + // Scale the fixed center with image scale(scale image to adjust image view) + fixedCenter.x = finalSize.width/imageSize.width * fixedCenter.x; + fixedCenter.y = finalSize.width/imageSize.width * fixedCenter.y; + + offset.y = fixedCenter.y - size.height * (1 - GOLDEN_RATIO); if (offset.y < 0) { + // Move outside top offset.y = 0; - } else if (offset.y + self.size.height > finalSize.height){ - offset.y = finalSize.height = self.size.height; + } else if (offset.y + size.height > finalSize.height){ + // Move outside bottom + // offset.y = finalSize.height = size.height; + offset.y = finalSize.height - size.height; } - offset.y = - offset.y; + + // If you want the final image is fit to the image view, you should set the height adjust the image view. + finalSize.height = size.height; } - CGRect finalRect = CGRectApplyAffineTransform(CGRectMake(offset.x, offset.y, finalSize.width, finalSize.height), - CGAffineTransformMakeScale(self.scale, self.scale)); + // The finalSize is just fit the image view now, so we should scale the frame to the image size. + CGFloat scale = imageSize.width/finalSize.width; + CGAffineTransform transform = CGAffineTransformMakeScale(scale, scale); + // Get the final image rect + CGRect finalRect = CGRectApplyAffineTransform(CGRectMake(offset.x, offset.y, finalSize.width, finalSize.height),transform); + // Creat image CGImageRef imageRef = CGImageCreateWithImageInRect([self CGImage], finalRect); UIImage *subImage = [UIImage imageWithCGImage:imageRef scale:self.scale orientation:self.imageOrientation]; CGImageRelease(imageRef); diff --git a/bf/bf/Images.xcassets/AppIcon.appiconset/Contents.json b/bf/bf/Images.xcassets/AppIcon.appiconset/Contents.json index a396706..118c98f 100644 --- a/bf/bf/Images.xcassets/AppIcon.appiconset/Contents.json +++ b/bf/bf/Images.xcassets/AppIcon.appiconset/Contents.json @@ -5,15 +5,30 @@ "size" : "29x29", "scale" : "2x" }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, { "idiom" : "iphone", "size" : "40x40", "scale" : "2x" }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, { "idiom" : "iphone", "size" : "60x60", "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" } ], "info" : { diff --git a/bf/bf/Launch Screen.storyboard b/bf/bf/Launch Screen.storyboard new file mode 100644 index 0000000..26ec982 --- /dev/null +++ b/bf/bf/Launch Screen.storyboard @@ -0,0 +1,50 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/bf/bf/ViewController.m b/bf/bf/ViewController.m index 278d12c..59f8e98 100644 --- a/bf/bf/ViewController.m +++ b/bf/bf/ViewController.m @@ -19,7 +19,6 @@ @implementation ViewController - (void)viewDidLoad { [super viewDidLoad]; - // Do any additional setup after loading the view, typically from a nib. [_view0.layer setBorderColor:[UIColor grayColor].CGColor]; [_view0.layer setBorderWidth:0.5f]; [_view0 setContentMode:UIViewContentModeScaleAspectFill]; @@ -33,12 +32,6 @@ - (void)viewDidLoad [_view1 setFast:YES]; } -- (void)didReceiveMemoryWarning -{ - [super didReceiveMemoryWarning]; - // Dispose of any resources that can be recreated. -} - - (IBAction)tabPressed:(id)sender { NSString *imageStr = @""; switch ([sender tag]) { diff --git a/bf/bf/bf-Info.plist b/bf/bf/bf-Info.plist index 0ce166b..6fd221e 100644 --- a/bf/bf/bf-Info.plist +++ b/bf/bf/bf-Info.plist @@ -9,7 +9,7 @@ CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier - com.croath.${PRODUCT_NAME:rfc1034identifier} + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName @@ -24,6 +24,8 @@ 1.0 LSRequiresIPhoneOS + UILaunchStoryboardName + Launch Screen UIMainStoryboardFile Main UIRequiredDeviceCapabilities diff --git a/bf/bfTests/bfTests-Info.plist b/bf/bfTests/bfTests-Info.plist index 20460e2..169b6f7 100644 --- a/bf/bfTests/bfTests-Info.plist +++ b/bf/bfTests/bfTests-Info.plist @@ -7,7 +7,7 @@ CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier - com.croath.${PRODUCT_NAME:rfc1034identifier} + $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundlePackageType From 1cfa924054ba8d9e0d4bce30d8e5822e5d1fd6f6 Mon Sep 17 00:00:00 2001 From: croath Date: Fri, 26 Aug 2016 10:25:36 +0800 Subject: [PATCH 2/7] Enable single image enabling. --- README.md | 20 +++++++++---------- .../BetterFaceClass/UIImageView+BetterFace.m | 13 ++++++++++-- 2 files changed, 21 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index 2b49f06..4364ba7 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ Looking for an Android version? Check this! [https://github.com/beartung/tclip-a ##Why? - - Have problems showing the resized image previews? + - Have problems showing the resized image previews? - People in the preview only have chins but not faces? - A group photo doesn't look well? @@ -21,14 +21,14 @@ Like this: ##How? - 1. drag `UIImageView+BetterFace.h` and `UIImageView+BetterFace.m` to your project - 2. add CoreImage.framework to your project - 3. import the .h file - 4. add `hack_uiimageview_bf();` to your `main` function - 5. add this:`[anImageView setNeedsBetterFace:YES];` - 6. done - 7. still have problems? clone the project and see the demo. - + 1. Drag `UIImageView+BetterFace.h` and `UIImageView+BetterFace.m` to your project + 2. Add CoreImage.framework to your project + 3. Import the .h file + 4. Add this:`[anImageView setNeedsBetterFace:YES];` + 5. If you want all `setImage:` methods do the magic: Add `hack_uiimageview_bf();` to your `main` function; Otherwise call `setBetterFaceImage:` for every image you want to make the face detection. + 6. Done + 7. Still have problems? clone the project and see the demo. + ##Too slow? try set the `fast` property to `YES` to get the faster speed(lower accuracy) @@ -46,7 +46,7 @@ If you're building your applications using UIImageView-BetterFace, please let me ##Debugging Add `BF_DEBUG` to your pre compile macros or `#define BF_DEBUG` to your `prefix.pch` file in order to see turn ON debugging logs on the console. - + ##Other Any issue and pull request is welcome. diff --git a/bf/bf/BetterFaceClass/UIImageView+BetterFace.m b/bf/bf/BetterFaceClass/UIImageView+BetterFace.m index f9a8925..eb55ab5 100644 --- a/bf/bf/BetterFaceClass/UIImageView+BetterFace.m +++ b/bf/bf/BetterFaceClass/UIImageView+BetterFace.m @@ -23,12 +23,21 @@ @implementation UIImageView (BetterFace) void hack_uiimageview_bf(){ Method oriSetImgMethod = class_getInstanceMethod([UIImageView class], @selector(setImage:)); - Method newSetImgMethod = class_getInstanceMethod([UIImageView class], @selector(setBetterFaceImage:)); + Method newSetImgMethod = class_getInstanceMethod([UIImageView class], @selector(_setBetterFaceImage:)); method_exchangeImplementations(newSetImgMethod, oriSetImgMethod); } - (void)setBetterFaceImage:(UIImage *)image{ - [self setBetterFaceImage:image]; + [self setImage:image]; + if (![self needsBetterFace]) { + return; + } + + [self faceDetect:image]; +} + +- (void)_setBetterFaceImage:(UIImage *)image{ + [self _setBetterFaceImage:image]; if (![self needsBetterFace]) { return; } From 971aa1e26a5912a267c823a84347f0d437ecb457 Mon Sep 17 00:00:00 2001 From: croath Date: Mon, 29 Aug 2016 07:37:01 +0800 Subject: [PATCH 3/7] fix a typo --- bf/bf/BetterFaceClass/UIImageView+BetterFace.m | 2 +- bf/bf/ViewController.m | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bf/bf/BetterFaceClass/UIImageView+BetterFace.m b/bf/bf/BetterFaceClass/UIImageView+BetterFace.m index eb55ab5..2b4e8ca 100644 --- a/bf/bf/BetterFaceClass/UIImageView+BetterFace.m +++ b/bf/bf/BetterFaceClass/UIImageView+BetterFace.m @@ -161,7 +161,7 @@ -(void)markAfterFaceDetect:(NSArray *)features size:(CGSize)size{ if (offset.y < 0) { offset.y = 0; } else if (offset.y + self.bounds.size.height > finalSize.height){ - offset.y = finalSize.height = self.bounds.size.height; + offset.y = finalSize.height - self.bounds.size.height; } offset.y = - offset.y; } diff --git a/bf/bf/ViewController.m b/bf/bf/ViewController.m index 59f8e98..1d503af 100644 --- a/bf/bf/ViewController.m +++ b/bf/bf/ViewController.m @@ -29,7 +29,7 @@ - (void)viewDidLoad [_view1 setContentMode:UIViewContentModeScaleAspectFill]; [_view1 setClipsToBounds:YES]; [_view1 setNeedsBetterFace:YES]; - [_view1 setFast:YES]; + [_view1 setFast:NO]; } - (IBAction)tabPressed:(id)sender { From 535728a3b5526d86a4a9b7c35719d2808efc48f9 Mon Sep 17 00:00:00 2001 From: croath Date: Mon, 29 Aug 2016 07:44:32 +0800 Subject: [PATCH 4/7] add travis ci --- .travis.yml | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..69b4864 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,5 @@ +language: objective-c +osx_image: xcode7.3 +before_script: +script: + - xctool -project bf/bf.xcodeproj -scheme bf build From ef35abc6290b5cbbb79bfd72e53d9fd2d0933fa9 Mon Sep 17 00:00:00 2001 From: croath Date: Mon, 29 Aug 2016 07:47:33 +0800 Subject: [PATCH 5/7] make scheme shared (for ci) --- .../xcshareddata/xcschemes/bf.xcscheme | 101 ++++++++++++++++++ 1 file changed, 101 insertions(+) create mode 100644 bf/bf.xcodeproj/xcshareddata/xcschemes/bf.xcscheme diff --git a/bf/bf.xcodeproj/xcshareddata/xcschemes/bf.xcscheme b/bf/bf.xcodeproj/xcshareddata/xcschemes/bf.xcscheme new file mode 100644 index 0000000..de8a1ee --- /dev/null +++ b/bf/bf.xcodeproj/xcshareddata/xcschemes/bf.xcscheme @@ -0,0 +1,101 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 766cbd63d2a3b9183e99182c28b11317ff7b1907 Mon Sep 17 00:00:00 2001 From: croath Date: Mon, 29 Aug 2016 07:56:31 +0800 Subject: [PATCH 6/7] SDK simulator --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 69b4864..85aa0f4 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,4 +2,4 @@ language: objective-c osx_image: xcode7.3 before_script: script: - - xctool -project bf/bf.xcodeproj -scheme bf build + - xctool -project bf/bf.xcodeproj -scheme bf -sdk iphonesimulator ONLY_ACTIVE_ARCH=NO From 221580f7f79b0c5dd6d8bc2cb3faea2b2f3d95de Mon Sep 17 00:00:00 2001 From: croath Date: Mon, 29 Aug 2016 08:04:34 +0800 Subject: [PATCH 7/7] add build status to readme --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 4364ba7..892ddbe 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ +[![Build Status](https://travis-ci.org/croath/UIImageView-BetterFace.svg)](https://travis-ci.org/croath/UIImageView-BetterFace) + UIImageView-BetterFace ======================