Update approximateTerrainHeights.json
See original GitHub issueapproximateTerrainHeights.json was generated from the STK World Terrain as of #3903, with all of the improvements made to Cesium World Terrain, we should regenerate this file.
Long term plan is still for this data to be accurately provided by each terrain provider, but approximateTerrainHeights.json will always be a good fallback for servers that don’t have the information.
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (7 by maintainers)
Top Results From Across the Web
Update approximateTerrainHeights.json · Issue #6557 - GitHub
I had a configuration error that was causing the request to bomb and I burned a little too much time trying to figure...
Read more >Assets resources are not loaded in application - Stack Overflow
I am using Ionic(Angular) 5 with Electron to build my Linux OS Application. Everything is running fine but whenever I load my Cesium ......
Read more >Are approximateTerrainHeights.json and the files under the ...
I find that approximateTerrainHeights.json takes more than 1 second to load. Is it necessary for running Cesium program?
Read more >core-frontend Change Log - iTwin.js
Dynamically import approximate terrain heights instead of fetching as JSON. Expose iTwin.js Core Version for extensions; Fixed interaction between linear ...
Read more >terriajs-cesium/CHANGES.md - UNPKG
89, * Reduced size of approximateTerrainHeights.json ... 234, * Updated terrain and imagery rendering, resulting in terrain/imagery loading ~33% faster and ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

@thw0rted thanks for pointing that out, it doesn’t look like we have an
otherwisefor loading theapproximateTerrainHeights.jsonfile https://github.com/AnalyticalGraphicsInc/cesium/blob/master/Source/Core/ApproximateTerrainHeights.js#L58-L60This was actually easier than what I suggested before, because if you have a JSON file you can turn it into a valid ES6 module by just adding
export defaultat the beginning. That let me throw together this build real quick. It builds and runs without apparent issue, with two caveats:StaticGroundGeometryColorBatchandStaticGeometryPerMaterialBatchfail but only if run in the whole suite – running just those two specs works fine. This suggests that some earlier test is manipulating theApproximateTerrainHeightsmodule (it’s the only one I changed), but I haven’t been able to figure out howSource/without looking atSpecs/, and it turns out that tons of tests poke around in the guts ofApproximateTerrainHeights. Even ignoring my suggestion from this fork, maybe those interactions should be replaced with a mock?createGroundPolylineGeometryworker inlines all its dependencies (recursively), includingApproximateTerrainHeights, which means that it gets its own (bundled) copy of the data. In a non-ES6 environment, I don’t have a good solution for this. (I had made a snide remark here but it looks like Firefox still hasn’t gotten onboard with ES6 modules in a web worker, so, oops?)