SPB Git

Repository Public License

conversion-engine-evaluation.md 10.3 KB

# Conversion engine evaluation

Environment audited on 2026-11-21: macOS 27.0 (26A5425a), Apple M5 Max (18 cores, 48 GB), Xcode 27.2, Swift 6.4.2, macOS SDK 27.2. Developer ID Application identity for team 3YM54G49SN present; notarytool keychain profile MacLustr-Notarize working. No earlier ORIX Convert existed locally or on the git server.

Decisions that apply to every engine:

  • Apple Silicon only (arm64), macOS 15.0 minimum. Bundled C libraries are built single-architecture. Nothing was run on macOS 15 or 26; every result below was measured on macOS 27.0.
  • Not sandboxed, Hardened Runtime. Helper executables need to be launched with arbitrary user files and LibreOffice needs allow-jit; the App Sandbox would add no protection the per-engine limits do not already give and would break the helper model. File access is still only what the user drops or picks.
  • Apple frameworks first; a third-party engine only where the frameworks cannot do the job. Every third-party component is bundled, built or fetched by a pinned script (EmbeddedEngines/<name>/), and listed in docs/licenses/dependency-license-report.md.
  • Library vs executable. Permissive libraries are linked (static xcframework, or a dylib for DuckDB). FFmpeg (LGPL), Pandoc (GPL) and LibreOffice (MPL) run as separate processes: that is what their licenses favour, and a crash or hang in a parser of untrusted media stays outside the app.

Sizes are as measured on disk after the build scripts ran. Performance figures are in each engine's document under docs/compatibility/engines/; the machine was heavily loaded by other work during every measurement.

# Engines adopted

Engine Used for Import / export License Build Size Security notes Known limits
ImageIO / Core Graphics / Core Image / vImage (system) Raster images Reads PNG, JPEG, HEIC/HEIF, WebP, AVIF, TIFF, BMP, GIF, APNG, ICO, ICNS, PSD, RAW/DNG, EXR, Radiance HDR, TGA, JPEG 2000, JPEG XL; writes the same minus WebP, RAW, DNG, JPEG XL Apple SDK none 0 Engine adds a decoded-pixel cap and strict container checks (ImageIO zero-fills several truncated formats) No WebP or JPEG XL encoder; no chroma-subsampling control; PSD layers flattened; AVIF encoder deadlocks on a saturated Swift cooperative pool (engine uses its own queue)
libwebp 1.6.0 WebP encode (lossy, lossless, alpha, animation) export BSD-3-Clause CMake, static xcframework 0.8 MB Statically linked, no I/O of its own 16383 px side limit
Own tracer (Swift) Raster → SVG / vector PDF export first-party none 0 Bounded regions/nodes Filled outlines only (no centerline tracing); photographs do not vectorise compactly
WebKit (system) SVG → PDF/PNG/JPEG/TIFF, HTML → PDF import Apple SDK none 0 JavaScript off, every remote load blocked (tested with a local listener) createPDF always paints an opaque page
FFmpeg 9.1 + LAME 3.100, libopus 1.6.1, libogg 1.3.6, libvorbis 1.3.7, libvpx 1.17.0, SVT-AV1 4.3.0, dav1d 1.5.5, zimg 3.0.6 Video and audio transcoding, remux, probing Decoders/demuxers: FFmpeg's LGPL set. Encoders/muxers: whitelist (see EmbeddedEngines/ffmpeg/NOTICE.md) LGPL-2.1+ build (no --enable-gpl, no nonfree); codecs BSD/LGPL/WTFPL from source, static codecs, ffmpeg + ffprobe executables linking only system libraries 28 MB + 28 MB Network and all protocols except file/pipe compiled out; argument arrays, no shell No x264/x265 (GPL): H.264/HEVC through VideoToolbox; no libass (no subtitle burn-in); no animated WebP
VideoToolbox / AudioToolbox / AVFoundation (system) Hardware H.264/HEVC/ProRes encode, AAC, MIDI synthesis, capability detection — Apple SDK none 0 — No AV1/VP9 hardware encoder on this Mac; MIDI uses the system sound bank only
Pandoc 3.14 Markdown, HTML, LaTeX, RST, EPUB, DOCX/ODT structure conversion both GPL-2.0-or-later official arm64 binary, unmodified, separate process 188 MB HTML/EPUB neutralised and RST/LaTeX includes resolved by the engine before Pandoc reads them (its readers otherwise fetch <iframe> targets and include arbitrary files) No PDF output of its own (needs TeX)
LibreOffice 26.8.3 (slimmed) DOC/DOCX/ODT/RTF layout conversion, → PDF, PPT/PPTX/ODP, XLS both MPL-2.0 (+ bundled third-party notices) official aarch64 build, slimmed 808 → 460 MiB, separate process 460 MB Throw-away profile per run; macros and active content disabled; link updates off; dead-end proxy; bundled Python, Java bridge, Basic libraries and update checker removed ~1.3–2.4 s per conversion (new process each time); needs allow-jit; rendering differs from Microsoft Office
NSAttributedString document readers/writers (system) Alternative backend for DOCX/DOC/RTF/ODT/HTML/TXT both Apple SDK none 0 — Drops images and footnotes, flattens tables on DOCX write; never the automatic choice
PDFKit / Core Graphics / Quartz / Vision (system) All PDF work, OCR both Apple SDK none 0 Permission flags of protected PDFs enforced No object-level rewriter: tags, attachments lost by page operations; compression goes through a Quartz filter
DuckDB 2.0.1 CSV/TSV/JSON/JSONL/Parquet/DuckDB files both MIT official libduckdb.dylib, thinned to arm64 62 MB Extensions never installed or loaded; session locked to the job's files; configuration locked SQLite/Excel/Arrow live in downloadable extensions and are therefore not used from DuckDB
SQLite (system libsqlite3) SQLite files, GeoPackage, history store both public domain (system) none 0 Sources opened read-only, defensive mode, trusted_schema off Views are listed, never executed
Yams 6.2.2 YAML both MIT SwiftPM source dependency compiled in Alias-bomb bound in the engine —
Own Swift codecs XLSX, ODS, Arrow IPC, TOML, exact JSON, ZIP, XML mapping, subtitles, sfnt/WOFF, STL/PLY/3MF/glTF/USDA writers, GeoJSON/KML/GPX/Shapefile/GeoPackage both first-party none 0 Bounded sizes, zip-bomb and entity limits, fuzz-style tests Listed per engine
libarchive 3.8.11 + xz 5.8.4 + zstd 1.5.7 Archives ZIP, 7z, TAR (+gz/bz2/xz/zst), single streams both ways; RAR read only BSD-2-Clause / 0BSD + BSD-3 CMake, static xcframework 2.2 MB External-program filters removed from the library; extraction is the engine's own openat(O_NOFOLLOW) code with bomb limits; xz 5.6.0/5.6.1 refused by the script No 7z/RAR decryption; gzip trailer and stored-RAR CRC not checked by libarchive (engine checks them itself); 7z creation is single-core
google/woff2 1.0.2 + brotli 1.2.1 WOFF2 both MIT static xcframework + C++ shim 1.0 MB Output bounded woff2's last release is from 2017
Assimp 6.0.2 OBJ, glTF/GLB, FBX, DAE import; DAE export import mostly BSD-3-Clause (+ MIT/zlib/BSL contrib) CMake, static xcframework, only 7 importers/exporters 7.9 MB Parses inside a helper process; a parser crash becomes an error FBX import unverified against real files; no Draco
Model I/O / SceneKit (system) USD family both Apple SDK none 0 Runs in the helper process Cannot author metersPerUnit in USDC
HDF5 2.2.0 (no netCDF library) HDF5 and NetCDF-4 through the HDF5 C library; NetCDF classic (CDF-1, CDF-2, CDF-5) read and written by the engine's own Swift code both (tables → HDF5 / NetCDF not offered) BSD-3-Clause CMake, static xcframework (libCHDF5.a 9 MB) 9 MB Plug-in loading disabled at build and run time; external links listed, never followed; a helper process (orix-hdf5-probe) opens each file first so that a hang or crash of the C library is contained No szip or third-party filters; the pre-check covers metadata and the first and last block of each dataset, the conversion then reads the data in-process; netcdf-c was not bundled (NetCDF-4 files are HDF5 files that follow conventions) — see scientific.md

