7 releases

0.1.6 Aug 4, 2023
0.1.5 Aug 2, 2023
0.1.3 Jul 31, 2023

#385 in Audio

Download history 6/week @ 2024-02-16 29/week @ 2024-02-23 9/week @ 2024-03-01 2/week @ 2024-03-08 1/week @ 2024-03-15 50/week @ 2024-03-29

53 downloads per month

MIT license

570KB
15K SLoC

Docs Build

Bindings for PipeWire

Overview

This crate provides Rust wrappers for the PipeWire APIs.

The main goal is to cover as many as possible PipeWire functionality with less code using macro and traits for unification.

Status

The library is not finished and not tested properly.

If you are looking for stable bindings, check the pipewire-rs crate.

Contributing

Any help is welcome.


lib.rs:

Docs Build

Overview

The crate structure is close to the PipeWire API structure, so PipeWire Documentation can be used to clarify some aspects of the bindings.

Examples

use pipewire_wrapper::core_api::main_loop::MainLoop;
use std::time::Duration;
let main_loop = MainLoop::default();

let callback = |_expirations| {
    main_loop.quit().unwrap();
};
let timer = main_loop.get_loop().add_timer(Box::new(callback)).unwrap();
main_loop
    .get_loop()
    .update_timer(&timer, Duration::from_secs(1), Duration::ZERO, false)
    .unwrap();
main_loop.run().unwrap();

More examples can be found in examples folder.

Dependencies

~1.3–4.5MB
~80K SLoC