Reputation: 4390
I'm using the following code to animate my company logo in the app main screen:
NSArray *array = [[NSArray alloc] initWithObjects:
[UIImage imageNamed:@"logo_001.png"],
[UIImage imageNamed:@"logo_002.png"],
[UIImage imageNamed:@"logo_003.png"],
nil];
self.imageViewLogo.image = [array lastObject];
self.imageViewLogo.animationImages = array;
self.imageViewLogo.animationDuration = 1;
self.imageViewLogo.animationRepeatCount = 1;
[self.imageViewLogo startAnimating];
How should I deal with the retina @2x images in this case?
Upvotes: 0
Views: 242
Reputation: 25392
If you have retina images:
[email protected]
[email protected]
[email protected]
You don't need to do anything. [UIImage imageNamed:]
will return the original image for non-retina devices and the 2x image for retina devices.
Upvotes: 1