Skip to content

armgit / 67.js

Public Imported from GitHub
0

3D engine that AI agents drive

Add change notes for the cascade hold (part of #504)

Nguyen Xuan Anc0a63488f3ca
diff --git a/changes/504.md b/changes/504.md
new file mode 100644
index 00000000..46dd5a8f
--- /dev/null
+++ b/changes/504.md
@@ -0,0 +1 @@
+- Redraw the far sun cascades less often while the camera orbits (issue #504): a cascade past the nearest one keeps its depth map while the camera moves inside it, and is redrawn 10 percent wider than needed when it leaves, so it stays valid for many frames; the nearest cascade and a camera that stopped fit exactly as before, and only the cascades whose map changed are drawn. Measured on an RTX 3060 at 1080p with an orbiting camera, the container port goes from 5.5-5.7 ms to 4.3-4.4 ms and the airport ramp from 15.6-17.0 ms to 13.3-13.8 ms. A still camera draws the same pixels as before; while orbiting, about 10 percent of pixels move by a few levels at shadow edges (0.2 percent by more than 8 of 255).
diff --git a/changes/504.size.md b/changes/504.size.md
new file mode 100644
index 00000000..325c7cee
--- /dev/null
+++ b/changes/504.size.md
@@ -0,0 +1,3 @@
+- entry:cascaded-shadows: grew 376 bytes gzip (10183 to 10559) for holding a far cascade map while the camera moves inside it; an orbiting frame of the container port goes from 5.5-5.7 ms to 4.3-4.4 ms and of the airport ramp from 15.6-17.0 ms to 13.3-13.8 ms at 1080p on an RTX 3060
+- scene:agent-scene+lazy: the same 357 bytes, because that scene loads the cascade module lazily
+- entry:core, scene:lit-box and scene:agent-scene: unchanged to the byte