[objective-c]UIImageの作り方
UIImageの作り方
NSString*fn=@"image.png"; UIImage*image1=[UIImage imageNamed:fn]; UIImage*image2=[UIImage imageWithContentsOfFile:[NSString stringWithFormat:@"%@/%@",[[NSBundle mainBundle] bundlePath],fn]]; NSURL*url=[NSURL URLWithString:@"http://yourdomain/image.png"]; NSData*data=[NSData dataWithContentsOfURL:url]; UIImage*image3=[UIImage imageWithData:data];