v1.45.0

Vanilagy/mediabunnyv1.45.0May 13, 2026by Vanilagy

AI Summary

Major release introducing `@mediabunny/server` for server-side environments, new media sample resources, and a video transformation API.

Key Highlights

  • Introduced `@mediabunny/server` package for Node, Bun, and Deno.
  • Added `VideoSampleResource` and `AudioSampleResource` for custom data backing.
  • Added `VideoSample.transform()` for resizing, rotating, and cropping frames.
  • Added CPU-based alpha splitter/merger fallback.

New Features

  • Server-side package
  • Media sample resources
  • Video transformation API

Full Release Notes

## `@mediabunny/server`

This version adds a new extension package which enables you to use the full feature set of Mediabunny in server-side environments (Node, Bun, Deno). For more details, check out [the README](https://github.com/Vanilagy/mediabunny/blob/main/packages/server/README.md).

Usage:
```ts
import { registerMediabunnyServer } from '@mediabunny/server';
registerMediabunnyServer();
```

That's it - you now have access to all audio and video decoders and encoders, as well as video transformation capabilities, on the server.

## `mediabunny`

- Added media sample resources: `VideoSampleResource` and `AudioSampleResource` allow you to provide a custom data backing for `VideoSample` and `AudioSample` and avoid having to copy data around.
- Added `VideoSample.transform()`: A way to perform simple transformations on a video frame (resize, rotate, crop).
- Added `registerVideoSampleTransformer`, a function for registering a custom transformer to power `VideoSample.transform()`
- Added a CPU-based alpha splitter/merger fallback for transparent video encoding and decoding
- `VideoSample.allocationSize()` and `VideoSample.copyTo()` no longer throw if their format is `null` but a custom format override is provided in the options
- Increased the default cache size of `ReadableStreamSource` from 16 MiB to 32 MiB
- Fixed track process synchronization in the Conversion API; reads are now more sequential
- Fixed CMAF segments starting with a `sidx` box not being recognized (#369)
- Fixed incorrect timestamps of decoded audio in Chromium (#370, #371)
- Fixed media sample range iterators cutting off samples with negative timestamps by default
- Fixed FLAC demuxer erroring when seeking to negative timestamps