ios - 以缩放模式运行的 iOS 8 应用程序是否使用 @3x 图像?

标签 ios iphone iphone-6 iphone-6-plus

如果我有一个使用 Xcode 6 构建的 iOS 8 iPhone 应用程序,它不为 iPhone 6/6+ 提供启动图像,但我提供了@3x 图像,那么在以缩放模式显示应用程序时,iPhone 6+ 是否仍会使用这些资源?

例如,我有 someImage.png , someImage@2x.png , 和 someImage@3x.png并像这样加载图像:

UIImage* image = [UIImage imageWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"someImage" ofType:@"png"]];

我没有 iPhone 6+ 设备来对此进行测试,iOS 8 模拟器出于某种奇怪的原因最终对所有设备使用@3x 图像,正如其他人指出的 here .

最佳答案

当前版本的 Xcode (6.3.2) 中的 iPhone 6+ 模拟器在缩放模式下运行时确实使用 @3x 版本的图像,而其他模拟器仅使用 @2x 和 @1x 图像。

来自 PaintCode 开发人员的本指南:http://www.paintcodeapp.com/news/ultimate-guide-to-iphone-resolutions
还建议 iPhone 6+ 将在缩放之前使用@3x 图像。

虽然我没有 iPhone 6+ 来测试它在实际设备上的行为是否相同。

关于ios - 以缩放模式运行的 iOS 8 应用程序是否使用 @3x 图像?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26208657/

相关文章:

ios - 用户滑动时 TableView 单元格突出显示

ios - 是否可以在 AKAudioPlayer 上使用 AKAmplitudeTracker 并测量振幅变化?

ios - 更改 UITableView 框架时奇怪的 UITableViewCell 动画

iphone - 在核心动画或核心图形上创建简单的橡皮擦效果有多难?

ios-创建多窗口应用程序

ios - iPhone 6/6+ 优化问题

ios - Cordova CLI 4.0 : how to install master/nightly version of cordova-ios?

ios - 我如何判断 Springs 和 Struts 应用程序是否在 iPhone 6 模拟器中缩放?

ios - UINavigationBar 标题不水平居中

ios - 如何从这个 [value isKindOfClass :[NSError class]]? 转换为 NSError