iOS 5 - 有时 GIF 动画显示颜色错误
我在我们的移动网站上使用一些 GIF 动画。这是一个时钟动画,自从 iOS 5 更新以来,有时时钟会像计划的那样变成蓝色而不是红色。发生在使用新操作系统的 iPhone4 和 iPhone5 上。
有什么想法可能会导致问题吗?很难重建这种故障,但这种情况时有发生。
任何帮助将不胜感激。
I'm using some animated gifs on our mobile-site. It's a clock-animation and since the iOS 5 update it sometimes happens that the clock gets blue instead of red, as planned. Happens on iPhone4 and iPhone5 with the new os.
Any ideas what could cause the problems? It's hard to reconstruct this failure but it happens from time to time.
Any help would be appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
有时,iOS 设备可能无法处理所有图像,因为与计算机相比,其图形能力相对较低。我建议使用动画 PNG,而不是使用 GIF。这在 ios 设备中更受欢迎,因为在使用 ios 设备时使用 GIF 已经过时了。我不确定这有多快,但我想说它比 gif 施加的压力更小。另一个想法是,因为它是一个时钟 gif,所以可以在程序中分析 gif 并确定任何问题。还可以使用 imgoptim(适用于 Mac)或 pngcrush(适用于 Windows)来减小 gif 的大小,以减轻处理器的压力。
Sometimes ios devices may not be able to process all the images because of its relatively low graphics ability compared to that of a computer. Instead of using a GIF I would suggest using an animated PNG. This has been more popular among the ios devices as using GIFs has become obsolete when working with ios devices. I am not sure how fast this would be, but I would say it can apply less stress then that of a gif. Another idea, because it is a clock gif is to analyze the gif in a program and determine any problems. Also use imgoptim (for mac) or pngcrush for windows to reduce the size of the gif to reduce the stress on the processor.
使用 GIF 128 抖动,并请确保图像大小必须基于分辨率,如果您的图像大小不依赖于视网膜或正常分辨率,有时会发生这种情况。如果我没记错的话,您仅在视网膜设备中遇到问题,下面的详细信息可能会对
iPhone 视网膜显示屏 有所帮助
~~~~~~~~~~~~~~~~~~~~~~~~
宽度 - 640 像素
高度 - 960px:包括 40px 状态栏
分辨率-326
use GIF 128 Dither and Please make sure that images size has to be base on the resolution it happen some time if your images size is not depend on retina or normal resolutions. And if I am not wrong you facing problem only in retina device, may be below details will help
iPhone Retina Display
~~~~~~~~~~~~~~~~~~~~~~~
Width - 640px
Height - 960px : including 40px status bar
DPI - 326
您可以使用 Cocos2D 框架,Cocos2d 和 UIKIT 都可以很好地工作,没有任何图形相关的错误... Sprite 表减少了内存使用量,还支持所有透明图像,您可以运行动画,停止和重复它们。祝你好运..
You can use Cocos2D framework, Cocos2d and UIKIT both work great with out any graphic related errors... Sprite sheets reduces the memory usage and also support all transparant images , you can run animation ,stop and repeat them. Good luck..