# Evaluated and rejected

Candidate Why not
ImageMagick Apache-2.0 would be fine, but ImageIO + libwebp + own PNM/HDR/ICO codecs cover the listed formats with correct colour management and far less attack surface.
librsvg LGPL and a large dependency tree (GLib, Pango, Cairo). WebKit renders SVG with public API and no extra code.
Potrace / autotrace GPL. The tracer is the flagship feature and is written from scratch in Swift.
x264 / x265 / fdk-aac GPL or non-free; they would force a GPL FFmpeg. VideoToolbox and AudioToolbox encode H.264, HEVC and AAC.
FFmpeg as linked libraries LGPL static linking obligations and no crash isolation; the executable is replaceable by the user.
AVFoundation export sessions as the conversion backend Fewer containers and codecs, less control; kept for capability detection, hardware encoders (through FFmpeg) and MIDI.
Apache arrow-swift Builds, but pulls 21 packages and failed on pyarrow files with large_string and decimal columns. Own IPC reader/writer instead.
DuckDB extensions (sqlite, excel, arrow) They are downloaded at run time — forbidden here — and signing them would break their own signature check.
GDAL / PROJ Hundreds of megabytes with data files. Geospatial formats and a small tested set of projections are implemented in Swift; other CRSs are passed through unchanged or refused.
OpenUSD (Pixar) Too large to bundle; Model I/O reads and writes the USD family.
A TeX distribution Gigabytes. LaTeX → PDF is therefore not offered; LaTeX is a structural source/target through Pandoc.
Calibre GPL-3 Python application; EPUB work is done with Pandoc and the engine's own OPF reader.
A private CoreSVG / other private frameworks Private API, forbidden.
iWork (Pages, Keynote, Numbers) converters No documented local converter exists. None of 1 026 iWork packages on this Mac carried an embedded preview PDF, so even "extract preview" could not be tested. Not supported.

# Size

The bundled helpers dominate the app: LibreOffice 460 MB, Pandoc 188 MB, DuckDB 62 MB, FFmpeg + ffprobe 56 MB. The first Release build with eight engine packages measured 722 MB; the signed helper tools alone compress to 214 MB in a ZIP. Final figures are in RELEASE-REPORT.md.

Files main
Menu

Theme