Hello Support,
I have a geojson file with 20000 points approximately. So i need to display tree for each every entity from geojson datasource. It is taking so much of time to loop each entity and apply png image for each entity. Below code shows loading geojson datasource and applying symbology for each entity.
Can you pls suggest what is the fastest way of loading geojson with symbology ?
var promise1 = Cesium.GeoJsonDataSource.load(
“geojson_data/site2/trees.geojson”, {
clampToGround: true,
}
);
promise1
.then(function (dataSource) {
viewer.dataSources.add(dataSource);
viewer.flyTo(dataSource);
//Get the array of entities
const entities = dataSource.entities.values;
// alert(entities.length);
for (let i = 0; i < entities.length; i++) {
const entity = entities[i];
entity.billboard.scale = 0.009;
entity.billboard.image = 'img/tree3.png';
}
})