* fix(engine): audio encodes on FFmpeg 4.4, which has no setts duration option
The segmented AAC encode ended its stream with setts=duration, added in FFmpeg 5.0, so every render
with audio failed on Ubuntu 22.04's FFmpeg 4.4. An FFmpeg without the option now encodes the audio in
one pass, which ends the stream at the duration itself.
* fix(engine): keep the setts capability check private to the AAC encoder
* perf(engine): a remote source's tail decodes run many at a time, not one per half-core
* perf(producer): the plan logs where its extract stage spends its time
* perf(engine): a window that ends inside its source takes its frame count without a decode
* test(engine): pin the tail-decode slot test to the windows that decode
* style(engine): format the tail-probe window check
* test(engine): deferred counts match extraction on a B-frame NTSC source; VFR is not deferred
* style(engine): format the tail-probe tests
* perf(aws-lambda): a site stores each video's ffprobe JSON, and the plan reads it instead of probing
* test(aws-lambda): a site stores and hands out each video's probe
* style(aws-lambda): format the probe-facts upload and tests
* perf(engine): a site's stored probe also holds the final-frame timestamp the plan would probe for
* test(engine): drop an unused import
* test(aws-lambda): the stored probe holds the ffprobe JSON and the final frame
* test(aws-lambda): the stored probe holds the ffprobe JSON and the final frame
* perf(producer): a distributed chunk encodes while it captures
* perf(producer): the audio task logs where its mix spends its time
One line per audio stage: prepare, groups, mix, master, encode and the peak check, in ms.
* perf(engine): locked warmup ticks stop sleeping once the page is ready
* perf(engine): a window reaching a stored video's end takes its frame count from stored facts
* fix(producer): the cloud audio task logs its phases
* perf(engine): stored facts keep the last packet length so late-start windows skip the tail decode
* fix(engine): a probe spawns without waiting when no stored facts are declared
* chore(aws-lambda): shorten comments over the line limit
* fix(engine): warmup keeps pacing after a failed tick; stored final frames check ffprobe major
* test(engine): the recorded ffprobe major matches the build's own banner
* test(engine): the version-banner probes go through a named binary like the other spawns
The chrome-headless-shell that HyperFrames downloads on Windows ships
without dxil.dll and dxcompiler.dll. Dawn's D3D12 backend loads them in
requestDevice, so the adapter is found but device creation fails and
three.js WebGPURenderer silently falls back to WebGL2.
Pass --disable-dawn-features=use_dxc next to --enable-unsafe-webgpu on
win32.
Refs #5775
Co-authored-by: serdarucel <196021214+serdarucel@users.noreply.github.com>
* fix(producer): a render's page-error count includes what the capture workers saw
* fix(producer): a failed parallel capture still carries its workers' page errors
* fix(producer): every capture failure carries the page's errors, in every stage
* chore(engine): drop a comment the capture classifier's name already says
* fix(engine): renames ride out Windows file locks instead of failing the render
* fix(producer): the true-peak and segment-manifest renames ride out Windows file locks too
parseAudioElements now resolves end the way core's compileTimingAttrs does. A clip
with no length at all warns, naming the clip, instead of silently playing to the end of
its source.
* fix(engine): h265 renders no longer fail on hosts with more than 16 cores
libx265 rejects more than 16 frame threads, so the thread count taken from the
CPU quota is now capped at 16 for x265. x264 is unchanged.
* fix(engine): pass the encoder to the thread cap in the CFR re-encode
* perf(producer): the audio task probes each video for sound instead of extracting its frames
* test(producer): the audio task finds a video's sound from a probe, with no frames extracted
* perf(engine): the audio mix reads clips held at a URL many at a time
* style(engine): format the remote clip slot choice
* fix(producer): the audio task places a video's sound in the window extraction would give it
* style(producer): format the slot cases of the script-src audio test
* perf(engine): remote sources of a site keep their probe results for the whole render
* test(engine): probe a content-addressed URL once per render
* style(engine): format the audio probe split
The serial guard in captureFrameSurface, which segmented capture reaches, threw on any frame under the
size floor. It now draws the frame once more and keeps a byte-identical redraw, as the streaming drain
guard does, so a flat frame no longer fails a segmented render.
Fixes#5685
The isolation CSS re-showed every descendant of a mover, so a child the
author hid with visibility:hidden was cropped and smeared into the trail
(240 green px in the repro; 0 in the sharp frame). The hide rule now skips
the mover subtree and the mover alone is made visible, so its descendants
inherit and keep their own visibility.
Found by review of #6106.
Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
* perf(aws-lambda): a render reads a video's audio from a small file stored beside it
A video's audio is interleaved with its pictures, so mixing it from the cloud read the whole video (2.5 GB for a 20-minute 4K film) at the Lambda's network speed. lambda sites create now stores each large video's audio packets as a separate object keyed by the video's hash; the audio task reads that when it exists.
* chore(producer): shorten the audio sidecar header comment
* fix(aws-lambda): no audio sidecar for a video whose audio starts late or that has several tracks
* test(producer): format the audio sidecar tests and end their ffprobe options with --
* fix(engine): a composition whose script throws is skipped with a warning, not waited on and refused
A script that threw before registering its timeline kept the capture waiting the full 45 s readiness timeout, then the render was refused. After a page error with timelines still missing the wait now ends after a short grace, each such composition gets an empty paused timeline of its authored length, and a script_error_isolated warning names the element. The render goes on without that animation.
* test(engine): memo test expects a script failure, format the browser test
* style(engine): shorten a doc comment to the line limit
* fix(engine): isolate only nested compositions that threw, never load failures or a root
* fix(engine): a thrown composition script fails fast and names the composition, not a load error
* fix(engine): the page-error grace starts at the first error, not at the start of the wait
* fix(engine): a nested throw is skipped only while another nested timeline is live
* feat: check names the filter fallback, the render log names the tier, Studio stops opting out
hyperframes check reports motion_blur_filter_fallback (info) with the reason capture could not
run and the way back to it. The engine's per-session log line gains tier=, and its pixel test
covers the fallback over a WebGL page. Studio no longer sends previewMotionBlur: every Chrome
can preview blur now, through the fallback where it lacks html-in-canvas; the server still
accepts false from an older Studio.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* feat(core): blur picks the cheaper filter tier when every mover only translates
The scan now notes whether any mover turns or scales (the linear part of its transform chain
changes) and whether it already forms a stacking context while it moves. When every mover only
translates, the filter tier draws as well as capture and costs about what no blur costs: on an
8 s bench shot a render took 7.0 s against 9.9 s with capture and 7.3 s with no blur. Anything
that turns or scales, or moves without a transform, stays on capture.
data-motion-blur-tier="capture" or "filter" forces a tier. The report says which one drew
and why (translation-only, tier-attribute); hyperframes check stays quiet for those two, which
are choices, not fallbacks. The pixel tests run the shared assertions through both tiers.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* docs(motion-blur): the two tiers, the tier attribute, and what changed in limits
The guide described blur turning off for WebGL, a root transform and similar. It now says the
filter tier draws instead, how the tier is chosen and forced, what each does with a turn or a
zoom, the measured cost of each, and which findings check emits. The skill note drops the
off-for-WebGL advice and the 1.7x figure.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* feat(core): blur defaults match a 240 degree shutter and at least 32 samples
The shutter opens 240 degrees by default (was 180) and each mover gets at least 32 taps (was
sized to the smear alone, down to 2), growing with the smear as before. These are the settings
the shutter blur Jake built uses; on the card whip the default render is now 51 dB from his
(34.6 dB at the old defaults). The guide's attribute table says so.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* chore(core): trim tier.ts comments to the ratchet
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* chore: allow deleting the Studio previewMotionBlur render test
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
* fix(producer): a chunk with mixed capture modes retries whole in screenshot mode
* fix(producer): format the mixed capture mode change
* fix(engine): the BeginFrame start-up check waits for the first frame up to its deadline
* style(engine): format the probe tests
* fix(engine): drop a comment from the probe loop
* fix(engine): a render no longer decodes the videos it replaces with extracted frames
* fix(engine): shorten the render-frame video hold comment
* fix(engine): keep the render-frame video hold comment under the line limit
* fix(engine): hold only the videos whose render id is replaced by extracted frames
Two scenes can share a video id. The render id tells them apart, so a live video is no longer held.
* feat(core): capture blur falls back to per-element filters where capture cannot run
html-in-canvas cannot capture a WebGL canvas, an iframe or a transform on the root, and some
browsers lack it. Blur used to turn off for the whole composition. Now the runtime hands the
composition to a filter tier: an SVG filter on each mover, 32 offset copies averaged along its
sampled path, softened along the motion so long smears do not step. It filters the live DOM,
so it works over a WebGL canvas, in any Chrome, and leaves glows and shadows on the element.
Turn and scale only soften; capture draws those truthfully, so it stays the first choice and
a scene re-init tries it again.
Capture turning itself off for a defect or three failed captures hands over; the renderer's
explicit off (HDR, distributed, engine blur) stays off. The report names the tier. Core's
unpacked size budget goes to 3,965,000 for the tier.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* test(engine): the backface pages now take the filter tier
The two backface tests still expected blur off; with the filter tier a
backface page reports tier filter. Fails on CI without this.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
* test(engine): the URL-read audio mix test stops its mix before cleanup and is not timed
* test(studio): bank the open-film thumbnail counts on the CI Chrome
The CI Chrome moved to 155 and renders one thumbnail fewer: 13 renders, 14 requests.
* fix(engine): a long audio mix prepares its clips a few at a time
A 200-clip mix started 200 ffmpeg at once and starved the host.
* chore(engine): trim the long comments in the audio mixer
Reasoning moved to the PR.
* test(engine): the mix order test starts every preparation at once
The mixer prepares clips in a core-sized pool; the test now sets enough cores.
* fix(engine): an opaque ProRes clip extracts to jpg frames, only ProRes with alpha stays png
ProRes was always cached as lossless PNG in case a missed tag hid alpha. ProRes alpha shows in its pixel format (yuva444p), so the guess only costs size: a 4K 4:2:2 clip wrote about 17 MB a frame, 18 GB for 36 s. VP8 and VP9 keep PNG because their alpha rides a side channel ffprobe can miss.
* test(engine): ProRes extraction format follows the alpha plane
* chore(engine): format the ProRes extraction change
* fix(engine): encode with the same x264 and x265 thread count on any host size
libx264 and libx265 pick their thread count from the host core count when
ffmpeg is not told one, and the bitstream depends on it, so the same frames
encoded to different bytes on 8, 16 and 32 vCPU nodes and chunks of one
render could differ. Both encoders now pass the thread count from the CPU
quota (Node reads the container limit), which is fixed per pod.
* chore(engine): raise the packed size budget for the encoder thread module
One ffmpeg graph held every clip of a group (or of the whole film) as its own
input, so a long project ran into the open-file and input limits and the
export failed. Past 96 clips the mixer now folds slices into one running
float sum, with no cap on the total; mixes of 96 clips or fewer take the same
single-graph path as before.
A mix process now also gets a deadline that grows with the film length, and a
failed ffmpeg run keeps how long it ran and the last lines of its stderr.
* fix(engine): render into a folder whose name holds a percent sign
ffmpeg reads an image sequence path as a printf template, so a folder like
"12% Up" was parsed as a format code and every video render failed. The
folder part of each frame-sequence path now goes through one helper that
doubles the percent sign.
* fix(engine): drop the helper doc line the comment ratchet rejects
* fix(core): capture blur sizes its taps to the smear and weights them exactly
A fast move strobed at the default 16 taps (8 px steps on a 1560 px whip). With no
data-motion-blur-samples set, taps are now about one per 2 px of travel (2 to 128); an
explicit samples count still wins.
Canvas quantizes image globalAlpha to 1/255, so 1/n weights left coverage short (n = 104
summed to 0.81, a lighter card body). Each tap now carries a whole number of 1/255 units
that sum to exactly 255.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* feat(core): capture blur draws the movers from their own transparent layer
The crop came from a capture of the whole scene, so the backdrop under a see-through mover
smeared with it (a lighter box with the dotted background erased) and a glow or shadow
outside the mover's box was cut off, leaving a hard-edged box.
Each frame now captures the movers alone, everything else visibility:hidden, so a mover's
pixels carry their true alpha and no backdrop; the background capture is unchanged. The crop
grows by the mover's ink reach (box-shadow, text-shadow, filter, outline, measured during the
scan), so glows travel with it. Two paints per frame, as before.
The output is cleared on wrap instead of showing the previous wrap's last frame, since the
first paint is no longer a drawable sharp frame. Core's unpacked size budget goes to 3,950,000
for the new module.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
* fix(core): capture blur finds callback-driven movers when events are on
The mover scan seeked with callbacks suppressed even where the root allows them, so a
composition whose motion lives in a timeline callback (a render(t) driven from onUpdate)
reported 0 movers and rendered sharp. With data-motion-blur-events="on" the scan now seeks
the way the frame reads do. Without it nothing changes: callbacks stay suppressed.
The no-movers finding in hyperframes check now names the attribute.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
* fix(engine): hundreds of effects in one audio group mix in time, and a mix timeout is named
* refactor(engine): name the group mix's single pad instead of commenting it
* fix(cli): preserve video frames when scenes reuse element IDs
* chore(core): keep media identity comments within the ratchet
* test(core): update page-build goldens for distinct media ids across repeated scenes
* fix(audio): fit PCM to video frames before AAC delivery
* fix(audio): migrate the CLI diagnostic stage fixture
* fix(test): measure the whole unscaled audio residual
* test(audio): refresh the speed-ramp delivery golden
* fix: data-volume multiplies the volume lane in preview and render
* fix: a clip's data-volume plays ahead of its audio effects, in preview and render
* feat(studio): the media panel shows a clip's Gain beside its Volume level
* fix(audio): cap gain times volume lanes through each ramp
* chore(core): account for shared volume envelopes in package budget
* fix(core): restore static gain when a playing lane is removed
Tooling and logs need more than "off". Give the runtime's report a reason
code for every way blur can be off (renderer-off, unsupported-browser, each
html-in-canvas defect, capture-failures), and two calls for tooling:
probe() runs the same scan a render would, without painting, and suspend()
stops all painting for the rest of a session without changing the reported
decision.
The engine prints one line per session from what the page reports:
`[motion-blur] on reasonCode=null movers=N failedFrames=K`. The first-frame
line cannot know about later failures, so the session end prints the same
line with "(session end)" when any frame fell back to plain DOM; a clean
session stays quiet. A render where every capture failed no longer reads as
"on" with nothing else.
Add the first test that reads blurred pixels: real Chrome with
html-in-canvas, the engine's frame order (seek, wait, composite, screenshot).
It checks the trail along the motion line, that what does not move matches
the sharp frame, that a box centered with translate is blurred where it
really is, and that a flipped backface card renders the plain frame. It
skips when Chrome or html-in-canvas is missing.
Folded review fixes: R13 (runtime half), R17 (engine half), T1 (the guards
that need reason codes), T3 (log-line and pixel tests).
Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>
Decide the html-in-canvas defects once for the whole timeline instead of at
the frame being drawn. The mover scan already seeks the timeline, so the
defect scan samples along it and a defect that only appears mid-timeline (a
rotated root, a flipped card) turns blur off from frame 0. Defects now block
on every Chrome version, so a render matches the preview it came from, and
GSAP's identity transform on the root no longer counts as one.
A per-frame check stays as a backstop for what scripts add later, and it
costs only that frame: a defect the scan missed (a short root shake, a
backface flip between samples) renders that frame sharp and logs once, and
blur resumes when the defect is gone. A block raised by the scan is lifted
when its cause is removed or the timeline changes; a capture failure stays
for the life of the instance.
The candidates a scan checks include faces whose backface-visibility: hidden
arrives through an animation. Each rescan adds to them and the per-frame
backstop reads the same set, so an animated-only flip card is caught by both.
Look for WebGL canvases in the whole document: a render's shader-transition
compositor appends its canvas to body, while preview puts it inside the root.
Turn page blur off on routes that cannot host it. The HDR and layered
compositors screenshot each DOM layer after hiding the others, which does
not reach blur's canvases, and a distributed (cloud or Lambda) chunk render
has no Studio preview to match and no guarantee of html-in-canvas in the
worker's Chrome. The producer sets pageMotionBlur to hdr-render,
layered-composite or distributed-render there, the distributed plan's
compile-time hint no longer forces screenshot capture, and the runtime says
which route turned it off.
Find the same movers whatever time a scan starts: the baseline is read at
t=0, so each worker of a parallel render picks the same set. An ancestor's
pan is not counted as its child's move.
Folded review fixes: R5, R10, R15, R19.
Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com>