Film

Film

Deterministic film timelines, nested segment rendering, and FFmpeg export from a single compile path.

1 min readUpdated

The Film pillar composes seekable HTML films from nested timelines, renders them frame-by-frame in headless Chromium, and muxes audio with FFmpeg. Preview and production render share one compile path.

What you will learn

  • Nested timeline schema with video, audio, caption, and component layers
  • Segment render queue with cache keys and crash recovery
  • Reproducibility manifests with sha256 provenance
  • Reduced-motion settled pathways in every template

Concept first

A Pax film is not a screen recording. It is a document that compiles to one self-contained HTML page where every animation can be paused and seeked. The renderer captures frames at exact timestamps, so output is bit-exact across runs on the same toolchain.

Quick render

  1. List templates and film commands

    paxfx film list
    paxfx demo list
  2. Render from a template

    paxfx demo render launch-hero --preset launch-hero --format mp4

    Requires FFmpeg and Playwright Chromium on PATH. See Troubleshooting.

  3. Edit the document

    paxfx demo init launch-hero --set product=Acme
    paxfx demo render .pax/demos/launch-hero.demo.json --format gif

Expected result

The artifact lands in .pax/exports/ beside a manifest recording dimensions, frame count, output sha256, and the exact command that reproduces the file.

Compatibility

OutputStatusNotes
mp4 (H.264)productionRequires FFmpeg
webm / webm-alphaproductionRequires FFmpeg
gif / png sequenceproductionRequires FFmpeg
Nested segment queuebetaCrash recovery via cache
Real-time streaming previewexperimentalNot shipped

Performance implications

Film renders are CPU-bound. A 1920×1080@60 launch film at ~1400 frames typically completes in 20–40 seconds on a modern laptop with warm cache. Budget longer for cold cache or multiple aspect variants.

Failure cases

FFmpeg not found

Install FFmpeg and rerun paxfx doctor. Doctor prints the exact PATH fix for your OS.

Render hangs mid-segment

Check .pax/cache/film/*/queue.json for the in-progress segment. Re-run the same render command; the queue resumes from the last completed segment.

Output differs between machines

Compare manifest sha256 and renderer versions. Linux CI baselines may differ slightly from macOS; regenerate baselines on your target platform.

Was this page helpful?

Answers are not recorded or transmitted. Pax has no telemetry.