Place every surface-bound layer through the shared placement

Import pins, infrastructure, ALPR, directions markers, bikeshare and the
Bhote Koshi story use createSurfacePoints instead of their own sampling,
budgets and partial triggers; ground snap, the mesh floor sampler,
traffic, transit, Street Level, the camera ground guard, wildlife and the
cockpit host read heights through readSurface or surfaceTriggers.
Per-layer offsets and floor policies stay as options. The import no
longer re-places pins on every camera move from the UI.

Calls to engine.surface outside src/globe go from 41 sampling calls to
10, each a raycast, a one-shot fly-to height or an asynchronous detailed
sample.
This commit is contained in:
German Khokhlov committed 2026-11-10 16:13:06 +04:00
1 parent ef104aaac3
commit 82ed68f443
31 files changed
+530 -568

No files matched your search

+23 -25
View File
@@ -3715,32 +3715,30 @@ test('actual Traffic, Bikeshare and Transit lifecycles retain sensitivity in eve
},
}).methods;
// The bikeshare display claims through its engine's camera: the viewer's.
const bike = createBikeshareDisplay(
{ camera: app.viewer.camera },
{
state: {
_overlayHost: { setVisible: noop },
_cityRuntime: new Map(),
_failedCityIds: new Set(),
},
services: {
render: { governorRequestRender: noop },
picking: { registerPickOwner: noop, unregisterPickOwner: noop },
},
source: {},
parts: {
display: {
_installClickHandler: noop,
_uninstallClickHandler: noop,
_clearSelection: noop,
onCameraChanged: noop,
runProximityCheck: noop,
deactivateAllCities: noop,
},
ingestion: { abortAllInFlight: noop },
},
const bike = createBikeshareDisplay(app.engine, {
state: {
_stationRenderMap: new Map(),
_overlayHost: { setVisible: noop },
_cityRuntime: new Map(),
_failedCityIds: new Set(),
},
);
services: {
render: { governorRequestRender: noop },
picking: { registerPickOwner: noop, unregisterPickOwner: noop },
},
source: {},
parts: {
display: {
_installClickHandler: noop,
_uninstallClickHandler: noop,
_clearSelection: noop,
onCameraChanged: noop,
runProximityCheck: noop,
deactivateAllCities: noop,
},
ingestion: { abortAllInFlight: noop },
},
});
const layers = { traffic, bikeshare: bike, transit: app.layer };
const orders = [
['traffic', 'bikeshare', 'transit'],