This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (UIImage *)rxScalePropertionallyToMaximumSize:(CGSize)maxSize blendMode:(CGBlendMode)blendMode alpha:(CGFloat)alpha scale:(CGFloat)scale { | |
if ((maxSize.width < 1.0e-15) || (maxSize.height < 1.0e-15)) return nil; | |
CGSize imageSize = self.size; | |
CGSize scaleFactors = { | |
.width = maxSize.width / imageSize.width, | |
.height = maxSize.height / imageSize.height, | |
}; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import <Foundation/Foundation.h> | |
@interface NSURL (Pieces) | |
-(NSDictionary *)piecesDictionary; | |
@end |