Skip to content

feat(compositor): expose programme time to the frame geometry - #687

Draft
EtienneLescot wants to merge 2 commits into
mainfrom
feat/3d-programme-time
Draft

EtienneLescot wants to merge 2 commits into
mainfrom
feat/3d-programme-time

Conversation

@EtienneLescot

@EtienneLescot EtienneLescot commented Sep 16, 2026

Copy link
Copy Markdown
Collaborator

Plumbing: programme time reaches the frame geometry so animated effects stay a pure function of t (preview equals export).

Chantier 3D, PR 3a. Spec complète et branche d intégration : #682.

🤖 Generated with Claude Code

The compositor only knew the active clip's source time, which jumps at every
cut and every clip, and a live frame counter that differs between playback
and seek for the same image. Animated backgrounds (PR 3b) need a continuous
output clock that is a pure function of the displayed instant.

- set_programme_time(Option<f32>) on the D3D11, Metal and wgpu compositors,
  carried through FrameGeometryInput into FrameGeometry::programme_t
  (fallback frame / FPS, like source_t). Nothing reads it yet, so rendering
  is unchanged; no shader or LayerCB change.
- Export: timeline_walk sets frames / out_fps before each compose.
- Preview: regions::ProgrammeClock rebuilds the same clock from the scene
  (previous clips' output frames + the active clip's speed segments, the
  spans the export walks) and Player applies it from the decoder pts in
  sync_time, so step and present_frame agree for the same image.
- plan_frame_is_pinned_bit_for_bit now also pins programme_t (a copy of the
  input); the 21 previous values are unchanged.
- Tests: clock vs export walk at every frame, continuity across clips,
  frame counter independence, and an env-gated D3D11 test comparing
  playback and seek on a real decoder.
The seek test checked Player::programme_time(), so a sync_time() that
stopped forwarding the value, or forwarded another one, still passed.
Expose the last received value through a doc-hidden getter on all three
compositors and assert on it after each step and seek. Note in the
header that CI skips this test.
@coderabbitai

coderabbitai Bot commented Sep 16, 2026

Copy link
Copy Markdown
Contributor

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant