recording: pace drivers in content-time (lockstep follow-up)#32
Merged
Conversation
Convert the node-editor recording drivers from wall-clock sleep() pacing to content-time hold_content (dasImgui's content-time helper, now on master). Under lockstep the recorder captures every rendered frame at a fixed 1/fps delay, so a wall-clock sleep(ms) stretches a beat to render_rate/fps * ms of video and drifts it off the voiceover; hold_content(app, ms) waits ms/1000*fps captured frames so the beat is exactly ms of video. 10 pacing sleep() calls across 7 drivers -> hold_content(app, ...): the lead before a gesture, the flow-pulse loop interval, and the dwell remainder. Effect-waits (wait_for_mouse_idle / record_check_*) are untouched. hold_content == sleep outside a recording session, so non-recording runs are unchanged. Validated by re-recording first_graph (1594 frames / 30fps = 53.133s): exit 0 (self-verifying), dropped 0. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
This PR updates the integration recording drivers’ pacing to be content-time based under lockstep recording, replacing wall-clock sleep() delays with hold_content(app, ...) so recorded video timing matches the intended narration/beat timing independent of machine render speed.
Changes:
- Replace flow-pulse loop pacing from
sleep(interval)tohold_content(app, interval)in multiple recording drivers. - Replace “lead-in” and “dwell remainder”
sleep(...)calls withhold_content(app, ...)in gesture/chord timing helpers.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| tests/integration/record_styling.das | Uses hold_content(app, interval) for link pulse pacing during voiced dwell. |
| tests/integration/record_first_graph.das | Uses hold_content(app, interval) for link pulse pacing during voiced dwell. |
| tests/integration/record_delete_and_select.das | Converts link pulse pacing and Delete-key lead/remainder holds to hold_content. |
| tests/integration/record_create_by_drag.das | Uses hold_content(app, interval) for post-creation link pulse pacing. |
| tests/integration/record_context_menus.das | Uses hold_content(app, interval) for initial “live link” pulse pacing. |
| tests/integration/record_connect_by_drag.das | Uses hold_content(app, interval) for post-link-creation pulse pacing. |
| tests/integration/record_clipboard.das | Converts chord timing helper lead/remainder holds to hold_content. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Re-records all 9 tutorial .mp4s on the content-time recording drivers (matches the dasImgui content-time pacing rework). Even beat timing under the lockstep fixed-dt clock; no wall-clock judder. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…l videos Self-contained per-repo runner: Clean -> Prepare (TTS) -> Record -> Convert for every tests/integration/record_*.das driver. Run one repo at a time; defaults re-record the whole repo. Computes its own repo root from $PSScriptRoot, resolves the sibling dasImgui checkout for the recording infra + module, and picks up $env:DASLANG. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to the lockstep-recording sweep (dasImgui #189 / #191, both merged). Converts the node-editor recording drivers from wall-clock
sleep()pacing to content-timehold_content.Why
Under lockstep the recorder captures every rendered frame at a fixed
1/fpsdelay, so a wall-clocksleep(ms)yieldsrender_rate/fps * msof video (beats stretch on a fast machine and drift off the real-time voiceover).hold_content(app, ms)waitsms/1000*fpscaptured frames, so a beat is exactlymsof video.hold_contentis a dasImgui playwright function already in scope (these drivers already callsay/say_begin/record_check_*from the same module), andhold_content == sleepoutside a recording session, so non-recording runs are unchanged.Changes
10 pacing
sleep()calls across 7 drivers →hold_content(app, ...): the lead before a gesture, the flow-pulse loopinterval, and the dwell remainder. Effect-waits (wait_for_mouse_idle/record_check_*) are untouched. Nohold_remainderhelper orref_time_ticksanchors exist here, so this is purely thesleep → hold_contentsubstitution.Validation
All 7 drivers lint clean (
-load_module dasImgui -load_module dasImguiNodeEditor). Re-recordedfirst_graphend-to-end (self-verifying): 1594 frames / 30 fps = 53.133 s exactly, dropped 0, exit 0.🤖 Generated with Claude Code