Loading 3D Tiles CesiumJS API

Hi All,

I have loaded two 3D Tiles layers in my CesiumJS API (http://45.190.248.136/topomen.geoportal/) using the code bellow. The second layer ametistaTileset is loading in Safari browser, plus that in Firefox, it loads only in a localhost API. However, in my remote server (http://45.190.248.136/topomen.geoportal/) is taking too long for rendering the webpage or not rendering at all from time to time. I’m new comer to CesiumJS and would anyone tell me if I’m missing any configuration based on the code below?

const tileset = viewer.scene.primitives.add(
  new Cesium.Cesium3DTileset({
    url: Cesium.IonResource.fromAssetId(1468527),
  })
);

(async () => {
  try {
    await tileset.readyPromise;
    await viewer.zoomTo(tileset);

    // Apply the default style if it exists
    var extras = tileset.asset.extras;
    if (
      Cesium.defined(extras) &&
      Cesium.defined(extras.ion) &&
      Cesium.defined(extras.ion.defaultStyle)
    ) {
      tileset.style = new Cesium.Cesium3DTileStyle(extras.ion.defaultStyle);
    }
  } catch (error) {
    console.log(error);
  }
})();

const ametistaTileset = viewer.scene.primitives.add(
  new Cesium.Cesium3DTileset({
    url: Cesium.IonResource.fromAssetId(1482238),
  })
);

(async () => {
  try {
    await ametistaTileset.readyPromise;
    await viewer.zoomTo(ametistaTileset);

    // Apply the default style if it exists
    var ametistaExtras = ametistaTileset.asset.extras;
    if (
      Cesium.defined(ametistaExtras) &&
      Cesium.defined(ametistaExtras.ion) &&
      Cesium.defined(ametistaExtras.ion.defaultStyle)
    ) {
      ametistaTileset.style = new Cesium.Cesium3DTileStyle(ametistaExtras.ion.defaultStyle);
    }
  } catch (error) {
    console.log(error);
  }
})();

Thank you very much for your time in advance. I appreciated it.

Julierme

Hi All,

I think the solution was just cleaning the browser cache. The problem is gone.