/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/texturetool -e PVRTC --bits-per-pixel-2 -o left.pvrtc left.jpg Failed to load image Failed to perform Encode解决方法 更改:
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/texturetool -e PVRTC --bits-per-pixel-2 -o left.pvrtc left.jpg
至:
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/texturetool -e PVRTC --bits-per-pixel-2 -o left.pvr left.PNG
该文件必须是PNG
更新了OSX 10.10的说明
在终端中,点击cd以确保您在根目录中.
cd /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ && ls
这应该显示那里所有工具的列表(确保你看到texturetool) – 如果你没有,更新你的 *** 作系统,然后Xcode
一旦你知道它在那里,cd回到你的root并运行工具,如:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/texturetool -e PVRTC –bits-per-pixel-2 -f PVR -o [pvr去的新路径] [原来的路径]
您的输出pvr路径可以是〜/ whatever / image.pvr,输入png是要转换的图像的路径.
HERE和HERE是其他很好的演练
The
iPhone SDK
includes a tool that allows you to create textures in the PVRTC compression format,aptly namedtexturetool
. If you have Xcode installed with the iPhone OS 2.2 SDK in the default location (/Developer/Platforms/),thentexturetool
is located at:/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/texturetool
.
texturetool
allows you to create four variants ofPVRTC
data,the primary difference being tradeoffs between quality and size. You will have to experiment with these variants to determine which setting is the best compromise for each indivIDual texture image.
> Apple Docs
HERE是一些相同的代码,一旦你有了你的pvrtc文件就可以提供帮助
HERE是一些更多的文档
HERE是关于PVRTC的好东西
总结以上是内存溢出为你收集整理的ios – 如何将图像转换为PVRTC格式全部内容,希望文章能够帮你解决ios – 如何将图像转换为PVRTC格式所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)