假設我理解這個權利 - 基本上你有一些基於會話#的數據類型,你希望在該經緯度上畫一個更大或更小的圓圈,長對。
你可以做的是最初導入數據,然後獲取會話數量並物理創建一個在地圖上呈現的集合(某種類型的數組或某物)。您可以使用地圖框標記來渲染這些圖標或圈出並物理分配它們的大小。
在此之前,你必須預先確定的函數取會話#,並將它們映射到物理半徑值 - 說1000個會話= 10個和50,000個會話半徑= 500。
半徑
例如在我創建這是我的代碼,使用 - https://github.com/mapbox/react-native-mapbox-gl
markersArray = markersArray.concat({
coordinates:[bList[i].latitude, bList[i].longitude],
'type': 'point',
title: bList[i].bname,
subtitle: bList[i].data,
id: bList[i].o_ID.toString(),
startTime: bList[i].startTime,
endTime: bList[i].endTime,
annotationImage: {
url: (bList[i].type === 'drink') ? (drinkUrl) : (foodUrl),
height: 30,
width: 30
},
rightCalloutAccessory: {
url: 'image!info-icon',
height: 20,
width: 20
}
});