I'm trying to add a background image to the NavigationBar of an UINavigationBarController
[viewController.navigationBar setBackgroundImage:[UIImage imageNamed:@"NavBarBackground"] forBarMetrics:UIBarMetricsDefault];
In my assets I have a
- NavBarBackground.png,
- [email protected],
- [email protected]
Apple documentation says about resolutions :
- iPhone 5/5c/5s/6 @x2 (retina)
- iPhone 6+ @x3 (retina HD)
BUT
- iPhone 5(&co) have a screen width of 640px
- iPhone 6 have a screen width of 750px
How can I handle iPhone 6 case without having another image that I'll need to named with extension in my setBackgroundImage method only for iPhone 6 ?