I'm trying to setup a correct background for my IOS app. I'm using Xcode 7, with Swift 2.0
According to this post, the user has the option to choose Device Specific image sets like so:
In xcode 7, it looks like I'm missing a few functionalities:
Now this is part of my issue, because my background looks good on every device, expect for the 4s.
The pixel width and heights I have used:
- 320x480 -> 1x (won't be used anyway because IOS minimum is above 8.3
- 750x1334 -> 2x
- 1242x2208 -> 3x
For these widths and heights, I followed this overview.
Now this is the result I get on the 4s, where the red color is the background.
As you see some white space at the left and right.
I've set the UIImageView to Aspect Fit, the constraints are Equel width and height to superview, and center X and Y to superview.
Now you might think: Why not use Aspect Fill? Because it is an image where it is kind of important to see the top and bottom of it, and Aspect Fill will also zoom in a bit (I believe) which decreases quality. Scale to fit obviously stretches the image.
Best solution would be to specify per device, because 2x is used for 4s and 6. While the background is fine on the 6, not on the 4s.
Thankyou!