Skip to content

Commit

Permalink
Increased elevation point sampling
Browse files Browse the repository at this point in the history
  • Loading branch information
sdl60660 committed Jun 28, 2022
1 parent 964c7da commit 2f2ae5f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/components/Map.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -330,9 +330,10 @@
let terrainElevationMultiplier = 1.2;
let cameraBaseAltitude = 4300;
const elevationArrayStep = Math.max(
2,
Math.round(Math.min(coordinatePath.length / 4 - 1, 100))
Math.round(Math.min(coordinatePath.length / 4 - 1, 20))
);
// Sometimes while 3D tiles are still loading, the queryTerrainElevation method doesn't hit,
Expand All @@ -342,7 +343,7 @@
let attempts = 0;
while (
attempts < 10 &&
attempts < 8 &&
(elevations === null || elevations.every((d) => d === null))
) {
await sleep(200);
Expand Down

1 comment on commit 2f2ae5f

@vercel
Copy link

@vercel vercel bot commented on 2f2ae5f Jun 28, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.