MPV plugins in Rust
Bindings for libmpv client API that allow you to create plugins for MPV in Rust.
⚠️ About this Fork: This is a maintained fork of the original TheCactusVert/mpv-client.
Key improvements in this fork:
- Windows Support: Added out-of-the-box support for Windows compilation (via MPV_CPLUGIN_DYNAMIC_SYM linkage-to-libmpv).
- No LLVM/Clang required: Uses pregenerated bindings by default, meaning you don't need
bindgenor a local LLVM installation duringcargo build.
Example
Here is an example for your Cargo.toml:
[]
= "mpv-plugin"
= "0.1.0"
= "2024"
[]
= "mpv_plugin"
= ["cdylib"]
[]
= { = "1.2", = "mpv-client-cross" }
And then the code src/lib.rs:
use ;
extern "C"