Zoom the video tab's time smoothly like the other tabs (#377)
game-maker / gate (push) Successful in 4m41s
game-maker / suite (push) Successful in 17m13s

The video tab jumped on every wheel step and on Fit. The Sound,
Pattern and Song tabs already ease the zoom since #377. The video
tab now takes the same transition, so all tabs feel alike.

- VideoCanvas runs wheel and Fit through `axisTween`. The duration
  comes from the General settings. Quick wheel steps add up, panning
  ends the transition, and the view that is stored is the one the
  transition lands on.
- Opening a video still fits at once without a transition. Only the
  Fit button eases, as in the Sound tab.
- `__gm.videoTab.zoom()` reports the zoom and whether a transition is
  on its way.

Tests:
- e2e 66 on melektaus-atx: ALL PASSED, 30 checks (1 new). The new
  check uses `sampleZoom` like the Sound tab. At 1000 ms the zoom is
  on its way two frames after the wheel (319 -> 321) and lands where
  the jump does (370.63). No counter-check against the old code.
- Gate on melektaus-atx: CHECK EXIT 0, 299 files, 4586 tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
adminandClaude Opus 5.5 committed 2026-10-11 21:52:29 +02:00
1 parent e191dc4b2e
commit 322fc39d16
4 files changed
+33 -6

No files matched your search

+4
View File
@@ -1,6 +1,7 @@
import { readFileSync } from 'node:fs';
import { uploadVideo } from '../lib/projects.mjs';
import { LANES, MAKE_OBJECT, pickAssetType } from './lib/scaffold.mjs';
import { sampleZoom } from './lib/zoomTransition.mjs';
/**
* Videos (#402). A WebM goes up and the worker turns it into an MP4 (in CI beside the PHP server,
@@ -197,6 +198,9 @@ export async function video(t) {
JSON.stringify({ spanBefore, untouched, moved, undoneMove, pickedBeside }),
);
await shot('66-video-tab');
// At 1000 ms a frame after the wheel the time's zoom is on its way, as in the Sound tab (#377).
const timeZoom = await sampleZoom(t, await strip(1), '__gm.videoTab.zoom()');
check('a zoom of the time is shown on its way and lands where the jump does', timeZoom.ok, timeZoom.detail);
// 66f. A sprite wearing the clip shows only its stretch, over and over: green and blue, never red
// or white, without sound in the editor.