(Created page with "{{Infobox Package |developer=Ryan Petrich |version=1.0 |package=com.rpetrich.layersnapshotter }} Adds APIs to snapshot UIViews and CALayers. == LayerSnapshotter Header == <s...") |
No edit summary |
||
(2 intermediate revisions by one other user not shown) | |||
Line 5: | Line 5: | ||
}} | }} | ||
'''LayerSnapshotter ''' adds APIs to snapshot UIViews and CALayers. | |||
== LayerSnapshotter Header == | == LayerSnapshotter Header == | ||
Line 29: | Line 29: | ||
UIView *newView = [[UIView alloc] initWithFrame:CGRectMake(0,0,320,480)]; | UIView *newView = [[UIView alloc] initWithFrame:CGRectMake(0,0,320,480)]; | ||
UIImage *imageOfView = [newView renderSnapshot]; | UIImage *imageOfView = [newView renderSnapshot]; | ||
</source> | </source> | ||
== References == | == References == | ||
Line 37: | Line 37: | ||
{{Navbox Library}} | {{Navbox Library}} | ||
[[Category:/usr/lib]] |
Latest revision as of 06:41, 21 January 2014
LayerSnapshotter | |
Cydia Package | |
---|---|
Developer | Ryan Petrich |
Package ID | com.rpetrich.layersnapshotter |
Latest Version | 1.0 |
LayerSnapshotter adds APIs to snapshot UIViews and CALayers.
LayerSnapshotter Header
#import <UIKit/UIKit.h>
#import <QuartzCore/QuartzCore.h>
@interface CALayer (Snapshot)
- (UIImage *)renderSnapshotWithScale:(CGFloat)scale;
@end
@interface UIView (Snapshot)
- (UIImage *)renderSnapshot;
@end
@interface UIImage (Saving)
- (BOOL)writeToFile:(NSString *)path atomically:(BOOL)atomically;
@end
Example Use
UIView *newView = [[UIView alloc] initWithFrame:CGRectMake(0,0,320,480)];
UIImage *imageOfView = [newView renderSnapshot];
References
ModMyI Package Info for LayerSnapShotter
rpetrich Slide from WWJC 2013
|