Chapter 8 · Section 9
Time Between Steps and the Camera
The BPT law
BPT does not state how to draw between the steps of a simulation; it is a game method. The BPT ideas it serves are the two clocks of Part 3.6 and the turning skin. In Temporal Genesis, "Data runs at the Pulse Rhythm, each single transition, while the physical runs at the Pulse Tempo, the full cycle that returns a state to itself": the game's flip is a Rhythm (Chapter 2), and its matter takes sub-steps within it. The screen has a third clock, the display frame, and this Part joins them, so that a universe whose steps arrive a few times a second still moves smoothly. The skin itself turns: by Bifold Drag, v_∂ = 𝒞→·a_f/(1 + √(1 − a_f²)) (BPT Part 3.6), the Bifold turns with the universe's spin and drags what it touches, which the game shows by turning the torus and everything on it with its frame dragging (Chapter 2). Where the camera stands is the player's choice, and the theory prefers no view: of its Hubble Law, BPT Part 3.11 says "every observer, anywhere, sees the same law with themselves at the centre".
The established physics
None: a game method. Drawing between simulation steps by linear extrapolation along the last velocity, and bounding the time step an animation may take in one frame, are standard real-time rendering practice.
The game's math
Steps and frames. app.js calls render(frame, advance, dt) scene3d.js:1918 once per simulation step (advance = true), and once per matter sub-step or universe slice with dt the share of a step it moved (app.js:4375, 4452; MATTER_SUB = 4, app.js:4319). Between calls the idle loop startIdle() scene3d.js:2173 draws with advance = false whenever no step has drawn for 16 ms, so the camera and arrows answer while time stands still.
stepGap = min(1000, now − lastStep) (ms between the last two steps, on advance)
drawnMs = min(50, now − lastDrawNow) (ms since the last drawn frame)
frac = 0 on a step; min(1, (now − lastStep) / max(16, stepGap)) between steps
Between steps everything that moves is drawn at frac of the way along its step: stars at their bodies' velocities and the lattice's drift (placeMatter), disks, wells and Proto Wells, the torus's turn (angle + ω_T·frac, scene3d.js:2107), the lattice's turn and phase, and the skin's scroll with the flow (texture offset = −(rows now + rows a step·frac)/rows, scene3d.js:1956–1960, so the data glides instead of jumping half the tube a step). Every animation in Parts 8.3 and 8.4 runs on drawnMs, at most 50 ms a frame, so a page that stalls for seconds (the Physical Nova's own work) still shows the big bang frame by frame.
The torus turns with the frame dragging of Chapter 2: torusAngle += ω_T·dt on each step (scene3d.js:2104), ω_T from app.js frameDrag(). Everything on the torus (wells, Proto Wells, crystals, strings, matter, disks) turns with it.
The camera (scene3d.js:38–60). A perspective camera with a 45° field of view starts at (0, 2.4, 4.6), 5.2 units from the center. On a portrait screen (aspect < 0.75) it starts twice as far, so the whole torus fits a phone (scene3d.js:183). The orbit controls damp at 0.08, and zoom between 0.55 and 14 units. The wheel is the game's own: one notch is 5 % nearer or farther, a line a third of a notch, a page five, at most three notches an event. setScale() scene3d.js:1396 pulls the camera back as the universe grows, keeping the zoom chosen:
want = 5.2 · fit · (HOLE + 2·TUBE·scale) / (HOLE + 2·TUBE)
distance = max(minDistance, want · (distance / last want)); maxDistance = max(14, 3·want)
setZoom(k) puts the camera at clamp(5.2/max(0.15, k), 0.6, 30); resetView() at 5.2·fit for a new universe.
In the game
The player sees one continuous motion whatever the pace. The "Speed" control, "How fast pulses run. Max runs the rule flat out and draws in batches ... The physics is the same at every speed" (index.php:133), and the "Pace" slider set how often steps come; between them the stars still glide along their orbits, the data still streams round the tube and the torus still turns. Start and Pause (index.php:97–98) stop the steps, not the picture: while a universe is paused the view can still be turned and zoomed, because the idle loop keeps drawing. The torus turns slowly by itself with the frame dragging of the universe's spin, carrying its wells, stars and strings with it, the Bifold Drag made visible.
The camera is the player's. Dragging orbits round the torus (the pointer a grabbing hand), the wheel or a pinch moves in and out, and the "Zoom" slider, "In 3D, how close the camera is; in 2D, the size of a cell" (index.php:212), sets the distance by 2^((v − 43)/25) (app.js:5560). A phone held upright starts with the camera twice as far so the whole torus fits. As the universe dilates the camera backs away with it, keeping the zoom the player chose, so the torus keeps its size on screen while the "Scale:" readout climbs.
The scale model
Exact: no scale model. The drawn motion between steps is a linear guess along the last step's motion; at each step the picture is exactly the simulation's.
Fixed numbers
| Number | Where | What it is | Kind |
|---|---|---|---|
| 1000 ms | scene3d.js:1920 | longest step gap counted | METHOD (a paused run does not stretch frac) |
| 50 ms | scene3d.js:1923 | most drawn time a frame | METHOD (animations survive stalls) |
| 16 ms | scene3d.js:1950, 2177 | least step gap; idle threshold | METHOD (one display frame) |
| 4 (MATTER_SUB) | app.js:4319 | matter sub-steps a flip drawn | METHOD (Chapter 4) |
| 45°, 0.1, 100 | scene3d.js:37 | field of view, near and far planes | DISPLAY |
| (0, 2.4, 4.6), 5.2 | scene3d.js:38, 1101, 1397 | start position and distance | DISPLAY |
| 0.75, 2 | scene3d.js:183 | portrait screens start twice as far | DISPLAY |
| 0.08, 0.55, 14, 1.1 | scene3d.js:44 | damping, zoom range, zoom speed | DISPLAY |
| 1.05, 3, 1/3, 5, 1/100 | scene3d.js:54–58 | wheel notch, notches an event, line and page and pixel units | DISPLAY |
| 3 (×want), 14 | scene3d.js:1400 | far zoom limit | DISPLAY |
| 0.15, 0.6, 30 | setZoom() scene3d.js:356 |
zoom slider range | DISPLAY |