问题描述
这一个是pretty的摆在那里,但我找不到任何职位的任何地方解决这个问题。对于谷歌地图API第3版,您可以添加自定义样式的地图元素:
This one is pretty out there, but I can't find any posts addressing it anywhere. For Google Maps API v3, you can add custom styling to the map elements:
var pinkParksStyles = [
{
featureType: "all",
stylers: [
{ saturation: -80 }
]
},
{
featureType: "poi.park",
stylers: [
{ hue: "#ff0023" },
{ saturation: 40 }
]
}
];
map.setOptions({styles: pinkParksStyles});
有谁知道有什么方法可以自定义样式应用到一个Android MapView类?谢谢!
Does anyone know of any way to apply custom styling to an Android MapView?? Thanks!!!
推荐答案
我最初的想法是将继承图形窗口和覆盖的抽奖活动。在使用 ColorMatrixColorFilter 的组合的OnDraw事件更换颜色的画布和 AvoidXfermode 。 Thees应该有所帮助:
My initial thoughts would be to subclass MapView and override the on draw event. Have the onDraw event replace the colors in the canvas using a combination of ColorMatrixColorFilter and AvoidXfermode. Thees should help as well:
avoidxfermode更换颜色在画布上
这篇关于自谷歌地图的造型为Android的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!