Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/image/5.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
Image Atlas未加载@3x图像_Image_Swift_Sprite Kit_Textures_Atlas - Fatal编程技术网

Image Atlas未加载@3x图像

Image Atlas未加载@3x图像,image,swift,sprite-kit,textures,atlas,Image,Swift,Sprite Kit,Textures,Atlas,在iphone6 plus上使用模拟器时,从atlas加载的图像在@2x~ iphone上加载,而不是在@3x~ iphone上加载。当我加载一个图像(不使用atlas)时,@3x~ iphone可以工作 我正在使用一个atlas,其中包含@2x~ iphone和@3x~ iphone图像(仅加载@2x~ iphone图像)。我在网上读到将atlas文件夹名称更改为@2x.atlas和@3x.atlas,但是出现了一个错误,说它找不到文件夹。我还将文件名更改为@2x~iphone.atlas和@

在iphone6 plus上使用模拟器时,从atlas加载的图像在@2x~ iphone上加载,而不是在@3x~ iphone上加载。当我加载一个图像(不使用atlas)时,@3x~ iphone可以工作

我正在使用一个atlas,其中包含@2x~ iphone和@3x~ iphone图像(仅加载@2x~ iphone图像)。我在网上读到将atlas文件夹名称更改为@2x.atlas和@3x.atlas,但是出现了一个错误,说它找不到文件夹。我还将文件名更改为@2x~iphone.atlas和@3x~iphone.atlas,但得到了相同的错误

这就是我用来将图像加载到数组的方法

func build_ArrayTextureSegment() {

    for var i = 0; i <= 12; i++ {
        let texture:SKTexture = SKTextureAtlas(named: "Segments").textureNamed("\(i)")
        arrayTextureSegments.append(texture)
    }

}
func build\u ArrayTextureSegment(){

对于var i=0;i,这是一个已知的地图集错误。我自己也尝试过一些方法,但没有成功:@Jarron你使用什么iOS&Xcode?我会很快阅读你提供的链接。Xcode是6.4,simulator是8.4。我没有iphone6 plus来测试应用程序。你会在评论中看到(第一个链接)即使你使用实际的设备,也会发生同样的情况。@Jaron你的意思是在这个错误修复后它是否会工作?理论上是的,但谁知道呢…我只会使用2张图像(如果需要使用atlas的话)因为这是你可以测试的,并且知道它肯定会工作。当修复程序到来时,你可以添加3x图像支持,测试一切,更新游戏等。但这只是我。感谢Whirlwind的输入,我将使用2x图像,直到我听说3x正常工作。你提供的一个链接可以追溯到1月份。这是surpris他说苹果还没有解决这个问题。