From e80a270b058bd56b67fd4c961c00460eb6ec3908 Mon Sep 17 00:00:00 2001 From: Richard Zink Date: Wed, 7 Oct 2026 21:00:32 +0200 Subject: [PATCH] Fix tile coords + reduce mosaic for faster load MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Tile coords were wrong — Passau at zoom 11 is (1099, 706), not (1102, 710). My earlier hand-calc (1100/706) was close but rounded in the wrong direction. Mosaic 16x16 = 256 tiles took 5-10s to load due to browser 6-connection limit. Reduced to 9x9 = 81 tiles (~2s). Camera already looks down enough that visible ground fits in 9 units. --- vendor/clouds3d.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/vendor/clouds3d.js b/vendor/clouds3d.js index 89e25bb..3ed57be 100644 --- a/vendor/clouds3d.js +++ b/vendor/clouds3d.js @@ -270,11 +270,11 @@ function init(canvas) { var GROUND_TILE_URL = 'https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/'; var GROUND_TILE_Z = 11; var GROUND_TILE_SIZE = 256; -var GROUND_MOSAIC_SIZE = 16; // 16x16 tiles around the camera +var GROUND_MOSAIC_SIZE = 9; // 9x9 tiles around the camera (~81 tiles, fast initial load) var GROUND_BUFFER_TILES = 2; // refetch when this close to edge // Passau tile at zoom 11 -var GROUND_BASE_X = 1102; -var GROUND_BASE_Y = 710; +var GROUND_BASE_X = 1099; +var GROUND_BASE_Y = 706; // Module-level state, shared across renderer instances var groundCanvas = null;