Commit Graph
124 Commits
Author SHA1 Message Date
Jonathan Cardoso 96d8e22c2d Image-sequence export reports the stills it wrote, not the path it was given (#4018)
* fix(export): an image-sequence export reports the stills it wrote

An export to `a.png` as an image sequence writes `a000.png`, `a001.png` and so on, but the
job's result, `file.exportMedia`'s `path` and the CLI's "exported" line all named `a.png`,
which does not exist.

The report now names the first still, the name `file.import` and `probe --image-sequence`
take for a sequence. `file.exportMedia` and `export.quick` name it as `path` up front, from
the frame count `export.resolve` uses, and add `lastPath`. The CLI prints both. A single
file keeps its path.

Fixes #4009

* fix(automation): a cancelled image-sequence export is cleaned up by its stills' name

Since `file.exportMedia` names an image sequence's first still as `path`, the MCP cancel
clean-up took `a000` as the stem: it left `a001.png` and every later still, and the `a.srt`
sidecar, behind. The result now also carries `basePath`, the name the stills are numbered
from, and the clean-up goes by it.

* fix(automation): an image-sequence cancel clean-up keeps the base name and finds .jpeg stills

An image-sequence export numbers every still, a single frame included, so a file under its base
name (`a.png`) is never its own: cancelling one deleted a user's `a.png` if it was saved during
the export. The stills of a `.jpeg` sequence were left behind instead, since the extension was
read as a format name, and `jpeg` names Motion-JPEG there; `file.exportMedia` keeps `.jpeg`
for a JPEG sequence.

* fix(automation): a cancelled image sequence removes only the stills it numbered

The clean-up matched any `<stem><3+ digits>.<ext>` written during the export, so cancelling an
export to `a.jpeg` could delete `a1000.jpeg`, the first still of an export to `a1.jpeg` in the
same folder. It now takes the digits and the last index from the result's `lastPath` and removes
only those names: `a000.jpeg` to `a120.jpeg` for a 121-frame export.
2026-11-03 00:03:30 -05:00
JohnandClaude Opus 5.5 e6eec33a42 G13: TikTok, Instagram Reels and YouTube Shorts export presets (#3721)
* G13: TikTok, Instagram Reels and YouTube Shorts export presets

Three Web & Social presets for short-form vertical video: H.264
1080×1920 (9:16), scaled to fill, at the sequence's frame rate, AAC
48 kHz stereo, with Loudness Normalization on at −14 LUFS and a −1 dBTP
ceiling, the level the platforms play at; 10, 8 and 12 Mbps VBR. They
share a short_form() helper; Social Vertical is unchanged.

short_form_presets_are_vertical_and_loudness_normalized checks size,
rate, scaling, bitrate, audio and loudness. Real exports measured
−14.1 LUFS from both a −19 and a −8.4 LUFS source.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* G13: the short-form presets test checks each maximum bitrate

CodeRabbit on #3721: assert max_bitrate_kbps (12, 10 and 16 Mbps) and
the VBR 1 pass mode next to the target bitrate, so a change to the
ceiling alone fails the test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-01 15:15:40 -05:00
Patrik LermonandClaude Opus 5.5 04476bf9cb Export: the time left counts down between batches; the status bar shows it once a second, in place (#3816)
* Export: the time left counts down between batches; the status bar shows it once a second, in place

An export finishes its frames in batches of up to 16. The estimate measured the speed to the
latest reading, so between batches the speed sagged and the time left grew, then fell when the
next batch landed: about ±13 % on a heavy 4K60 export, enough to flip between 1:04:50 and 56:11.
It now measures the speed between batch arrivals and counts down from the last one; a batch three
intervals late falls back to the speed up to now, so a stall still makes the estimate grow.

The status bar redrew its text every frame, right-aligned against the bar, in Inter's proportional
digits, so "Exporting… 46%" moved sideways with every change of the time left. The text now
changes at most once a second, its digits sit in cells of equal width, and its room only grows
while the job runs (from the start it fits 100 % and a time under an hour).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* Export: no "0 s left" while the last batch is late; the status text has room for any time left from the start

The countdown between batches reached zero when the last batch took longer than the speed said,
and showed "0 s left" until it was three intervals late; it now gives way to the speed up to now as
soon as it runs out. The status bar's room was for a time under an hour, so an export's first
estimate over an hour still moved the text once; it is now for 99:59:59 from the start.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* Export: the queue's and the Progress panel's job text change once a second, with digits of one width

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ui-egui: tabular_label is read by screen readers as a label

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-01 15:14:46 -05:00
aiongg f0857494f6 Merge PR #3475: fix(export): a failed encoder factory does not stop the next one (#936) 2026-10-31 02:12:03 +00:00
Michael ButlerandBrandon Thomas 0f8b6593af Export: write fast-start MP4 files for upload compatibility (#3459) (#3470)
* #3459: finalize MP4 video exports with fast-start metadata

Use the existing fast-start muxer for MP4 video, support reading buffered outputs, and retain readable reserved proxy handles. Add disk, memory, reserved-handle and I/O failure regressions.

Implemented with OpenAI Codex assistance.

* #3459: assert decoded audio RMS in fast-start exports

Use the existing RMS helper to check the expected tone level across every output mode and container. Contributor reports the updated tests passing.

Implemented with OpenAI Codex assistance.

---------

Co-authored-by: Brandon Thomas <echelon@gmail.com>
2026-10-30 01:45:30 -04:00
Gerrit Timmer 4d57c52ab6 Free decoder frame caches and plane pools when an export ends (#3637)
Every source keeps up to 384 MiB of decoded frames plus its live decoders
for the whole session, and the 1 GiB process budget only trims caches that
were idle while another cache asks for frames. The 8/16-bit plane shelves
(192 MiB each) were never trimmed. A long-lived process (MCP) therefore
held 2-3 GiB after an export and ran out of memory on the second one.

Add filmcraft_codecs::release_idle(), which empties every cache nobody is
decoding on (try-locked, so users are untouched), and
filmcraft_frame::pool::trim_planes(). A standalone export calls both next
to trim_f32 when its pipeline drops; parts of a batch keep them.
2026-10-30 01:42:27 -04:00
Michael ButlerandCodex d74379858d Export: preserve optional binary transparency in animated GIFs (#3396) (#3423)
* #3396: preserve binary transparency in animated GIF exports

Enable Include Alpha Channel for GIF with an explicit 128/255 threshold. Cover transparent, opaque and partial-alpha pixels, frame disposal and the Export UI. Document the behavior and add the requested username-only contributor credit.

Co-Authored-By: Codex <noreply@openai.com>

* #3396: clarify when the GIF alpha threshold applies

Begin the export hint with "When enabled," and wrap the longer label so its explanation remains visible. Alpha behavior and threshold wording remain unchanged.

Co-Authored-By: Codex <noreply@openai.com>

* #3396: cover GIF transparency during palette quantization

Round-trip two frames with more than 256 post-conversion RGBA colors, a moving isolated transparent pixel, and opaque black and near-black neighbors. Require exact alpha and bounded RGB error. Document commands for the GIF and export test suites; leave the encoder unchanged.

Co-Authored-By: Codex <noreply@openai.com>

---------

Co-authored-by: Codex <noreply@openai.com>
2026-10-30 01:22:02 -04:00
Dylan M. Taylor 343ce0503f Refactor export for strict Clippy checks 2026-10-28 04:36:48 +00:00
ComfyChloeandOpenCode abd5287137 fix(export): a failed encoder factory does not stop the next one (#936)
make_venc walked the registered encoder factories with find_map, and
`Some(Err(..))` is a `Some`: a factory that failed ended the walk, and no
later factory was asked. That is wrong as soon as more than one factory
could take the export.

For H.264 the software encoder is the documented fallback (Export >
Hardware encoding: Auto: "use the hardware encoder when the system has one
and it takes the settings; otherwise the software encoder"). A hardware
factory that *declines* already answers None, so the walk continues; but a
factory that *failed* answered Some(Err(..)) and the export died instead
of falling back.

For H.265 there is no software encoder at all, so the next factory may be
the only one that can take the export. With a second hardware encoder
registered (Media Foundation, #2488) this is not hypothetical: on an NVIDIA
Windows machine the H.265 export failed with "opening the NVENC session
failed" and the Media Foundation encoder, which does work there, was never
asked.

The walk now continues past a factory that failed and reports the first
failure when no factory takes the export, so the message a user sees is
unchanged.

Co-authored-by: OpenCode (MiniMax M3.1 Flash) <noreply@opencode.ai>
2026-10-28 02:07:52 +00:00
NetterSilverandClaude Opus 5.5 69f8d63e6c Count H.264 conversion done ahead on the render threads as convert time
The convert stage counter stopped growing once the render threads
converted every frame ahead, which failed
determinism_tests::an_export_adds_up_the_wall_time_of_its_stages
under nextest (one process per test).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 18:16:09 +01:00
NetterSilverandClaude Opus 5.5 ef4a5f83f4 Take colour conversion off the H.264 export's critical path
- The H.264 encoder's RGBA -> 4:2:0 conversion runs on the render
  threads (VideoEncoder::prepare_ahead), which are idle while a batch is
  encoded; encode() picks the planes up by picture index and converts a
  picture itself when there are none (then on the encoder's own pool,
  not the busy global one).
- rgba_to_yuv420_8 uses per-code tables of the same products, rounds
  without roundf and works row by row so the divisions vectorise; the
  output is pinned against the float formula for all 2^24 colours.
- Full-size opaque 8-bit Y'CbCr -> linear conversion tabulates R' and
  B' per code pair with the expressions of the per-pixel loop.
- over_black_rgba8 fetches the sRGB table once per picture.

bench_export (1080p H.264 + AAC to H.264 + AAC, Ryzen 16 threads, 7
interleaved rounds) with the encoder change: median 7.86 s -> 6.14 s
(-21.9 %), min 7.78 s -> 6.02 s (-22.7 %). Same file (MD5) as
before, and the same for a ProRes export of the clip.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 17:42:52 +01:00
aiongg b9a5912628 refactor(export): split lib.rs into format, output, registry, stats, encoders, convert, still_encode and run 2026-10-26 18:28:12 +00:00
Dylan M. Taylor 7725f48673 refactor: clear S9045 and S107 new-code issues (#3336)
Move the test modules in whisper/tokenizer.rs and export/pipeline.rs to the
end of their files. Group the output path and optional open file in proxies.rs
into a Dest struct so transcode_with_file takes 7 parameters. Behaviour is unchanged.
2026-10-25 21:47:49 -04:00
Dylan M. Taylor de529c88f4 chore: resolve SonarCloud maintainability issues (#3329)
* chore: resolve SonarCloud maintainability issues

* fix: repair CI on the Sonar maintainability refactor

- h264: the coefficient scratch is i32, so the method path is <[i32]>::first_chunk_mut
- hevc: Px::w32 takes self, so keep the closure over the &P from slice::get
- tts: upsamples is a method, not an importable item
- vp8: drop the unused B_DC_PRED/DC_PRED imports; cargo fmt the import lists
- ui-egui: editing no longer needs to be mutable
- packaging: keep literal printf formats (shellcheck SC2059)

* fix: restore the mutable binding in hot_number
2026-10-25 19:40:57 -04:00
aiongg f819462589 Merge #1870: #1216: a cap on the CPU threads an export uses (maxThreads) 2026-10-25 12:33:07 +00:00
aiongg 7228abec42 Merge #1869: PNG Sequence writes RGB files when Include Alpha Channel is off 2026-10-25 12:33:06 +00:00
Earl Co 90327492a6 security(export): bound image overlay decoding (#2944) 2026-10-24 04:49:13 -04:00
aiongg 0a881266c8 CI: xtask ci in the dev profile, one test binary per crate, nextest (#2860)
* Tests: one integration-test binary per crate

Each crate with several tests/*.rs files keeps them as modules of tests/it/,
so cargo links one test executable per crate instead of one per file. Files
that change process-wide state or time a workload stay binaries of their own.

* Profiles: line tables for workspace crates, no debug info for dependencies

* Windows ARM64: nightly and on release pushes instead of every push to main

* xtask ci: clippy and tests in the dev profile

The release profile's thin LTO and single codegen unit made linking the test
binaries take most of the gate. The codec and audio crates stay at opt-level 3
in the dev profile, so their tests run at release speed.

* xtask ci: nextest, doctests, no examples, one wasm check

Tests run with cargo nextest when it is installed (cargo test otherwise) and
build with --lib --bins --tests, so examples aren't linked; doctests run
separately. The wasm check keeps going past the first failing crate. VP8
fixture generation locks across processes, since nextest runs each test in
its own.

* VP9 synthetic fixtures: write aside and rename

A test in another process could read a fixture ffmpeg was still writing.

* Fuzz tests: a third of each sweep by default, all of it with FILMCRAFT_FUZZ_ITERS

Every seed, mutation kind and thread count still runs. Header bytes each get
one overwrite value and two bit flips in rotation, so every value and bit
index still occurs across the region. FILMCRAFT_FUZZ_ITERS=N runs the whole
sweep plus N random rounds per seed, as before.

* Platform fallback tests: one failure point per hybrid path

The failure-anywhere test injected a failure at four points around every
restart point; the hybrid's paths differ only in the first GOP, around the
second and last restart points, at the end and never. The replay test needs
the first two GOPs.

* Export tests: shorter ranges with the same checks

The bitrate test measures 0.5–1.5 s, where each preset reaches its own
target (on 0–3 s the simple demo left two presets at the same rate). The
every-preset test exports three frames per preset.

* Audio tests: effects in parallel, a table-driven FFT for the Opus quality metric

The extreme-settings test keeps both settings and the 40 s tail for every
effect, one thread each. The Opus quality metric's FFT builds its twiddles
once and allocates nothing per transform (same algorithm and summation order).

* CI: dev-profile gate with nextest

xtask ci no longer builds with --release, so the release-profile overrides
go; nextest is installed for the test step.

* CI: apt packages through the cached install-apt-packages action

* Review fixes: fuzz tests with a panic hook in their own binaries, loud fixture lock

The fuzz tests of av1, h264, hevc, mpeg2v, vp8 and vp9 count panics through
a process-wide hook, so a panic in another test of the same process would
fail them; they are binaries of their own again. The VP8 fixture lock fails
the test instead of skipping it silently, and the full-sweep doc comments say
how many truncation points the full run samples.

* Fuzz tests: rotate the default subset per run (FILMCRAFT_FUZZ_SEED replays one)

* platform tests: decode-switch tests in their own binaries, one NVENC lock
2026-10-23 13:34:16 -04:00
04a4a7bc72 security(proxies): reserve outputs atomically (#2922)
* security(proxies): reserve outputs atomically

* proxies: ReservedOutput::file returns an Option instead of expect()

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Brandon Thomas <brandon@storyteller.ai>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 10:51:54 -04:00
Sam SandweissandClaude Opus 5.5 678fe73221 fix(export): tag SDR exports with a colr box (#2142)
ColorSignal::apply_to wrote the sample entry's colr box only for HDR, so
SDR ProRes, DNxHR and APV MOVs carried no colour that Apple's media stack
reads (it takes their colour only from colr, not from the codecs' frame
headers): QuickTime Player and Final Cut saw no primaries, transfer or
matrix. SDR exports now get colr with the export's colour too (nclc in
MOV, nclx in MP4); HDR metadata stays PQ-only.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-15 18:53:32 -07:00
Earl CoandCodex 8309f21a6c fix(export): prevent nested renderer-pool deadlocks
Bound outer export batches by actual renderer-pool capacity before nested Rayon work can steal a sibling frame. Cover image sequences, GIF, stepped export and overlapping audio with the original one-renderer regression.

Addresses #1956.

Full original GPU contribution preserved at `preserve/861-gpu-export-original` (674e8cd68d).

Co-authored-by: Codex <noreply@openai.com>
2026-10-14 23:05:50 -06:00
Guilherme Barbosa Ferrarezi 32b8577440 #1216: a cap on the CPU threads an export uses (ExportSettings::max_threads)
`ExportSettings::max_threads` (`maxThreads` in JSON, default 0 = all cores)
makes `export()` run on a dedicated rayon pool of that size when it is below the
pool the export is called in. Batch size, render-ahead, the renderer pool and the
parallel work of the software encoders follow it because they ask rayon for the
number of threads. A cap at or above the current pool changes nothing.

The commands that resolve export settings accept it as a flat parameter or inside
`settings`. The output does not depend on it. The decoders' and the H.264
encoder's own thread pools are not counted yet.
2026-10-14 08:56:17 -03:00
Marco Arnulfo e8d20a39e7 PNG Sequence writes RGB files when Include Alpha Channel is off (fixes #1863) 2026-10-14 13:41:30 +02:00
Brandon ThomasandClaude Opus 5.5 234b3454ef Export: as_chunks in the float-audio oracle test (clippy manual_chunks)
Follow-up to #1245.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 00:07:17 -04:00
Claude 6c13dda2bf export: 32-bit integer and 32-bit float audio; Sample Size lists every size and greys out the unsupported ones
- AudioSettings gains `float`; `bits` takes 16, 24 or 32. `SampleFormat` (Int16 / Int24 /
  Int32 / Float32) and `ExportSettings::supports_sample_format` decide what each codec and
  container stores: WAV, AIFF and QuickTime PCM all four, MXF integers, FLAC integers.
  `validate` refuses float without 32 bits and float in FLAC or MXF.
- WAV float is WAVE_FORMAT_IEEE_FLOAT (EXTENSIBLE for more than two channels) with a `fact`
  chunk; AIFF float is AIFF-C `fl32`; QuickTime float is `lpcm` with the float flag; MXF writes
  32-bit integers. Float keeps the mix as it is, peaks above 0 dBFS included; 16 and 24 bit
  write the same bytes as before.
- FLAC encoder: 8-32 bits. 32-bit stereo is coded independently (a side channel would need 33
  bits), the sample range check no longer overflows, and 32-bit frames point at STREAMINFO for
  the size, which symphonia 0.5 (FilmCraft's own FLAC import) and ffmpeg both read.
- Export mode: Sample Size shows 16 bit, 24 bit, 32 bit and 32 bit float like Audio Format
  does, greying out what the format cannot store with the reason on hover; a size that stops
  being available (float after switching to FLAC) becomes 32-bit integer. es, fr, pt-br, id,
  ja and zh-cn strings.
- Tests: writer layouts and ffprobe codecs for every new format, round trips through ffmpeg
  and FilmCraft's own readers in WAV, AIFF, MOV, MXF and FLAC, headroom of a +6 dB tone,
  refused combinations, full-scale 32-bit FLAC through ffmpeg (MD5 too) and symphonia, and a
  UI test of the selector.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015nzevSsTNZxHPpUngfGTAw
2026-10-12 05:42:44 +00:00
Brandon ThomasandClaude Opus 5.5 71ceebe857 Merge main into #879 (export schema next to FLAC, catalogs, parity table)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 22:01:41 -04:00
Brandon Thomas 8ec1a36b9f Merge pull request #613 from JordyUSA/feat/flac-export
Export: FLAC (clean-room encoder; .flac files and FLAC audio in MP4/MOV)
2026-10-11 21:02:50 -04:00
Brandon ThomasandClaude Opus 5.5 383fafea8e export: rustfmt settings tests after merging #1113
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 20:56:58 -04:00
Brandon Thomas 1b42e5b2f9 Merge pull request #957 from Ni-zav/fix/908-tiff-size-estimate-s20261011T0357Z-b83c
fix(export): estimate TIFF sequence size using the actual channel count
2026-10-11 20:34:35 -04:00
Brandon Thomas 5f922d8abe Merge pull request #872 from vangel76/fix-854-gif-frame-delays
#854: GIF frame delays add up to the sequence duration
2026-10-11 20:32:43 -04:00
JordyUSAandClaude Opus 5.5 773e1a3c72 Merge origin/main into feat/flac-export
Keep FLAC beside main's new AAC Audio format (21 formats, both audio-only
presets), use is_mp4_with / is_mp4_video in audio_codec() and the Audio
Format picker so MP4 (incl. AV1) offers AAC or FLAC, and add flacLevel to
main's export.media params.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 12:32:13 +07:00
Nigel Ihza Firdausy 8859e98fb7 export: estimate RGB TIFF sequence size from written channels 2026-10-11 11:09:25 +07:00
Earl Co 5d7dc800a8 M7: correct export loudness after peak limiting
Bound post-limiter loudness correction and cover high-crest signals, infeasible targets, cancellation, and output alignment. Focused tests and lint pass; full workspace validation pending for draft review.
2026-10-11 06:09:02 +02:00
vangel76andClaude Opus 5.5 d066f82e26 #874: compressed (RLE / ZIPS / ZIP) OpenEXR export
Problem: OpenEXR sequences (#806) were written uncompressed only, because the
workspace had no deflate encoder; the files are 2-4x larger than necessary and
Premiere offers an EXR compression choice.

Fix: a small clean-room DEFLATE (RFC 1951) encoder in a zlib (RFC 1950)
wrapper in filmcraft-export (greedy LZ77 with bounded hash chains; stored,
fixed or dynamic Huffman per block, whichever is smallest; length-limited
codes). The EXR writer gains RLE, ZIPS (1 line) and ZIP (16 lines) chunks with
the format's byte interleave + delta predictor; chunks that do not shrink are
stored raw. New ExportSettings::exr_compression (default None, as before),
`exrCompression` param on file.exportMedia, Compression combo in Export mode
(es/fr/ja/zh-cn strings).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 02:46:53 +02:00
vangel76andClaude Opus 5.5 7625ddf4de #854: GIF frame delays add up to the sequence duration
Problem: the GIF exporter gave every frame the same delay of
1000·den/num ms, which the encoder truncates to whole centiseconds.
At 24 fps each 41.67 ms frame became 4 cs, so a 4.0 s sequence played
in 3.84 s (4 % fast); other non-integer rates drifted the same way.

Fix: each frame's delay now runs from its rounded start time to the
next frame's (gif_delay_cs), so delays alternate (4, 4, 5, 4, 4, 4 cs
at 24 fps) and add up to the exact duration. Checked i128 math also
replaces the unchecked `(1000 * den) as u32` cast.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 02:22:09 +02:00
vangel76 f8f16b6eca Merge remote-tracking branch 'upstream/main' into gap-aac-audio
# Conflicts:
#	crates/engine/src/commands.rs
#	docs/gaps.md
2026-10-11 01:09:25 +02:00
Brandon ThomasandClaude Opus 5.5 f114b5f10c Revert #783 (Linux H.265 through NVENC): intermittent heap corruption in the CLI
With NVENC registered on Linux, `filmcraft-cli --test cli` aborts in 2 of 45 runs on an RTX 3090
(`malloc(): mismatching next->prev_size`, `malloc(): unaligned fastbin chunk detected`) right
after an export finishes; 0 of 30 runs fail with this reverted.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 19:01:15 -04:00
vangel76andClaude Opus 5.5 b9f60842bb #814: AAC Audio export (audio-only .m4a, or ADTS .aac)
Problem: Premiere's "AAC Audio" format has no FilmCraft equivalent. AAC
was only written inside H.264 / H.265 / AV1 movies; the only audio-only
exports were Waveform Audio and AIFF.

Fix: a new `aac` export format ("AAC Audio") that encodes the sequence
mix with the existing AAC-LC encoder into an MPEG-4 audio file (.m4a,
encoder delay in an edit list), or a raw ADTS stream when the path ends
in .aac. Bitrate, sample rate, channels and loudness normalisation follow
the audio settings. Adds an "AAC Audio 48 kHz 320 kbps" Audio Only
preset, CLI extension guessing (.m4a / .aac), es/fr/ja/zh-cn strings, and
updates G13 (also noting ProRes 4444 / XQ is already in the export UI).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 00:56:35 +02:00
vangel76andClaude Opus 5.5 fb5863bc8a #806: export OpenEXR image sequences
Problem: Premiere offers OpenEXR as an image-sequence export format;
FilmCraft could not write EXR at all (docs/gaps.md G13).

Fix: a new export format (id exr, "OpenEXR") writing numbered .exr stills,
with a preset, the Include Alpha Channel option, the file.exportMedia format
list and es/ja/zh-cn strings. The writer in crates/export/src/raster.rs
follows the public OpenEXR file layout: version 2 single-part scan-line
file, half-float B/G/R(/A) channels, no compression, one scan line per
chunk, Rec.709 chromaticities; values are scene-linear (the pipeline's
transfer undone) with premultiplied alpha, as EXR defines. No new
dependency. ZIP / PIZ / DWA compression stays open.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 00:34:28 +02:00
Brandon Thomas 257d7af4ab Merge pull request #791 from vangel76/gap-image-sequences
#779: export JPEG, Targa and DPX image sequences
2026-10-10 18:09:10 -04:00
vangel76andClaude Opus 5.5 c673ee85b9 #779: export JPEG, Targa and DPX image sequences
Problem: Premiere offers JPEG, Targa and DPX as image-sequence export
formats; FilmCraft only wrote PNG, TIFF and BMP sequences (docs/gaps.md G13).

Fix: three new export formats (ids jpg, tga, dpx), numbered like the other
sequences, with presets, the export UI (JPEG quality slider, Targa alpha)
and es/ja/zh-cn strings. JPEG uses the image crate at the export quality;
Targa (TGA 2.0, uncompressed 24/32-bit) and DPX (SMPTE ST 268, 10-bit RGB
method A, BT.709) are written by a small hostile-input-safe writer in
crates/export/src/raster.rs. Format::is_image_sequence replaces the
hand-kept format lists. OpenEXR stays open.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 23:51:41 +02:00
Brandon Thomas 662d9d07b1 Merge pull request #783 from SilentYeti/nvenc-hevc-linux
Linux: H.265 export through NVENC
2026-10-10 17:49:22 -04:00
SilentYetiandClaude Opus 5.5 c635d9af9e Linux: H.265 export through NVENC
The NVENC HEVC encoder (Main 8-bit SDR and Main 10 HDR PQ / HLG) was gated to
Windows. It now also runs on 64-bit Linux, on the CUDA device the H.264 encoder
already uses: the H.265 format and HDR probes are registered there and the
HEVC tests run on both systems.

NVENC registration on Linux now happens after the VA-API probe. Started beside
it, the background HEVC probe's first cuInit could deadlock with
libva-nvidia-driver, which calls cuInit from its library constructor under the
loader lock.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 14:41:04 -07:00
Brandon ThomasandClaude Opus 5.5 36cc163b44 Merge origin/main into #739: keep #600's CRF validation, and AV1 (hardware, like H.265) has no CRF mode either
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 17:15:40 -04:00
Brandon Thomas 74963e0e7e Merge pull request #760 from maccagnit/gpu-export-cpu-frames
GPU export: a frame planned as one CPU image skips the renderer pool (Auto was slower than Off)
2026-10-10 17:01:07 -04:00
Tommaso MaccagniandClaude Opus 5.5 13d8e73e8e export: a frame planned as one CPU image does not take a pooled GPU renderer
With GPU rendering on, a frame the planner hands back whole (an adjustment
layer, a complex transition, an HDR / wide-gamut sequence) was still rendered
by render_sequence, but inside RendererPool::with: as many frames at a time as
there are pooled renderers (2 to 4) instead of one per export thread. A
timeline graded on an adjustment layer exported slower with Auto than with Off.

Pipeline::frame asks the planner first (plan::is_cpu_frame, the test
plan_frame itself makes) and renders such a frame on the CPU directly. It
counts as a fallback now, not as a GPU frame. The picture does not change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 21:40:37 +02:00
vangel76 95a9a7770a Merge upstream/main into fix-342-prores-4444-export
# Conflicts:
#	crates/engine/src/commands.rs
2026-10-10 21:27:52 +02:00
Brandon Thomas 794a25fc9e Merge pull request #658 from vbasky/fix/current-bugs
Fix silent WAV sample-rate substitution
2026-10-10 14:57:13 -04:00
Brandon Thomas 97c39725cb Merge pull request #606 from JordyUSA/fix/pcm-large-files
Export: never crash on WAV/AIFF over 4 GiB; stream PCM to disk
2026-10-10 14:52:50 -04:00
Manuel CamachoandClaude Opus 5.5 7f4bf2157b HW6: AV1 export format, enabled where a hardware encoder registers one (#30)
Format::Av1 in export settings and jobs, SampleEntry::av1 (av01 + av1C) in
isobmff, and the Export panel's Format list, profile and encoder rows. No
encoder ships here: like H.265, AV1 is listed greyed out until a platform
encoder registers a probe, and a job without one fails with "AV1 encoder not
available yet". Split out of #409; the VA-API AV1 encoder follows on main's
vaapi::va design.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 10:46:43 -07:00