COOLJAPAN
← All posts

OxiMedia 0.1.1 Released — FFmpeg CLI Compatibility and an OpenCV cv2 API in Pure Rust

OxiMedia 0.1.1 is a pure-Rust FFmpeg + OpenCV replacement. This release adds a drop-in FFmpeg CLI compatibility layer (oximedia-ff), an OpenCV cv2 Python API, a complete MP4 demuxer and end-to-end transcode pipeline, a plugin system, and FFV1/JPEG-XL/DNG/Y4M support — 97 crates and ~1.49M SLoC of pure Rust.

release oximedia ffmpeg opencv computer-vision video-transcoding pure-rust wasm

Swap into your FFmpeg and OpenCV workflows without ever touching a C toolchain again.

Today we released OxiMedia 0.1.1 — a pure-Rust reconstruction of FFmpeg and OpenCV, now with a drop-in FFmpeg CLI compatibility layer, an OpenCV cv2 Python API, a complete MP4 demuxer, and a real end-to-end transcode pipeline.

No C. No C++. No FFmpeg binaries. No OpenCV .so files. No pkg-config, no brew install, no autotools. OxiMedia is one unified multimedia and computer-vision framework written entirely in safe Rust — unsafe_code = "deny" across every one of its 97 crates — that compiles to a single static binary or to WebAssembly and runs everywhere. It ships royalty-free codecs only (AV1, VP9, VP8, Theora, Opus, Vorbis, FLAC, MP3), so there are no patent royalties to chase down and no licensed libraries to vendor.

Why 0.1.1 matters

Anyone who has shipped a media or vision pipeline knows the pain. FFmpeg and OpenCV are C/C++ build hell: pkg-config hunting for the right .pc files, brew install ffmpeg opencv pinning you to a system layout, patent-encumbered codecs that complicate distribution, and Python bindings that bottleneck on FFI marshalling. Reproducing a build across CI runners, containers, and a teammate’s laptop can eat a whole afternoon.

OxiMedia 0.1.1 attacks that directly. The new FFmpeg CLI compatibility layer gives you a drop-in oximedia-ff binary that understands FFmpeg-style arguments for common transcode, streaming, and filter workflows — 80+ codec mappings — so existing shell scripts can switch over with little to no rewriting. The new OpenCV cv2 Python API exposes 18 modules aligned to the OpenCV Python interface (imread, imwrite, resize, cvtColor, VideoCapture, VideoWriter, and more), letting you port OpenCV-Python code onto a pure-Rust backend. Together they mean you can move into your existing FFmpeg and OpenCV workflows without a C toolchain anywhere in the picture.

Technical Deep Dive

Foundation. OxiMedia is layered. oximedia-core, oximedia-io, oximedia-codec, and oximedia-container form the base: frame and packet types, async I/O, codec implementations, and demuxers/muxers. Everything is async-first on Tokio, so transcode and streaming work is built around real task scheduling rather than blocking calls. This release lands a complete MP4 demuxerprobe and read_packet are fully implemented in oximedia-container, enabling reliable MP4/MOV source reading — alongside a new Y4M container for raw YUV in and out.

The FFmpeg compat layer. The new oximedia-compat-ffmpeg crate plus the oximedia-ff binary translate FFmpeg CLI arguments into OxiMedia’s native pipeline, covering common transcode/streaming/filter invocations with 80+ codec mappings. Behind it sits the new transcode pipeline in oximedia-transcode: an end-to-end demux→filter→encode→mux flow with backpressure and async task scheduling.

The Python / cv2 surface. oximedia-py now ships the oximedia.cv2 submodule, an OpenCV-Python-aligned surface across 18 modules. It is the bridge for teams with existing OpenCV-Python code who want a pure-Rust engine underneath.

The plugin system. The new oximedia-plugin crate introduces a CodecPlugin trait, a PluginRegistry, a StaticPlugin builder, a declare_plugin! macro, and JSON manifests. Static plugins are the default; a dynamic-loading feature gate enables shared-library codecs when you need them.

Codec and image additions. This release adds the FFV1 lossless video codec (decoder + encoder, range coder, Golomb-Rice, multi-plane), the next-gen JPEG-XL image codec (decoder + encoder, modular transform, entropy coding, progressive), and the DNG Digital Negative RAW format (reader + writer, TIFF/IFD parsing, CFA demosaicing, color calibration). All of it lands on a green-list, royalty-free codec stance in a zero-unsafe workspace.

Getting Started

Add the crate:

cargo add oximedia

Use the FFmpeg-style CLI to inspect and transcode media:

# Probe a file's format and streams
cargo run --bin oximedia -- probe -i video.webm

# Transcode to AV1 in a WebM container
cargo run --bin oximedia -- transcode -i input.mkv -o output.webm --codec av1

Or drive the transcode pipeline from Rust:

use oximedia::prelude::*;

#[tokio::main]
async fn main() -> Result<()> {
    // Probe a format from in-memory bytes
    let data = std::fs::read("input.mkv")?;
    let format = probe_format(&data)?;
    println!("Detected format: {format:?}");

    // Build and run an end-to-end transcode pipeline
    let pipeline = TranscodePipeline::builder()
        .input("input.mkv")
        .video_codec(VideoCodec::Av1)
        .audio_codec(AudioCodec::Opus)
        .output("output.webm")
        .build()?;

    pipeline.run().await?;
    Ok(())
}

What’s New in 0.1.1

Tips

Part of the COOLJAPAN ecosystem

OxiMedia builds on pure-Rust COOLJAPAN foundations: SciRS2 (scirs2-core) supplies the tensor and signal math under the codecs and filters, and OxiARC (oxiarc-archive) provides pure-Rust compression — no zip, flate2, or C codec libraries anywhere in the stack. It is part of the broader COOLJAPAN ecosystem of C/C++/Fortran-free Rust libraries.

Repository: https://github.com/cool-japan/oximedia

Star the repo if pure-Rust media and computer vision is something you want to see more of.

Pure Rust media and computer vision is here — fast, safe, and sovereign.

KitaSan at COOLJAPAN OÜ March 10, 2026

↑ Back to all posts