我使用了一张640x1136的图片作为我的应用程序的背景,但是图片看起来已经放大了。正确显示与启动画面相同的图像。我跟着找到here的方向走。两张照片,
原图:

屏幕截图,模拟器iPhone 6.1,外观与我的iPhone 5相同

我使用的代码如下:
CGRect screenSize = [[UIScreen mainScreen]bounds];
if (screenSize.size.height == 568.0f) {
self.view.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"Default-568h@2x"]];
}else {
self.view.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"Default@2x"]];
}发布于 2013-05-28 18:02:34
在应用程序的底部有You栏。因此,您需要使用不同图像闪屏和背景屏幕的Inicio选项卡。
发布于 2013-05-28 18:04:11
您正在使用ratina图像(后缀为@2x)并签入NonRetina模拟器。因此选择使用iphone模拟器属性的基于Retina的模拟器
Hardware -> Device -> iPhone(Retina 4-inch)然后运行app。
希望能对你有所帮助。
https://stackoverflow.com/questions/16789175
复制相似问题