忘了放常规图像,但它有Retina @ 2x图像 [英] forgot to put regular image but it has Retina @2x image

查看:167
本文介绍了忘了放常规图像,但它有Retina @ 2x图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经提交了我的应用程序,它支持常规和视网膜显示版本。



我忘了放一个常规图像文件(a.png)但它有( a@2x.png)Retina图片。

是否普通iPhone能够显示(a@2x.png)图像?



<我没有任何线索,因为我没有3GS或iPod Touch,但在iPhone常规模拟器上出来显示图像。



有经验吗?



谢谢。

解决方案

当iOS加载图片时,它会检查正确图像的文件名



ie。在视网膜显示设备上,它将检查 imageName + @ 2x + .png 。如果找到它,它将加载它。如果没有,它将加载非视网膜图像并进行缩放。



在非视网膜显示设备上,系统不会检查在文件名中@ 2x ,因此它只会尝试加载 imageName.png - 如果找不到它,则无法加载它没有显示任何内容。



我建议你拉二进制并更新它。


I have submitted my app which support both regular and retina display edition.

I forgot to put one of regular image file (a.png) but it has (a@2x.png) Retina image.
Is it going to be regular iPhone able to show (a@2x.png) image or not?

I have no clue since I don't have 3GS or iPod Touch, but on iPhone regular simulator came out to be show that image.

Any experience?

Thank You.

解决方案

When iOS loads an image it will check the file name for the correct image

ie. on a retina display device, it will check for imageName + @2x + .png. If it finds it, it will load it. If not, it will load the non-retina image and scale it.

On a non-retina display device the system will not check for the @2x in the filename, therefore it will just try to load imageName.png - if it can't find it, it can't load it, and nothing will display.

I would suggest pulling your binary and updating it.

这篇关于忘了放常规图像,但它有Retina @ 2x图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