![](/img/trans.png)
[英]Google Maps SDK for iOS - Cluster Manager don't show marker title on marker tap
[英]Google Maps SDK for iOS: don't support little endian bitmaps
我正在尝试在iOS版Google Maps中实现GMSTileLayer
子类。 我在磁盘上有一堆用于图块层中每个图块的PNG图像,它们是使用UIImage(contentsOfFile:)
加载的。 当我尝试加载图像时,它们没有显示,并且我在日志中收到此消息:
2015-08-22 22:50:10.663 inPin[44718:24904635] ((null)) was false: Don't support little endian bitmaps
2015-08-22 22:50:10.663 inPin[44718:24904635] ((null)) was false: Unable to create GMSGLImageTile due to bad graphics data
我不知道PNG图像甚至具有字节顺序,所以我不知道此消息来自何处。 有人知道为什么会这样吗? 我从Google磁贴服务器尝试了PNG,效果很好。 我的PNG由使用ImageMagick的脚本生成。
好吧,我知道了。 原来我的图像具有16位色深,将其更改为8位可使错误消失。 在ImageMagick中,我只需要添加-depth 8
。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.