Draw the map with WebGL2 by default, with the 2D canvas as fallback
- Sea, land, waves, clouds, cables, tubes and packets are drawn by the graphics card; the land is geometry built once, so panning and zooming repaint nothing. - Cities, labels and markers are painted once into a sprite atlas and drawn in one call (with drawImage in 2D, which speeds up the 2D map too). - Settings > Map drawing: Auto or Always 2D, per device. Browsers without WebGL2, a lost context and puzzles keep the 2D map. - npm run bench:gpu compares 2D and WebGL in a real browser on a real GPU; ?fps shows a frame meter.
This commit is contained in:
parent
7aa6506e70
commit
cf9ab5e774
36 changed files with 862 additions and 83 deletions
|
|
@ -19,6 +19,7 @@
|
|||
"page": "node scripts/lib/page.js",
|
||||
"serve": "npm run build && npx --yes serve@14.2.4 _site",
|
||||
"perf": "node scripts/perf-bench.js",
|
||||
"bench:gpu": "node scripts/gpu-bench.js",
|
||||
"mcp": "node scripts/mcp.js",
|
||||
"mcp:browser": "node scripts/mcp.js --browser"
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue