Show HN: Show HN: Interactive map of Earth's coastlines if all ice melts
cosmicplayground.org
Show HN: Show HN: Interactive map of Earth's coastlines if all ice melts
1–2 of 2 posts
Re: Show HN: Show HN: Interactive map of Earth's coastlines if all ice melts
#2The map[2] is not mobile friendly and requires WebGL. I recorded a video that tours through the map to music.[3] It's the same experience as pressing "begin tour" on the map. The website version will have better visuals because of video compression.
The map is rendered with WebGL via PixiJS and the rest of the app is Svelte. The original DOM implementation was written in Svelte but it was too inefficient, the bottleneck being the DOM and not Svelte. You can test the difference yourself on the map by pressing `ctrl+backtick` to enter dev mode and clicking "webgl" to toggle over to the DOM version. On my machine, the Pixi version drops no frames in all browsers, and for the DOM version, Firefox drops about 1 in 10 frames and Chrome/Edge are sludge, seemingly because they're shy about using more GPU. The source code readme[4] has some technical notes discussing Svelte and Pixi[5], and it links to original DOM implementation with more comments if you're curious.
I'd be glad to answer questions. Not about the science though, I'm a web developer.
[1] https://visibleearth.nasa.gov/collection/1484/blue-marble
[2] https://www.cosmicplayground.org/#deep-breath
[3] https://www.youtube.com/watch?v=7xEPqg-Kyg4
[4] https://github.com/ryanatkn/cosmicplayground
[5] https://github.com/ryanatkn/cosmicplayground#technical-notes