Repository navigation
Read MXF on macOS through the bundled FFmpeg - #23
Merged
Merged
Conversation
AVFoundation cannot open MXF, so on macOS Canon XF-AVC, Sony XAVC and other MXF clips were reported as "invalid PCM" and left out. The macOS engine now hands MXF, and only MXF, to the FFmpeg tier, which reads it exactly as the portable engine does elsewhere; every other format stays with AVFoundation. A missing FFmpeg on macOS leaves those files out with a warning instead of ending the run, as on 0.3.2. macOS releases build the same minimal LGPL FFmpeg as Linux and Windows, targeting the app's minimum macOS (15.0), and bundle ffmpeg and ffprobe beside the executables, with their license and corresponding source. Packaging rejects tools for another architecture or minimum macOS, or linking libraries outside macOS.
Merged
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.
Stacked on the #16 branch (
fix/damaged-audio-packets), whose portableengine sends MXF straight to FFmpeg without Symphonia's probe.
AVFoundation cannot open MXF. On macOS, Canon XF-AVC, Sony XAVC and other
MXF clips were reported as "Decode error: invalid PCM." and left out of
synchronization; macOS releases shipped no FFmpeg.
Changes:
inspection, analysis, refinement windows and native (export) decoding.
It reads them exactly as the portable engine does on Linux and Windows.
Every other format stays with AVFoundation.
On macOS, where development builds may lack it, MXF files are then left
out with a warning, as in 0.3.2, instead of stopping synchronization.
(
build-ffmpeg-minimal.sh, now withMACOSX_DEPLOYMENT_TARGET=15.0, theapp's
LSMinimumSystemVersion) and bundleffmpegandffprobeinAlign.app/Contents/MacOS, where both entry points already look forsidecars, with
FFMPEG-LICENSE.txtand the corresponding FFmpeg source inalign-source-macOS.tar.gz. About 7 MB.package-macos.sh(withBUNDLE_FFMPEG=1, as the release job now sets)rejects tools that are not arm64 built for macOS 15.0 (
lipo,vtool)or that link libraries outside
/usr/liband/System/Library. Thebundle is signed ad hoc with
--deep, which covers the tools.describe FFmpeg on macOS, including the local packaging command and that
the build manifest's hashes describe the tools before macOS re-signs them.
Verified locally:
CoreVideo and CoreMedia, and reads camera-original Canon EOS C70 XF-AVC,
Sony XAVC (4K, 8 tracks) and MPEG-2 MXF completely.
package-macos.shwithBUNDLE_FFMPEG=1packaged the app;codesign --verify --deep --strictpasses. The CLI insideAlign.app, run withPATH=/usr/bin:/binand the default macOS engine, synchronized the CanonC70 MXF with its recorder at the correct offset; 0.3.2 left it out with
"invalid PCM".
for arm64, macOS 27.2; need arm64, macOS 15.0") and accepts the rebuilt
one (
minos 15.0).ffprobebut noffmpeg, a development CLI on a cleanPATHsynchronizes the rest and warns about the MXF, instead of exiting with
"ffmpeg missing".
mxf_is_read_through_ffmpeg(macOS): the macOS engine inspects anMXF exactly like the portable engine and decodes it; with MXF routed to
AVFoundation it fails with "InvalidPcm".
missing_ffmpeg_ends_the_run_only_where_it_shipscovers the policy.cargo fmt,cargo clippy -D warnings,cargo test --workspace: 383passed, 1 ignored;
script/test-release-source.py; workflow YAML parses.Not verified here: the release job itself, which runs on a tag. It now
builds FFmpeg on the macOS runner, which already installs
nasm.