brawsource (beta)
Dual VapourSynth / AviSynth+ source plugin for Blackmagic RAW (.braw),
written in Zig against the official Blackmagic RAW SDK (CPU + GPU decode).
Frame-exact random access, audio, frame properties from clip/frame metadata.
- VapourSynth:
braw.Source+braw.AudioSource— Linux x64, Windows x64, macOS (x64/arm64) - AviSynth+:
BRAWSource(video + audio track) — Windows x64, AviSynth+ 3.6+ (interface V8)
Install
VapourSynth users can install straight from PyPI — runtime included, no DaVinci Resolve needed:
pip install vapoursynth-brawsource
The wheels are baseline x86-64; for the faster -v3 builds (AVX2/F16C)
or the AviSynth+ plugin, grab a release zip below.
System requirements: macOS 13.4+ with the release zips; PyPI wheels require
macOS 14+ because pip cannot express the runtime's 13.4 minimum. On Linux
the bundled runtime additionally needs the system libGL.so.1 (Mesa) and
libuuid.so.1 — present on practically every desktop distribution.
Runtime
The plugin loads the Blackmagic RAW runtime at run time. The release zips
are batteries-included: they ship the runtime in a
blackmagic_win_deps / blackmagic_linux_deps /
blackmagic_mac_deps folder next to the plugin — extract into your
plugin directory and you're done. For custom setups the same folder
convention works with your own copy of the runtime; alternatively an
installed Blackmagic RAW 6.0+ / a matching DaVinci Resolve runtime is found automatically, or use
the libpath parameter / BRAW_LIBRARY env var.
x86_64 builds come in two flavors: the plain one runs on any CPU, the
-v3 one (x86-64-v3: AVX2/F16C, Intel Haswell 2013+ / AMD Excavator+)
has noticeably faster pixel-copy loops — prefer it on any recent machine.
Usage
clip = core.braw.Source(source="clip.braw") # bit depth automatic
audio = core.braw.AudioSource(source="clip.braw")
BRAWSource("clip.braw", bitdepth=32) # AviSynth, audio attached
Parameters (both frameworks):
| Parameter | Description |
|---|---|
bitdepth |
8, 16 or 32 (32 = float). Unset = auto: 16-bit, or 32-bit float for Linear gamma. fp=true with 16 = half float (VapourSynth only) |
audio |
AviSynth only: attach audio track (default true) |
scale |
decode at 1/2/4/8 resolution |
pipeline |
VapourSynth only: decode on cpu (default), cuda (NVIDIA, Linux/Windows), metal (Apple GPU, macOS) or opencl (any OpenCL GPU — the option for AMD/Intel). On Apple Silicon metal is 1.7-2.7x faster and leaves the CPU nearly idle; CUDA helps mainly at high resolution; opencl sits between CPU and CUDA (~1.6x CPU on an RTX 3080). See doc/gpu-benchmark.md |
kelvin, tint, exposure, iso |
per-frame processing overrides |
gamma, gamut, colorscience |
color science overrides (e.g. gamma="Rec.709"); invalid values error at open |
highlightrecovery, gamutcompression |
processing toggles |
allmetaprops |
expose every metadata key as BRAW_<key> frame prop |
threads |
CPU decode threads (SetCPUThreads); 0 = all hardware threads. Lower it to leave cores free for downstream filters — the BRAW decoder otherwise saturates every core |
libpath |
Blackmagic RAW library file or directory |
Defaults decode "as shot": camera metadata plus an auto-applied
<clipname>.sidecar next to the file (reported via the
BRAWSidecarAttached prop; parameters override both).
Frame props: _DurationNum/Den, _AbsoluteTime, _Matrix, _Range (AviSynth: _ColorRange)
(+_Transfer/_Primaries when the gamma/gamut has a standard code), plus
BRAWTimecode, BRAWISO, BRAWWhiteBalanceKelvin/Tint, BRAWExposure,
camera/clip info as BRAW*. Inspect everything with
braw-probe --frame 0 --list-attrs --all-meta clip.braw (built by
zig build into zig-out/bin/; not part of the release packages).
Building
Zig 0.17.0; BRAW SDK headers and the AviSynth binding are vendored. The
binding includes a Zig 0.17 compatibility patch documented in
vendor/avisynth-zig/README.md. Other pinned build dependencies are
downloaded automatically on the first build.
zig build # plugins into zig-out/{vapoursynth,avisynth}, braw-probe into zig-out/bin
zig build test # unit tests
zig build release # all targets, ReleaseFast, into zig-out/release/
tools/extract-sdk.sh # unpack SDK/runtime into third_party/ (dev/tests)
The SDK extractor expects the Blackmagic RAW 6.0 Mac, Linux and Windows
archives in SDK-Sources/ and verifies them against tools/sdk-manifest.sha256.
Use tools/extract-sdk.sh --force to replace an extracted older SDK.
Development/test environment (Python 3.12+; VapourSynth R81RC1):
uv venv --python 3.13 encode_test/.venv
uv pip install --python encode_test/.venv/bin/python -r requirements-dev.txt
tools/build-oracle.sh
BRAW_TEST_STRICT=1 encode_test/.venv/bin/python test/python/test_source.py
Strict integration tests require the SDK and Portrait sample plus CUDA and OpenCL devices; missing fixtures or devices are reported as failures.
License
Plugin code: see LICENSE. Vendored SDK headers (vendor/) are Copyright
Blackmagic Design, license in their file headers. The Blackmagic RAW
runtime ("API Libraries") is explicitly redistributable together with
software built on the SDK (Blackmagic RAW SDK Developer License §1.1(d)),
so plugin bundles may ship it in the blackmagic_*_deps folder. This
repository just doesn't vendor the binaries — tools/extract-sdk.sh
unpacks them locally, or take them from a Blackmagic RAW install.
Metadata
Release files for vapoursynth-brawsource 0.5.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| vapoursynth_brawsource-0.5.0.tar.gz | 152.8 kB | Details |
Built distributions (wheels)
| File | Reset | |||
|---|---|---|---|---|
| vapoursynth_brawsource-0.5.0-py3-none-win_amd64.whl | Python 3 | none | Windows x86-64 | Details |
| vapoursynth_brawsource-0.5.0-py3-none-manylinux2014_x86_64.whl | Python 3 | none | Linux glibc 2.17+ x86-64 | Details |
| vapoursynth_brawsource-0.5.0-py3-none-macosx_14_0_x86_64.whl | Python 3 | none | macOS 14.0+ x86-64 | Details |
| vapoursynth_brawsource-0.5.0-py3-none-macosx_14_0_arm64.whl | Python 3 | none | macOS 14.0+ ARM64 | Details |
Total release size: 36.4 MB
Release files / vapoursynth_brawsource-0.5.0.tar.gz
| Download URL | vapoursynth_brawsource-0.5.0.tar.gz |
|---|---|
| Size | 152.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
55401d9b8a1cf31cb5c31d264b73c9e3b538b0415186cdc2a7d2c332363d48f1
|
|
BLAKE2b-256 checksum How to use checksums |
617c7239b476b7f1c4cfa1a15d17bc723dbd367e7f0baa1bc3eb2e96de007c1a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.20 {"installer":{"name":"uv","version":"0.12.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"CachyOS Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / vapoursynth_brawsource-0.5.0-py3-none-win_amd64.whl
| Download URL | vapoursynth_brawsource-0.5.0-py3-none-win_amd64.whl |
|---|---|
| Size | 6.9 MB |
| Tags | Python 3 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
5fe6766c26301b217dec28489eb6ba406bf150d7771289498686ee4c6cba34da
|
|
BLAKE2b-256 checksum How to use checksums |
54ac09fafec8acdc0258242c293c443df752366a1d8594ae7e937d1391a0709d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.20 {"installer":{"name":"uv","version":"0.12.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"CachyOS Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / vapoursynth_brawsource-0.5.0-py3-none-manylinux2014_x86_64.whl
| Download URL | vapoursynth_brawsource-0.5.0-py3-none-manylinux2014_x86_64.whl |
|---|---|
| Size | 6.9 MB |
| Tags | Linux glibc 2.17+ x86-64 Python 3 |
|
SHA-256 checksum How to use checksums |
0ccf3a3a259946696ee03bf06d27bc40605ea08d5a976de77821e4485249224a
|
|
BLAKE2b-256 checksum How to use checksums |
2d505572c5c6a06820b2ef2fd14baa0c91a0d7e6835b04cc20a30eb95e00e2c1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.20 {"installer":{"name":"uv","version":"0.12.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"CachyOS Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / vapoursynth_brawsource-0.5.0-py3-none-macosx_14_0_x86_64.whl
| Download URL | vapoursynth_brawsource-0.5.0-py3-none-macosx_14_0_x86_64.whl |
|---|---|
| Size | 11.2 MB |
| Tags | Python 3 macOS 14.0+ x86-64 |
|
SHA-256 checksum How to use checksums |
e0698b5bd5ffc6e822bc92e7a9aa336c9a56177b037bd7bdb70b90dc1f11237a
|
|
BLAKE2b-256 checksum How to use checksums |
3be34e2b10b724f7bdf018f2f94f30e65c1f048d89a028ba11e780b3974eaa23
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.20 {"installer":{"name":"uv","version":"0.12.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"CachyOS Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / vapoursynth_brawsource-0.5.0-py3-none-macosx_14_0_arm64.whl
| Download URL | vapoursynth_brawsource-0.5.0-py3-none-macosx_14_0_arm64.whl |
|---|---|
| Size | 11.2 MB |
| Tags | Python 3 macOS 14.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
d44c91acb33948853a3cdfca173c983fe5e1e40943b53dab50a0cda79ae9c943
|
|
BLAKE2b-256 checksum How to use checksums |
4f38d1c8af24d29ea1729dd0fc31f2693cbbe4e357a904e7b55ac47e29c96245
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.20 {"installer":{"name":"uv","version":"0.12.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"CachyOS Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|