├── LBBlurredImage ├── en.lproj │ ├── InfoPlist.strings │ └── LBViewController.xib ├── Default.png ├── example.png ├── Default@2x.png ├── Default-568h@2x.png ├── LBViewController.h ├── LBBlurredImage-Prefix.pch ├── main.m ├── LBAppDelegate.h ├── LBViewController.m ├── UIImageView+LBBlurredImage.h ├── LBBlurredImage-Info.plist ├── LBAppDelegate.m └── UIImageView+LBBlurredImage.m ├── Resources └── SimulatorScreenshot.png ├── .gitignore ├── README.md └── LBBlurredImage.xcodeproj └── project.pbxproj /LBBlurredImage/en.lproj/InfoPlist.strings: -------------------------------------------------------------------------------- 1 | /* Localized versions of Info.plist keys */ 2 | 3 | -------------------------------------------------------------------------------- /LBBlurredImage/Default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenHongbin/LBBlurredImage/HEAD/LBBlurredImage/Default.png -------------------------------------------------------------------------------- /LBBlurredImage/example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenHongbin/LBBlurredImage/HEAD/LBBlurredImage/example.png -------------------------------------------------------------------------------- /LBBlurredImage/Default@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenHongbin/LBBlurredImage/HEAD/LBBlurredImage/Default@2x.png -------------------------------------------------------------------------------- /Resources/SimulatorScreenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenHongbin/LBBlurredImage/HEAD/Resources/SimulatorScreenshot.png -------------------------------------------------------------------------------- /LBBlurredImage/Default-568h@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenHongbin/LBBlurredImage/HEAD/LBBlurredImage/Default-568h@2x.png -------------------------------------------------------------------------------- /LBBlurredImage/LBViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // LBViewController.h 3 | // Blur 4 | // 5 | // Created by Luca Bernardi on 11/11/12. 6 | // Copyright (c) 2012 Luca Bernardi. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface LBViewController : UIViewController 12 | 13 | @property (strong, nonatomic) IBOutlet UIImageView *imageView; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /LBBlurredImage/LBBlurredImage-Prefix.pch: -------------------------------------------------------------------------------- 1 | // 2 | // Prefix header for all source files of the 'Blur' target in the 'Blur' project 3 | // 4 | 5 | #import 6 | 7 | #ifndef __IPHONE_4_0 8 | #warning "This project uses features only available in iOS SDK 4.0 and later." 9 | #endif 10 | 11 | #ifdef __OBJC__ 12 | #import 13 | #import 14 | #endif 15 | -------------------------------------------------------------------------------- /LBBlurredImage/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // Blur 4 | // 5 | // Created by Luca Bernardi on 11/11/12. 6 | // Copyright (c) 2012 Luca Bernardi. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | #import "LBAppDelegate.h" 12 | 13 | int main(int argc, char *argv[]) 14 | { 15 | @autoreleasepool { 16 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([LBAppDelegate class])); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /LBBlurredImage/LBAppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // LBAppDelegate.h 3 | // Blur 4 | // 5 | // Created by Luca Bernardi on 11/11/12. 6 | // Copyright (c) 2012 Luca Bernardi. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @class LBViewController; 12 | 13 | @interface LBAppDelegate : UIResponder 14 | 15 | @property (strong, nonatomic) UIWindow *window; 16 | 17 | @property (strong, nonatomic) LBViewController *viewController; 18 | 19 | @end 20 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Mac OS X Finder and whatnot 2 | .DS_Store 3 | 4 | # XCode 5 | *.mode1 6 | *.mode1v3 7 | *.mode2v3 8 | *.perspective 9 | *.perspectivev3 10 | *.pbxuser 11 | *.xcworkspace 12 | xcuserdata 13 | 14 | # Generated files 15 | VersionX-revision.h 16 | 17 | # build products 18 | build/ 19 | *.o 20 | *.LinkFileList 21 | *.hmap 22 | 23 | # Other source repository archive directories (protects when importing) 24 | .hg 25 | .svn 26 | CVS 27 | 28 | # automatic backup files 29 | *~.nib/ 30 | *.swp 31 | *~ 32 | *.dat 33 | *.dep 34 | -------------------------------------------------------------------------------- /LBBlurredImage/LBViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // LBViewController.m 3 | // Blur 4 | // 5 | // Created by Luca Bernardi on 11/11/12. 6 | // Copyright (c) 2012 Luca Bernardi. All rights reserved. 7 | // 8 | 9 | #import "LBViewController.h" 10 | #import "UIImageView+LBBlurredImage.h" 11 | 12 | @interface LBViewController () 13 | 14 | @end 15 | 16 | 17 | @implementation LBViewController 18 | 19 | #pragma mark - View lifecycle 20 | 21 | - (void)viewDidLoad 22 | { 23 | [super viewDidLoad]; 24 | } 25 | 26 | - (void)viewWillAppear:(BOOL)animated 27 | { 28 | [self.imageView setImageToBlur:[UIImage imageNamed:@"example"] 29 | blurRadius:kLBBlurredImageDefaultBlurRadius 30 | completionBlock:^(NSError *error){ 31 | NSLog(@"The blurred image has been setted"); 32 | }]; 33 | } 34 | 35 | - (void)didReceiveMemoryWarning 36 | { 37 | [super didReceiveMemoryWarning]; 38 | } 39 | 40 | @end 41 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | LBBlurredImage 2 | ============ 3 | 4 | LBBlurredImage is an UIImageView category that permit to set an image and make this blurred. 5 | 6 | Here are an example of what you can achieve: 7 | 8 | ![](https://raw.github.com/lukabernardi/LBBlurredImage/master/Resources/SimulatorScreenshot.png) 9 | 10 | Installation & Use 11 | ============ 12 | 13 | ### Installation 14 | - Just grab the two file named `UIImageView+LBBlurredImage.h` & `UIImageView+LBBlurredImage.m` in the Additions group into your project and link with CoreImage.framework . 15 | - `#import "UIImageView+LBBlurredImage.h"` where you need it. 16 | 17 | ### Use 18 | 19 | ``` objective-c 20 | [self.imageView setImageToBlur:[UIImage imageNamed:@"example"] 21 | blurRadius:kLBBlurredImageDefaultBlurRadius 22 | completionBlock:^(NSError *error){ 23 | NSLog(@"The blurred image has been setted"); 24 | }]; 25 | ``` 26 | 27 | The generation of the blurred image is made on a background thread, for this reason a completion block is provided. The completionBlock is dispatched on the main thread when the image was generated and set to the UIImageView. -------------------------------------------------------------------------------- /LBBlurredImage/UIImageView+LBBlurredImage.h: -------------------------------------------------------------------------------- 1 | // 2 | // UIImageView+LBBlurredImage.h 3 | // LBBlurredImage 4 | // 5 | // Created by Luca Bernardi on 11/11/12. 6 | // Copyright (c) 2012 Luca Bernardi. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | typedef void(^LBBlurredImageCompletionBlock)(NSError *error); 12 | 13 | extern NSString *const kLBBlurredImageErrorDomain; 14 | 15 | extern CGFloat const kLBBlurredImageDefaultBlurRadius; 16 | 17 | enum LBBlurredImageError { 18 | LBBlurredImageErrorFilterNotAvailable = 0, 19 | }; 20 | 21 | 22 | @interface UIImageView (LBBlurredImage) 23 | 24 | /** 25 | Set the blurred version of the provided image to the UIImageView 26 | 27 | @param UIImage the image to blur and set as UIImageView's image 28 | @param CGFLoat the radius of the blur used by the Gaussian filter 29 | *param LBBlurredImageCompletionBlock a completion block called after the image 30 | was blurred and set to the UIImageView (the block is dispatched on main thread) 31 | */ 32 | - (void)setImageToBlur: (UIImage *)image 33 | blurRadius: (CGFloat)blurRadius 34 | completionBlock: (LBBlurredImageCompletionBlock) completion; 35 | 36 | @end 37 | -------------------------------------------------------------------------------- /LBBlurredImage/LBBlurredImage-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | ${PRODUCT_NAME} 9 | CFBundleExecutable 10 | ${EXECUTABLE_NAME} 11 | CFBundleIdentifier 12 | com.lucabernardi.${PRODUCT_NAME:rfc1034identifier} 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | ${PRODUCT_NAME} 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1.0 25 | LSRequiresIPhoneOS 26 | 27 | UIRequiredDeviceCapabilities 28 | 29 | armv7 30 | 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | 38 | 39 | -------------------------------------------------------------------------------- /LBBlurredImage/LBAppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // LBAppDelegate.m 3 | // Blur 4 | // 5 | // Created by Luca Bernardi on 11/11/12. 6 | // Copyright (c) 2012 Luca Bernardi. All rights reserved. 7 | // 8 | 9 | #import "LBAppDelegate.h" 10 | 11 | #import "LBViewController.h" 12 | 13 | @implementation LBAppDelegate 14 | 15 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 16 | { 17 | self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; 18 | // Override point for customization after application launch. 19 | self.viewController = [[LBViewController alloc] initWithNibName:@"LBViewController" bundle:nil]; 20 | self.window.rootViewController = self.viewController; 21 | [self.window makeKeyAndVisible]; 22 | return YES; 23 | } 24 | 25 | - (void)applicationWillResignActive:(UIApplication *)application 26 | { 27 | // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. 28 | // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. 29 | } 30 | 31 | - (void)applicationDidEnterBackground:(UIApplication *)application 32 | { 33 | // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 34 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 35 | } 36 | 37 | - (void)applicationWillEnterForeground:(UIApplication *)application 38 | { 39 | // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. 40 | } 41 | 42 | - (void)applicationDidBecomeActive:(UIApplication *)application 43 | { 44 | // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. 45 | } 46 | 47 | - (void)applicationWillTerminate:(UIApplication *)application 48 | { 49 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 50 | } 51 | 52 | @end 53 | -------------------------------------------------------------------------------- /LBBlurredImage/UIImageView+LBBlurredImage.m: -------------------------------------------------------------------------------- 1 | // 2 | // UIImageView+LBBlurredImage.m 3 | // LBBlurredImage 4 | // 5 | // Created by Luca Bernardi on 11/11/12. 6 | // Copyright (c) 2012 Luca Bernardi. All rights reserved. 7 | // 8 | 9 | #import "UIImageView+LBBlurredImage.h" 10 | #import 11 | 12 | 13 | NSString *const kLBBlurredImageErrorDomain = @"com.lucabernardi.blurred_image_additions"; 14 | CGFloat const kLBBlurredImageDefaultBlurRadius = 20.0; 15 | 16 | 17 | @implementation UIImageView (LBBlurredImage) 18 | 19 | #pragma mark - LBBlurredImage Additions 20 | 21 | - (void)setImageToBlur: (UIImage *)image 22 | blurRadius: (CGFloat)blurRadius 23 | completionBlock: (LBBlurredImageCompletionBlock) completion 24 | 25 | { 26 | CIContext *context = [CIContext contextWithOptions:nil]; 27 | CIImage *sourceImage = [CIImage imageWithCGImage:image.CGImage]; 28 | 29 | // Apply clamp filter: 30 | // this is needed because the CIGaussianBlur when applied makes 31 | // a trasparent border around the image 32 | 33 | NSString *clampFilterName = @"CIAffineClamp"; 34 | CIFilter *clamp = [CIFilter filterWithName:clampFilterName]; 35 | 36 | if (!clamp) { 37 | 38 | NSError *error = [self errorForNotExistingFilterWithName:clampFilterName]; 39 | if (completion) { 40 | completion(error); 41 | } 42 | return; 43 | } 44 | 45 | [clamp setValue:sourceImage 46 | forKey:kCIInputImageKey]; 47 | 48 | CIImage *clampResult = [clamp valueForKey:kCIOutputImageKey]; 49 | 50 | // Apply Gaussian Blur filter 51 | 52 | NSString *gaussianBlurFilterName = @"CIGaussianBlur"; 53 | CIFilter *gaussianBlur = [CIFilter filterWithName:gaussianBlurFilterName]; 54 | 55 | if (!gaussianBlur) { 56 | 57 | NSError *error = [self errorForNotExistingFilterWithName:gaussianBlurFilterName]; 58 | if (completion) { 59 | completion(error); 60 | } 61 | return; 62 | } 63 | 64 | [gaussianBlur setValue:clampResult 65 | forKey:kCIInputImageKey]; 66 | [gaussianBlur setValue:[NSNumber numberWithFloat:blurRadius] 67 | forKey:@"inputRadius"]; 68 | 69 | CIImage *gaussianBlurResult = [gaussianBlur valueForKey:kCIOutputImageKey]; 70 | 71 | __weak UIImageView *selfWeak = self; 72 | 73 | dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^{ 74 | 75 | CGImageRef cgImage = [context createCGImage:gaussianBlurResult 76 | fromRect:[sourceImage extent]]; 77 | 78 | dispatch_async(dispatch_get_main_queue(), ^{ 79 | selfWeak.image = [UIImage imageWithCGImage:cgImage]; 80 | if (completion){ 81 | completion(nil); 82 | } 83 | }); 84 | }); 85 | } 86 | 87 | /** 88 | Internal method for generate an NSError if the provided CIFilter name doesn't exists 89 | */ 90 | - (NSError *)errorForNotExistingFilterWithName:(NSString *)filterName 91 | { 92 | NSString *errorDescription = [NSString stringWithFormat:@"The CIFilter named %@ doesn't exist",filterName]; 93 | NSError *error = [NSError errorWithDomain:kLBBlurredImageErrorDomain 94 | code:LBBlurredImageErrorFilterNotAvailable 95 | userInfo:@{NSLocalizedDescriptionKey : errorDescription}]; 96 | return error; 97 | } 98 | 99 | @end 100 | -------------------------------------------------------------------------------- /LBBlurredImage.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 9F8DAB0A16506119006C4EF3 /* UIImageView+LBBlurredImage.m in Sources */ = {isa = PBXBuildFile; fileRef = 9F8DAB0916506119006C4EF3 /* UIImageView+LBBlurredImage.m */; }; 11 | 9FB1B48C165051DD0076BEB5 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9FB1B48B165051DD0076BEB5 /* UIKit.framework */; }; 12 | 9FB1B48E165051DD0076BEB5 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9FB1B48D165051DD0076BEB5 /* Foundation.framework */; }; 13 | 9FB1B490165051DD0076BEB5 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9FB1B48F165051DD0076BEB5 /* CoreGraphics.framework */; }; 14 | 9FB1B496165051DD0076BEB5 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 9FB1B494165051DD0076BEB5 /* InfoPlist.strings */; }; 15 | 9FB1B498165051DD0076BEB5 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 9FB1B497165051DD0076BEB5 /* main.m */; }; 16 | 9FB1B49C165051DD0076BEB5 /* LBAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 9FB1B49B165051DD0076BEB5 /* LBAppDelegate.m */; }; 17 | 9FB1B49E165051DD0076BEB5 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 9FB1B49D165051DD0076BEB5 /* Default.png */; }; 18 | 9FB1B4A0165051DD0076BEB5 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 9FB1B49F165051DD0076BEB5 /* Default@2x.png */; }; 19 | 9FB1B4A2165051DD0076BEB5 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 9FB1B4A1165051DD0076BEB5 /* Default-568h@2x.png */; }; 20 | 9FB1B4A5165051DD0076BEB5 /* LBViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 9FB1B4A4165051DD0076BEB5 /* LBViewController.m */; }; 21 | 9FB1B4A8165051DD0076BEB5 /* LBViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 9FB1B4A6165051DD0076BEB5 /* LBViewController.xib */; }; 22 | 9FB1B4AF1650520A0076BEB5 /* example.png in Resources */ = {isa = PBXBuildFile; fileRef = 9FB1B4AE1650520A0076BEB5 /* example.png */; }; 23 | 9FB1B4B11650529B0076BEB5 /* CoreImage.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9FB1B4B01650529B0076BEB5 /* CoreImage.framework */; }; 24 | /* End PBXBuildFile section */ 25 | 26 | /* Begin PBXFileReference section */ 27 | 9F8DAB0816506119006C4EF3 /* UIImageView+LBBlurredImage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIImageView+LBBlurredImage.h"; sourceTree = ""; }; 28 | 9F8DAB0916506119006C4EF3 /* UIImageView+LBBlurredImage.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIImageView+LBBlurredImage.m"; sourceTree = ""; }; 29 | 9FB1B487165051DD0076BEB5 /* LBBlurredImage.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = LBBlurredImage.app; sourceTree = BUILT_PRODUCTS_DIR; }; 30 | 9FB1B48B165051DD0076BEB5 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 31 | 9FB1B48D165051DD0076BEB5 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 32 | 9FB1B48F165051DD0076BEB5 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 33 | 9FB1B493165051DD0076BEB5 /* LBBlurredImage-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "LBBlurredImage-Info.plist"; sourceTree = ""; }; 34 | 9FB1B495165051DD0076BEB5 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; 35 | 9FB1B497165051DD0076BEB5 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 36 | 9FB1B499165051DD0076BEB5 /* LBBlurredImage-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "LBBlurredImage-Prefix.pch"; sourceTree = ""; }; 37 | 9FB1B49A165051DD0076BEB5 /* LBAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = LBAppDelegate.h; sourceTree = ""; }; 38 | 9FB1B49B165051DD0076BEB5 /* LBAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = LBAppDelegate.m; sourceTree = ""; }; 39 | 9FB1B49D165051DD0076BEB5 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = ""; }; 40 | 9FB1B49F165051DD0076BEB5 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = ""; }; 41 | 9FB1B4A1165051DD0076BEB5 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = ""; }; 42 | 9FB1B4A3165051DD0076BEB5 /* LBViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = LBViewController.h; sourceTree = ""; }; 43 | 9FB1B4A4165051DD0076BEB5 /* LBViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = LBViewController.m; sourceTree = ""; }; 44 | 9FB1B4A7165051DD0076BEB5 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/LBViewController.xib; sourceTree = ""; }; 45 | 9FB1B4AE1650520A0076BEB5 /* example.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = example.png; sourceTree = ""; }; 46 | 9FB1B4B01650529B0076BEB5 /* CoreImage.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreImage.framework; path = System/Library/Frameworks/CoreImage.framework; sourceTree = SDKROOT; }; 47 | /* End PBXFileReference section */ 48 | 49 | /* Begin PBXFrameworksBuildPhase section */ 50 | 9FB1B484165051DD0076BEB5 /* Frameworks */ = { 51 | isa = PBXFrameworksBuildPhase; 52 | buildActionMask = 2147483647; 53 | files = ( 54 | 9FB1B4B11650529B0076BEB5 /* CoreImage.framework in Frameworks */, 55 | 9FB1B48C165051DD0076BEB5 /* UIKit.framework in Frameworks */, 56 | 9FB1B48E165051DD0076BEB5 /* Foundation.framework in Frameworks */, 57 | 9FB1B490165051DD0076BEB5 /* CoreGraphics.framework in Frameworks */, 58 | ); 59 | runOnlyForDeploymentPostprocessing = 0; 60 | }; 61 | /* End PBXFrameworksBuildPhase section */ 62 | 63 | /* Begin PBXGroup section */ 64 | 9F018C1E16516E0900AE2C47 /* Additions */ = { 65 | isa = PBXGroup; 66 | children = ( 67 | 9F8DAB0816506119006C4EF3 /* UIImageView+LBBlurredImage.h */, 68 | 9F8DAB0916506119006C4EF3 /* UIImageView+LBBlurredImage.m */, 69 | ); 70 | name = Additions; 71 | sourceTree = ""; 72 | }; 73 | 9FB1B47C165051DD0076BEB5 = { 74 | isa = PBXGroup; 75 | children = ( 76 | 9FB1B491165051DD0076BEB5 /* LBBlurredImage */, 77 | 9FB1B48A165051DD0076BEB5 /* Frameworks */, 78 | 9FB1B488165051DD0076BEB5 /* Products */, 79 | ); 80 | sourceTree = ""; 81 | }; 82 | 9FB1B488165051DD0076BEB5 /* Products */ = { 83 | isa = PBXGroup; 84 | children = ( 85 | 9FB1B487165051DD0076BEB5 /* LBBlurredImage.app */, 86 | ); 87 | name = Products; 88 | sourceTree = ""; 89 | }; 90 | 9FB1B48A165051DD0076BEB5 /* Frameworks */ = { 91 | isa = PBXGroup; 92 | children = ( 93 | 9FB1B4B01650529B0076BEB5 /* CoreImage.framework */, 94 | 9FB1B48B165051DD0076BEB5 /* UIKit.framework */, 95 | 9FB1B48D165051DD0076BEB5 /* Foundation.framework */, 96 | 9FB1B48F165051DD0076BEB5 /* CoreGraphics.framework */, 97 | ); 98 | name = Frameworks; 99 | sourceTree = ""; 100 | }; 101 | 9FB1B491165051DD0076BEB5 /* LBBlurredImage */ = { 102 | isa = PBXGroup; 103 | children = ( 104 | 9F018C1E16516E0900AE2C47 /* Additions */, 105 | 9FB1B4AE1650520A0076BEB5 /* example.png */, 106 | 9FB1B49A165051DD0076BEB5 /* LBAppDelegate.h */, 107 | 9FB1B49B165051DD0076BEB5 /* LBAppDelegate.m */, 108 | 9FB1B4A3165051DD0076BEB5 /* LBViewController.h */, 109 | 9FB1B4A4165051DD0076BEB5 /* LBViewController.m */, 110 | 9FB1B4A6165051DD0076BEB5 /* LBViewController.xib */, 111 | 9FB1B492165051DD0076BEB5 /* Supporting Files */, 112 | ); 113 | name = LBBlurredImage; 114 | path = LBBlurredImage; 115 | sourceTree = ""; 116 | }; 117 | 9FB1B492165051DD0076BEB5 /* Supporting Files */ = { 118 | isa = PBXGroup; 119 | children = ( 120 | 9FB1B493165051DD0076BEB5 /* LBBlurredImage-Info.plist */, 121 | 9FB1B494165051DD0076BEB5 /* InfoPlist.strings */, 122 | 9FB1B497165051DD0076BEB5 /* main.m */, 123 | 9FB1B499165051DD0076BEB5 /* LBBlurredImage-Prefix.pch */, 124 | 9FB1B49D165051DD0076BEB5 /* Default.png */, 125 | 9FB1B49F165051DD0076BEB5 /* Default@2x.png */, 126 | 9FB1B4A1165051DD0076BEB5 /* Default-568h@2x.png */, 127 | ); 128 | name = "Supporting Files"; 129 | sourceTree = ""; 130 | }; 131 | /* End PBXGroup section */ 132 | 133 | /* Begin PBXNativeTarget section */ 134 | 9FB1B486165051DD0076BEB5 /* LBBlurredImage */ = { 135 | isa = PBXNativeTarget; 136 | buildConfigurationList = 9FB1B4AB165051DD0076BEB5 /* Build configuration list for PBXNativeTarget "LBBlurredImage" */; 137 | buildPhases = ( 138 | 9FB1B483165051DD0076BEB5 /* Sources */, 139 | 9FB1B484165051DD0076BEB5 /* Frameworks */, 140 | 9FB1B485165051DD0076BEB5 /* Resources */, 141 | ); 142 | buildRules = ( 143 | ); 144 | dependencies = ( 145 | ); 146 | name = LBBlurredImage; 147 | productName = LBBlurredImage; 148 | productReference = 9FB1B487165051DD0076BEB5 /* LBBlurredImage.app */; 149 | productType = "com.apple.product-type.application"; 150 | }; 151 | /* End PBXNativeTarget section */ 152 | 153 | /* Begin PBXProject section */ 154 | 9FB1B47E165051DD0076BEB5 /* Project object */ = { 155 | isa = PBXProject; 156 | attributes = { 157 | CLASSPREFIX = LB; 158 | LastUpgradeCheck = 0450; 159 | ORGANIZATIONNAME = "Luca Bernardi"; 160 | }; 161 | buildConfigurationList = 9FB1B481165051DD0076BEB5 /* Build configuration list for PBXProject "LBBlurredImage" */; 162 | compatibilityVersion = "Xcode 3.2"; 163 | developmentRegion = English; 164 | hasScannedForEncodings = 0; 165 | knownRegions = ( 166 | en, 167 | ); 168 | mainGroup = 9FB1B47C165051DD0076BEB5; 169 | productRefGroup = 9FB1B488165051DD0076BEB5 /* Products */; 170 | projectDirPath = ""; 171 | projectRoot = ""; 172 | targets = ( 173 | 9FB1B486165051DD0076BEB5 /* LBBlurredImage */, 174 | ); 175 | }; 176 | /* End PBXProject section */ 177 | 178 | /* Begin PBXResourcesBuildPhase section */ 179 | 9FB1B485165051DD0076BEB5 /* Resources */ = { 180 | isa = PBXResourcesBuildPhase; 181 | buildActionMask = 2147483647; 182 | files = ( 183 | 9FB1B496165051DD0076BEB5 /* InfoPlist.strings in Resources */, 184 | 9FB1B49E165051DD0076BEB5 /* Default.png in Resources */, 185 | 9FB1B4A0165051DD0076BEB5 /* Default@2x.png in Resources */, 186 | 9FB1B4A2165051DD0076BEB5 /* Default-568h@2x.png in Resources */, 187 | 9FB1B4A8165051DD0076BEB5 /* LBViewController.xib in Resources */, 188 | 9FB1B4AF1650520A0076BEB5 /* example.png in Resources */, 189 | ); 190 | runOnlyForDeploymentPostprocessing = 0; 191 | }; 192 | /* End PBXResourcesBuildPhase section */ 193 | 194 | /* Begin PBXSourcesBuildPhase section */ 195 | 9FB1B483165051DD0076BEB5 /* Sources */ = { 196 | isa = PBXSourcesBuildPhase; 197 | buildActionMask = 2147483647; 198 | files = ( 199 | 9FB1B498165051DD0076BEB5 /* main.m in Sources */, 200 | 9FB1B49C165051DD0076BEB5 /* LBAppDelegate.m in Sources */, 201 | 9FB1B4A5165051DD0076BEB5 /* LBViewController.m in Sources */, 202 | 9F8DAB0A16506119006C4EF3 /* UIImageView+LBBlurredImage.m in Sources */, 203 | ); 204 | runOnlyForDeploymentPostprocessing = 0; 205 | }; 206 | /* End PBXSourcesBuildPhase section */ 207 | 208 | /* Begin PBXVariantGroup section */ 209 | 9FB1B494165051DD0076BEB5 /* InfoPlist.strings */ = { 210 | isa = PBXVariantGroup; 211 | children = ( 212 | 9FB1B495165051DD0076BEB5 /* en */, 213 | ); 214 | name = InfoPlist.strings; 215 | sourceTree = ""; 216 | }; 217 | 9FB1B4A6165051DD0076BEB5 /* LBViewController.xib */ = { 218 | isa = PBXVariantGroup; 219 | children = ( 220 | 9FB1B4A7165051DD0076BEB5 /* en */, 221 | ); 222 | name = LBViewController.xib; 223 | sourceTree = ""; 224 | }; 225 | /* End PBXVariantGroup section */ 226 | 227 | /* Begin XCBuildConfiguration section */ 228 | 9FB1B4A9165051DD0076BEB5 /* Debug */ = { 229 | isa = XCBuildConfiguration; 230 | buildSettings = { 231 | ALWAYS_SEARCH_USER_PATHS = NO; 232 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 233 | CLANG_CXX_LIBRARY = "libc++"; 234 | CLANG_ENABLE_OBJC_ARC = YES; 235 | CLANG_WARN_EMPTY_BODY = YES; 236 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 237 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 238 | COPY_PHASE_STRIP = NO; 239 | GCC_C_LANGUAGE_STANDARD = gnu99; 240 | GCC_DYNAMIC_NO_PIC = NO; 241 | GCC_OPTIMIZATION_LEVEL = 0; 242 | GCC_PREPROCESSOR_DEFINITIONS = ( 243 | "DEBUG=1", 244 | "$(inherited)", 245 | ); 246 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 247 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 248 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 249 | GCC_WARN_UNUSED_VARIABLE = YES; 250 | IPHONEOS_DEPLOYMENT_TARGET = 6.0; 251 | ONLY_ACTIVE_ARCH = YES; 252 | SDKROOT = iphoneos; 253 | }; 254 | name = Debug; 255 | }; 256 | 9FB1B4AA165051DD0076BEB5 /* Release */ = { 257 | isa = XCBuildConfiguration; 258 | buildSettings = { 259 | ALWAYS_SEARCH_USER_PATHS = NO; 260 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 261 | CLANG_CXX_LIBRARY = "libc++"; 262 | CLANG_ENABLE_OBJC_ARC = YES; 263 | CLANG_WARN_EMPTY_BODY = YES; 264 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 265 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 266 | COPY_PHASE_STRIP = YES; 267 | GCC_C_LANGUAGE_STANDARD = gnu99; 268 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 269 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 270 | GCC_WARN_UNUSED_VARIABLE = YES; 271 | IPHONEOS_DEPLOYMENT_TARGET = 6.0; 272 | OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1"; 273 | SDKROOT = iphoneos; 274 | VALIDATE_PRODUCT = YES; 275 | }; 276 | name = Release; 277 | }; 278 | 9FB1B4AC165051DD0076BEB5 /* Debug */ = { 279 | isa = XCBuildConfiguration; 280 | buildSettings = { 281 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer: Luca Bernardi (6V2Q7N95B2)"; 282 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 283 | GCC_PREFIX_HEADER = "LBBlurredImage/LBBlurredImage-Prefix.pch"; 284 | INFOPLIST_FILE = "LBBlurredImage/LBBlurredImage-Info.plist"; 285 | PRODUCT_NAME = LBBlurredImage; 286 | "PROVISIONING_PROFILE[sdk=iphoneos*]" = "7A51DF00-66E9-4154-B6C9-8D25E278D3F4"; 287 | WRAPPER_EXTENSION = app; 288 | }; 289 | name = Debug; 290 | }; 291 | 9FB1B4AD165051DD0076BEB5 /* Release */ = { 292 | isa = XCBuildConfiguration; 293 | buildSettings = { 294 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 295 | GCC_PREFIX_HEADER = "LBBlurredImage/LBBlurredImage-Prefix.pch"; 296 | INFOPLIST_FILE = "LBBlurredImage/LBBlurredImage-Info.plist"; 297 | PRODUCT_NAME = LBBlurredImage; 298 | WRAPPER_EXTENSION = app; 299 | }; 300 | name = Release; 301 | }; 302 | /* End XCBuildConfiguration section */ 303 | 304 | /* Begin XCConfigurationList section */ 305 | 9FB1B481165051DD0076BEB5 /* Build configuration list for PBXProject "LBBlurredImage" */ = { 306 | isa = XCConfigurationList; 307 | buildConfigurations = ( 308 | 9FB1B4A9165051DD0076BEB5 /* Debug */, 309 | 9FB1B4AA165051DD0076BEB5 /* Release */, 310 | ); 311 | defaultConfigurationIsVisible = 0; 312 | defaultConfigurationName = Release; 313 | }; 314 | 9FB1B4AB165051DD0076BEB5 /* Build configuration list for PBXNativeTarget "LBBlurredImage" */ = { 315 | isa = XCConfigurationList; 316 | buildConfigurations = ( 317 | 9FB1B4AC165051DD0076BEB5 /* Debug */, 318 | 9FB1B4AD165051DD0076BEB5 /* Release */, 319 | ); 320 | defaultConfigurationIsVisible = 0; 321 | defaultConfigurationName = Release; 322 | }; 323 | /* End XCConfigurationList section */ 324 | }; 325 | rootObject = 9FB1B47E165051DD0076BEB5 /* Project object */; 326 | } 327 | -------------------------------------------------------------------------------- /LBBlurredImage/en.lproj/LBViewController.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 1536 5 | 12C3006 6 | 2844 7 | 1187.34 8 | 625.00 9 | 10 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 11 | 1930 12 | 13 | 14 | IBNSLayoutConstraint 15 | IBProxyObject 16 | IBUIImageView 17 | IBUILabel 18 | IBUIView 19 | 20 | 21 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 22 | 23 | 24 | PluginDependencyRecalculationVersion 25 | 26 | 27 | 28 | 29 | IBFilesOwner 30 | IBCocoaTouchFramework 31 | 32 | 33 | IBFirstResponder 34 | IBCocoaTouchFramework 35 | 36 | 37 | 38 | 274 39 | 40 | 41 | 42 | 274 43 | {320, 548} 44 | 45 | 46 | 47 | _NS:9 48 | NO 49 | IBCocoaTouchFramework 50 | 51 | 52 | 53 | 292 54 | {{67, 62}, {187, 58}} 55 | 56 | 57 | 58 | _NS:9 59 | NO 60 | YES 61 | 7 62 | NO 63 | IBCocoaTouchFramework 64 | LBBlurredImage 65 | 66 | 3 67 | MQA 68 | 69 | 70 | 71 | 3 72 | MAA 73 | 74 | {1, 1} 75 | 0 76 | 1 77 | 78 | 2 79 | 23 80 | 81 | 82 | Helvetica-Bold 83 | 23 84 | 16 85 | 86 | NO 87 | 88 | 89 | {{0, 20}, {320, 548}} 90 | 91 | 92 | 93 | 94 | 3 95 | MC43NQA 96 | 97 | 2 98 | 99 | 100 | NO 101 | 102 | 103 | IBUIScreenMetrics 104 | 105 | YES 106 | 107 | 108 | 109 | 110 | 111 | {320, 568} 112 | {568, 320} 113 | 114 | 115 | IBCocoaTouchFramework 116 | Retina 4 Full Screen 117 | 2 118 | 119 | IBCocoaTouchFramework 120 | 121 | 122 | 123 | 124 | 125 | 126 | view 127 | 128 | 129 | 130 | 7 131 | 132 | 133 | 134 | imageView 135 | 136 | 137 | 138 | 13 139 | 140 | 141 | 142 | 143 | 144 | 0 145 | 146 | 147 | 148 | 149 | 150 | -1 151 | 152 | 153 | File's Owner 154 | 155 | 156 | -2 157 | 158 | 159 | 160 | 161 | 6 162 | 163 | 164 | 165 | 166 | 167 | 3 168 | 0 169 | 170 | 3 171 | 1 172 | 173 | 62 174 | 175 | 1000 176 | 177 | 3 178 | 9 179 | 3 180 | 181 | 182 | 183 | 9 184 | 0 185 | 186 | 9 187 | 1 188 | 189 | 0.0 190 | 191 | 1000 192 | 193 | 6 194 | 24 195 | 2 196 | 197 | 198 | 199 | 6 200 | 0 201 | 202 | 6 203 | 1 204 | 205 | 0.0 206 | 207 | 1000 208 | 209 | 8 210 | 29 211 | 3 212 | 213 | 214 | 215 | 5 216 | 0 217 | 218 | 5 219 | 1 220 | 221 | 0.0 222 | 223 | 1000 224 | 225 | 8 226 | 29 227 | 3 228 | 229 | 230 | 231 | 3 232 | 0 233 | 234 | 3 235 | 1 236 | 237 | 0.0 238 | 239 | 1000 240 | 241 | 8 242 | 29 243 | 3 244 | 245 | 246 | 247 | 4 248 | 0 249 | 250 | 4 251 | 1 252 | 253 | 0.0 254 | 255 | 1000 256 | 257 | 8 258 | 29 259 | 3 260 | 261 | 262 | 263 | 264 | 265 | 266 | 8 267 | 268 | 269 | 270 | 271 | 9 272 | 273 | 274 | 275 | 276 | 10 277 | 278 | 279 | 280 | 281 | 11 282 | 283 | 284 | 285 | 286 | 12 287 | 288 | 289 | 290 | 291 | 19 292 | 293 | 294 | 295 | 296 | 7 297 | 0 298 | 299 | 0 300 | 1 301 | 302 | 187 303 | 304 | 1000 305 | 306 | 3 307 | 9 308 | 1 309 | 310 | 311 | 312 | 8 313 | 0 314 | 315 | 0 316 | 1 317 | 318 | 58 319 | 320 | 1000 321 | 322 | 3 323 | 9 324 | 1 325 | 326 | 327 | 328 | 329 | 330 | 24 331 | 332 | 333 | 334 | 335 | 25 336 | 337 | 338 | 339 | 340 | 27 341 | 342 | 343 | 344 | 345 | 28 346 | 347 | 348 | 349 | 350 | 351 | 352 | LBViewController 353 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 354 | UIResponder 355 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 356 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 357 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 358 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 359 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 360 | 361 | 362 | 363 | 364 | 365 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 366 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 367 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 368 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 369 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 370 | 371 | 372 | 373 | 374 | 375 | 376 | 377 | 378 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 379 | 380 | com.apple.InterfaceBuilder.IBCocoaTouchPlugin 381 | 382 | 383 | 384 | 385 | 386 | 28 387 | 388 | 389 | 390 | 391 | LBViewController 392 | UIViewController 393 | 394 | filterButtonTapped: 395 | id 396 | 397 | 398 | filterButtonTapped: 399 | 400 | filterButtonTapped: 401 | id 402 | 403 | 404 | 405 | imageView 406 | UIImageView 407 | 408 | 409 | imageView 410 | 411 | imageView 412 | UIImageView 413 | 414 | 415 | 416 | IBProjectSource 417 | ./Classes/LBViewController.h 418 | 419 | 420 | 421 | NSLayoutConstraint 422 | NSObject 423 | 424 | IBProjectSource 425 | ./Classes/NSLayoutConstraint.h 426 | 427 | 428 | 429 | 430 | 0 431 | IBCocoaTouchFramework 432 | YES 433 | 3 434 | YES 435 | 1930 436 | 437 | 438 | --------------------------------------------------------------------------------