关闭

支持新iPad高清屏的图片命名规则

1764人阅读 评论(1) 收藏 举报
刚查了Apple的文档,图片的命名规则如下即可:

Devices with out retina:
ImageName.png - For iPhone/iPod
ImageName~ipad.png -- For iPad

Devices with retina display:
ImageName@2x~ipad.png -- For iPad
ImageName@2x.png - For iPhone/iPod


Applications running in iOS 4 should now include two separate files for each image resource. One file provides a standard-resolution version of a given image, and the second provides a high-resolution version of the same image. The naming conventions for each pair of image files is as follows:
    Standard: <ImageName><device_modifier>.<filename_extension>
    High resolution: <ImageName>@2x<device_modifier>.<filename_extension>
The <ImageName> and <filename_extension> portions of each name specify the usual name and extension for the file. The <device_modifier>portion is optional and contains either the string ~ipad or ~iphone. You include one of these modifiers when you want to specify different versions of an image for iPad and iPhone. The inclusion of the @2x modifier for the high-resolution image is new and lets the system know that the image is the high-resolution variant of the standard image.
Important When creating high-resolution versions of your images, place the new versions in the same location in your application bundle as the original.
0
0

查看评论
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场
    个人资料
    • 访问:772727次
    • 积分:7217
    • 等级:
    • 排名:第3089名
    • 原创:36篇
    • 转载:387篇
    • 译文:0篇
    • 评论:53条
    其它
    壶天的语像 http://blog.sina.com.cn/wallydai zcmky的家 http://www.cnblogs.com/zcmky/archive/2010/04/02/1703397.html pjk1129专栏:http://blog.csdn.net/pjk1129/article/details/6593264 OpenGL ES学习网址 http://ityran.com/portal.php?mod=list&catid=1 雨松MOMO的程序世界专栏:http://blog.csdn.net/xys289187120/article/list/1 Techotopia:http://www.techotopia.com/index.php/Preparing_an_iOS_5_iPhone_App_to_use_iCloud_Storage 易飞扬:http://www.yifeiyang.net/ 禚 的iphone开发专栏:http://blog.csdn.net/diyagoanyhacker/article/category/846338 Marshal's Blog:http://marshal.easymorse.com/page/2 XML解析:http://www.raywenderlich.com/725/how-to-read-and-write-xml-documents-with-gdataxml http :http://www.dreamingwish.com/dream-2011/powerful-asihttprequest-library-c.html
    最新评论