如何在此处集群地图中显示重复的制造商
How to display duplicate maker in cluster here map
我在这里使用地图并且使用聚类。但是我在显示坐标相同 /dublicate 的制造商时遇到问题。当我放大集群时,不幸的是,制造商不可见,但集群仍然可见。集群缩放时如何显示这些标记?
我的集群选项如下
var clusteredDataProvider = new H.clustering.Provider(dataPoints, {
clusteringOptions : {
eps : 16,
minWeight : 2
},
theme : new PusulaClusterTheme()
});
我们遇到了同样的问题。如果你绝对需要标记来显示完全相同的点,可以这么说,那么我不知道你能做什么。但是我们想为街道上的每栋房子显示标记,有时我们有多个家庭在一个房子里,所以我们无法正确显示多个家庭。
我们用 HERE 开了一张票,这是他们的回复:
"...when you are placing multiple markers at the same geo-point, it is
just that they are stacked one on top of the other. Since they are all
at the same coordinate only the top most one will be displayed. So
to enable multiple marker to be shown at the same coordinate, you will
need to have some logic to avoid overlapping of markers. There is no
method straight off the shelf in JS API that can do this for you, but maybe
you can use the method map.getObjectsat(X,Y) to check if there are
already any markers at the point. If there is an existing one, then use
some logic to slightly change the coordinate value of the new marker
to be added at the point.
我们最终复制了我们在 Whosebug see this link 上找到的解决方案,该解决方案是为 Google 地图编写的,但在这里与 HERE 一样相关。它使用一个函数来随机更改最后一位或 2 个坐标(如果它们是多个),这样您的所有多个坐标都会有点独特并且间隔开。
我在这里使用地图并且使用聚类。但是我在显示坐标相同 /dublicate 的制造商时遇到问题。当我放大集群时,不幸的是,制造商不可见,但集群仍然可见。集群缩放时如何显示这些标记?
我的集群选项如下
var clusteredDataProvider = new H.clustering.Provider(dataPoints, {
clusteringOptions : {
eps : 16,
minWeight : 2
},
theme : new PusulaClusterTheme()
});
我们遇到了同样的问题。如果你绝对需要标记来显示完全相同的点,可以这么说,那么我不知道你能做什么。但是我们想为街道上的每栋房子显示标记,有时我们有多个家庭在一个房子里,所以我们无法正确显示多个家庭。
我们用 HERE 开了一张票,这是他们的回复:
"...when you are placing multiple markers at the same geo-point, it is just that they are stacked one on top of the other. Since they are all at the same coordinate only the top most one will be displayed. So to enable multiple marker to be shown at the same coordinate, you will need to have some logic to avoid overlapping of markers. There is no method straight off the shelf in JS API that can do this for you, but maybe you can use the method map.getObjectsat(X,Y) to check if there are already any markers at the point. If there is an existing one, then use some logic to slightly change the coordinate value of the new marker to be added at the point.
我们最终复制了我们在 Whosebug see this link 上找到的解决方案,该解决方案是为 Google 地图编写的,但在这里与 HERE 一样相关。它使用一个函数来随机更改最后一位或 2 个坐标(如果它们是多个),这样您的所有多个坐标都会有点独特并且间隔开。