Add a comet trail animation
The frame glides from waypoint to waypoint and drops a screenshot of itself every frame-width or so. The stills stay where they were taken and fade over a few seconds, so the live video reads as the head of a comet whose tail is its own recent past. The steering caps how fast the heading may change: an instant turn would lay the stills out in straight dotted lines, and it is the curve that makes a tail read as one. Drops are spaced by distance travelled rather than by a timer, so they stay even however the frame is turning. Since the capture is a crop of the tab, a still lying under the frame would be photographed into the next one. A drop waits until the frame is clear of the tail, keeping the invariant corners already relies on. Also picks up the FRAME_SCALE, BOUNCE_SPEED and CORNER_INTERVAL_SECONDS tuning sitting in the tree. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Tg15tLAuT6NrCE1ZxKVgDB
This commit is contained in:
@@ -18,6 +18,11 @@ import {
|
||||
DRAG_FRAME_SCALE,
|
||||
DRAG_MIN_SCALE,
|
||||
DRAG_MAX_SCALE,
|
||||
TRAIL_SPEED,
|
||||
TRAIL_TURN_RATE,
|
||||
TRAIL_SPACING,
|
||||
TRAIL_LENGTH,
|
||||
TRAIL_FADE_SECONDS,
|
||||
BACKGROUNDS,
|
||||
ANIMATIONS,
|
||||
AUTO_ANIMATION,
|
||||
@@ -51,6 +56,11 @@ app.get('/config.js', (_req, res) => {
|
||||
`export const DRAG_FRAME_SCALE = ${DRAG_FRAME_SCALE};\n` +
|
||||
`export const DRAG_MIN_SCALE = ${DRAG_MIN_SCALE};\n` +
|
||||
`export const DRAG_MAX_SCALE = ${DRAG_MAX_SCALE};\n` +
|
||||
`export const TRAIL_SPEED = ${TRAIL_SPEED};\n` +
|
||||
`export const TRAIL_TURN_RATE = ${TRAIL_TURN_RATE};\n` +
|
||||
`export const TRAIL_SPACING = ${TRAIL_SPACING};\n` +
|
||||
`export const TRAIL_LENGTH = ${TRAIL_LENGTH};\n` +
|
||||
`export const TRAIL_FADE_SECONDS = ${TRAIL_FADE_SECONDS};\n` +
|
||||
`export const BACKGROUNDS = ${JSON.stringify(BACKGROUNDS)};\n` +
|
||||
`export const ANIMATIONS = ${JSON.stringify(ANIMATIONS)};\n` +
|
||||
`export const AUTO_ANIMATION = ${JSON.stringify(AUTO_ANIMATION)};\n`,
|
||||
|
||||
Reference in New Issue
Block a user