I\'m working on an iOS app. It currently only works on iOS 4 since I use the following method on several occasions: \"UIGraphicsBeginImageContextWithOptions\". This method i
I know this is an old question, but with new Xcode and iOS versions (upper than 9) any of this methods work for me.
I always check the system version in this way:
NSString *sysver = [[UIDevice currentDevice] systemVersion];
NSArray *versionNums = [sysver componentsSeparatedByString:@"."];
int majorVersion = [versionNums[0] intValue];
if (majorVersion > 3){
UIGraphicsBeginImageContextWithOptions(...);
}
else{
UIGraphicsBeginImageContext(...);
}
I hope this could help anyone.