Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ios/120.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/xcode/7.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ios Xcode接口生成器中的图像资源大小_Ios_Xcode_Image_Resolution - Fatal编程技术网

Ios Xcode接口生成器中的图像资源大小

Ios Xcode接口生成器中的图像资源大小,ios,xcode,image,resolution,Ios,Xcode,Image,Resolution,如果我在Xcode中的interface builder中添加了一个图像视图,它的大小为200 x 100(Xcode中的大小),那么我如何知道为1x 2x和3x创建图像资源的大小 如果我在photoshop中将3x设置为600x300像素,然后尝试使用此图像,它在iPhone 7 plus上看起来不太清晰,那么如何知道给定图像视图大小的图像资源的分辨率 如果我在Xcode中的interface builder中添加了一个图像视图,它的大小为200 x 100(Xcode中的大小),那么我如何知

如果我在Xcode中的interface builder中添加了一个图像视图,它的大小为200 x 100(Xcode中的大小),那么我如何知道为1x 2x和3x创建图像资源的大小

如果我在photoshop中将3x设置为600x300像素,然后尝试使用此图像,它在iPhone 7 plus上看起来不太清晰,那么如何知道给定图像视图大小的图像资源的分辨率

如果我在Xcode中的interface builder中添加了一个图像视图,它的大小为200 x 100(Xcode中的大小),那么我如何知道为1x 2x和3x创建图像资源的大小

分辨率是点和像素之间的对应关系。如果所需的图像大小为200x100点,则应提供以下三种图像大小:

  • 1x:200x100像素
  • 2x:400x200像素
  • 3x:600x300像素
例如,如果我们在2x分辨率的设备上运行,图像将加载,其
比例设置为2,这样2个像素将对应于1个点

请注意,您不应试图通过简单地放大1x图像来制作3x图像。这显然看起来很糟糕。您应该从600x300原版开始,缩小比例以获得2x和1x图像

如果我在Xcode中的interface builder中添加了一个图像视图,它的大小为200 x 100(Xcode中的大小),那么我如何知道为1x 2x和3x创建图像资源的大小

分辨率是点和像素之间的对应关系。如果所需的图像大小为200x100点,则应提供以下三种图像大小:

  • 1x:200x100像素
  • 2x:400x200像素
  • 3x:600x300像素
例如,如果我们在2x分辨率的设备上运行,图像将加载,其
比例设置为2,这样2个像素将对应于1个点

请注意,您不应试图通过简单地放大1x图像来制作3x图像。这显然看起来很糟糕。您应该从600x300原版开始,缩小比例以获得2x和1x图像