From 0d15e80e281aeee3f0bcdb39dba5504e5e50e6ff Mon Sep 17 00:00:00 2001 From: German Khokhlov Date: Mon, 2 Nov 2026 17:11:42 +0400 Subject: [PATCH] Keep Navara satellite daylight through orbital zoom --- scripts/qa-engine-switch.mjs | 19 +++++++++++++++++++ src/globe/navara/index.js | 1 - 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/scripts/qa-engine-switch.mjs b/scripts/qa-engine-switch.mjs index 98f2c956d..b39b92f13 100644 --- a/scripts/qa-engine-switch.mjs +++ b/scripts/qa-engine-switch.mjs @@ -205,6 +205,25 @@ try { 'data-terrain-daylight', ), ); + // Zooming out on the satellite map must keep the same inspection sun. + assert.ok( + await page.evaluate(async () => { + const { engine } = window.__godsEyeView; + engine.camera.zoomOut(2_000_000); + await new Promise((resolve) => { + const remove = engine.frames.postRender.addEventListener(() => { + remove(); + resolve(); + }); + engine.render.request('qa-orbital-daylight'); + }); + return ( + engine.camera.height() > 1_500_000 && + engine.host.container.hasAttribute('data-terrain-daylight') + ); + }), + 'the orbital frame keeps daylight on the inspected globe', + ); await page.$eval('[data-stack-id="osm"]', (el) => el.click()); await page.waitForFunction( () => diff --git a/src/globe/navara/index.js b/src/globe/navara/index.js index 2bf7485b2..2d02da876 100644 --- a/src/globe/navara/index.js +++ b/src/globe/navara/index.js @@ -176,7 +176,6 @@ export async function createNavaraGlobe({ const placed = readCameraPlace(camera); const landscape = placed && - lookCarto.height < 100_000 && plan.globeLighting && automaticLandscape && (engine.maps.baseKind === 'sentinel2' ||