-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathUIImage+Additions.h
26 lines (22 loc) · 1.02 KB
/
UIImage+Additions.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
//
// UIImage+Additions.h
//
// Created by Wess Cope on 2/11/11.
// Copyright 2012. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface UIImage(Additions)
+ (UIImage *)scaleImage:(UIImage *)incomingImage ToWidth:(CGFloat)width;
+ (UIImage *)scaleImage:(UIImage *)incomingImage ToHeight:(CGFloat)height;
+ (UIImage *)scaleToSize:(UIImage *)incomingImage targetSize:(CGSize)targetSize;
+ (UIImage *)resizeImage:(UIImage *)image ToSize:(CGSize)size;
+ (UIImage *)cropImage:(UIImage *)img toInset:(CGFloat)inset;
+ (UIImage *)cropImage:(UIImage *)img toSize:(CGSize)size;
+ (UIImage *)cropImage:(UIImage *)img toSize:(CGSize)size atPoint:(CGPoint)point;
+ (UIImage *)ratioScale:(UIImage *)image toRect:(CGRect)frame fromSize:(CGSize)size;
+ (UIImage *)fillImage:(UIImage *)image withColor:(UIColor *)color;
+ (UIImage *)imageFromURL:(NSString *)urlString;
- (UIImage *)resizeTo:(CGSize)targetSize;
- (UIImage *)fillImageWithColor:(UIColor *)color;
+ (UIImage *)imageNamed:(NSString *)name withShadowColor:(UIColor *)color;
@end