/* create path to cache directory inside the application's Documents directory */
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
NSString *filePath = [[paths objectAtIndex: 0] stringByAppendingPathComponent: @"output.jpg"];
NSData *photoData = UIImageJPEGRepresentation(dstImg, 1);
[photoData writeToFile:filePath atomically: YES];
沒有留言:
張貼留言