5

Cesium マップに何千ものポイントを配置しようとしていますが、Firefox がクラッシュするという問題が発生しています。Firefox を使用する必要があります。マップは15,000ポイント(画像として)表示できるようです。ただし、これもほとんど使い物になりません。ズームとパンには大きな遅延があり、最終的にはクラッシュします。何点が限界か分かる人いますか?また、これらのポイントを表示するより良い方法はありますか? セシウムではなく、私であることを願っています。czml を作成して渡すのが遅いと聞いたので、次の JavaScript テストを行います。

function test(){
  for (var i=0; i<15000; i++){
     tempLat +=1;
     tempLon +=1;
     if(tempLat>90){
      tempLat=0;
      tempLon=0;
     }
     addBillboard(scene, ellipsoid, tempLat,tempLon);
  }
}

 //this is from the sandcastle examples for cesium. 
 function addBillboard(scene, ellipsoid,tempLat,tempLon) {
    var primitives = scene.primitives;
    var image = new Image();
    image.onload = function() {
        var billboards = new Cesium.BillboardCollection();
        var textureAtlas = scene.context.createTextureAtlas({image : image});
        billboards.textureAtlas = textureAtlas;
        billboard = billboards.add({
            position : ellipsoid.cartographicToCartesian(Cesium.Cartographic.fromDegrees(tempLat, tempLon)),
            imageIndex : 0
        });
        primitives.add(billboards);
    };
    image.src = '../images/Cesium_Logo_overlay.png';
}
4

1 に答える 1