简体   繁体   English

Xcode 2x,3x图像缩放不起作用?

[英]Xcode image scaling for 2x,3x not working?

I have an image called shareIdea. 我有一个名为shareIdea的图像。 I created @2x, @3x and named them shareIdea@2x and shareIdea@3x. 我创建了@ 2x,@ 3x并将其命名为shareIdea @ 2x和shareIdea @ 3x。 I have added them to xcode as you can see in the image here: 我已将它们添加到xcode中,如您在此处的图像中所见:

这里

However when I compile and run. 但是,当我编译并运行时。 The images used along my toolbar are still the 22px. 我的工具栏上使用的图像仍然是22px。 So I'm unsure what to do or how to fix it. 所以我不确定该怎么做或如何解决它。

In each device you have a image proportion that the SO will request, they will use the "maximum" available for each one. 在每个设备中,SO都会请求图像比例,它们将使用每个设备可用的“最大”比例。

  • 4, 4s, 5, 5s and6 (Max @2x) 4,4s,5,5s和6(最大@ 2x)
  • 6 plus (Max @3x ) 6加(最大@ 3x)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM