Can you please provide me .terrain files? I need offline terrain elevations data.
I tried accessing this link: http://sergeserver.dyndns.org/phocadownload/terrain.tar.gz
But now it seems the hostname does not exist.
Can you please provide me .terrain files? I need offline terrain elevations data.
I tried accessing this link: http://sergeserver.dyndns.org/phocadownload/terrain.tar.gz
But now it seems the hostname does not exist.
Hi there,
Here is some sample data for you to try: https://github.com/AnalyticalGraphicsInc/cesium/tree/master/Specs/Data/CesiumTerrainTileJson
Hope that helps,
Hi,
Actually, for the below code:
var terrainProvider = new Cesium.GeoserverTerrainProvider({
url : “http://localhost:8080/geoserver/wcs/wms”,
layerName: “wcs:clip11(reproject)”,
waterMask:true
});
globe.terrainProvider = terrainProvider;
Where do i get the geoserver folder from?
[The geoserver folder to be hosted at 8080]
Hi there,
Here is some global terrain data: https://cesiumjs.org/data-and-assets/terrain/index.html
However, note that it’s free for Internet use, but click on the individual datasets for information on offline terms of use.
Hope that helps,
Hi,
When i write below code:
terrainProvider : new Cesium.CesiumTerrainProvider({
url : ‘//assets.agi.com/stk-terrain/world’
})
I can see map on the globe , but when i write below code:
var terrainProvider = new Cesium.GeoserverTerrainProvider({
url: “http://localhost:8080/geoserver/wms?SERVICE=WMS&REQUEST=GetCapabilities&tiled=true”,
layerName: “SRTM90”,
styleName: “grayToColor”,
waterMask: true
})
Then i cant see neither map nor globe. Whole screen becomes black when i from switch from ol3 to ol3cesium using below code:
this.map = new ol.Map({
});
this.ol3d = new olcs.OLCesium({ map: this.map });
Why is it coming as black!
Hi,
Have you tested the GeoserverTerrainProvider is working in a pure Cesium application?
Guillaume
Hi,
No, I havent tested ‘GeoserverTerrainProvider’ on a pure cesium app.
Actually my app is not purely cesium app, my app should support both ol3 and ol3cesium/cesium.
So, i have made a button, which allows switching from 2d to 3d mode (i.e. ol3 to ol3cesium mode). But now in the 3d, i.e. ol3cesium globe mode, I have to show elevations using offline data. For which i made the geoserver setup done.
But now the problem is coming up that earlier i was able to see the map using :
source: new ol.source.Stamen({
layer: ‘terrain’
})
map in ol3 and when switching to ol3cesium i was able to see elevations using:
var terrainProvider = new Cesium.CesiumTerrainProvider({
url: ‘https://assets.agi.com/stk-terrain/world’
});
scene.terrainProvider = terrainProvider;
BUT, now when i switch to ol3cesium i see blank screen , i cant see globe when i use:
var terrainProvider = new Cesium.GeoserverTerrainProvider({
//url: “http://localhost:8080/geoserver/wms?SERVICE=WMS&REQUEST=GetCapabilities&tiled=true”,
layerName: “SRTM90”,
styleName: “grayToColor”,
waterMask: true
});
Thanks.
Hi,
Yes I understand your use case, I am the main dev of OL-Cesium.
Making sure the problem is not a pure Cesium bug would help analyze your issue.
Guillaume
Hi Guillaume,
I solved the blank black screen problem by changing the code as below:
var globe = new Cesium.Globe(Cesium.Ellipsoid.WGS84);
var terrainProvider = new Cesium.GeoserverTerrainProvider({
url: “http://localhost:8080/geoserver/ows?service=wms&version=1.3.0&request=GetCapabilities”,
//layerName: “SRTM90”,
//styleName: “grayToColor”,
waterMask: false
});
globe.terrainProvider = terrainProvider;
Am not sure if this is the correct way though.
BUT, i cant see any elevations ! What am i missing?
Please guide.
Don’t know.
Have you considered using https://github.com/geo-data/cesium-terrain-builder instead?
I am trying to install cesium terrain builder, but getting an error of wanting gdal version 2.0.0 during setup.
I think using ctb i can convert .tif to .terrain and then use those .terrain files in my app. Right?
Yes
Hi Guillaume,
I have got the elevations of a particular region by hosting the .terrain files on a local server on my machine by below code:
var terrainProvider = new Cesium.CesiumTerrainProvider({
url: ‘http://localhost:8080/terrain/terrain_52_06’
});
this.scene.terrainProvider = terrainProvider;
But now i dont want it from “server”, but read directly from the local filesystem without server then what should be the code ?
Please guide…
How to read directly from the local filesystem without server. What should be the code ?
The files must be hosted on a server in order for Cesium to access them – this is just a general security feature of the browser.
Hope that helps,
Hi Rachel,
My web app is already hosted on node server at 3005. So i wrote below code:
var terrainProvider = new Cesium.CesiumTerrainProvider({
url: ‘./app/map/terrain_52_06’
});
this.scene.terrainProvider = terrainProvider;
I get to see elevations of that one area. BUT i can also see unwanted elevated spikes all over remaining world.
What could be the issue?
Hi there,
It looks like this might be either a server configuration problem, or a problem directly with your tileset. Unfortunately, this isn’t enough information for us to help you diagnose your problems. I would recommend checking the rest of your setup, because I’m not sure this is a directly Cesium issue. If you narrow it down a little more, perhaps we could help answer more specific questions.
Hope that helps,
Actually my app is running on node server (port 3005) and when i host terrain elevation data on tomcat (port 8080) and enable CORS, I get to see perfect elevations of my one area.
But when i don't use tomcat and host data from node server (port 3005) using code shared before, I can see unwanted elevated spikes.