## Description
Project description
PIPEWIRE's python controller (wrapper)
JOIN OUR TELEGRAM SUPPORT:
ONLY AUDIO BY NOW [PR & FR WELCOME]
Python controller, player and recorder via pipewire's commands.
- Pipewire is a project that aims to greatly improve handling of audio and video under Linux. (Better than pulseaudio or jack)
Requirements
-
A Pipewire version installed (clean or via Pulseaudio) is needed, to check if you have pipewire installed and running, run this command, if the output is different, you'll need to install pipewire:
- Pipewire versions supported: 0.3.30, 0.3.32+
pw-cli info 0
# Example output
id: 0
permissions: rwxm
type: PipeWire:Interface:Core/3
cookie: 134115873
user-name: "user"
host-name: "user"
version: "0.3.30" # Possibly more actual than this version
name: "pipewire-0"
...
To uninstall pipewire clic here.
- Python 3.7+
- Ubuntu 20.04+
Install & Tutorial
Install
pip3 install pipewire_python # or pip
Tutorial
PLAY AND RECORD
from pipewire_python.controller import Controller
# [PLAYBACK]: normal way
audio_controller = Controller()
audio_controller.set_config(rate=384000,
channels=2,
_format='f64',
volume=0.98,
quality=4)
audio_controller.playback(audio_filename='docs/beers.wav')
# [RECORD]: normal way
audio_controller = Controller()
audio_controller.record(audio_filename='docs/5sec_record.wav',
timeout_seconds=5)
GET INTERFACES
from pipewire_python.controller import Controller
audio_controller = Controller()
# Return all Client Interfaces on Pipewire
audio_controller.get_list_interfaces(
type_interfaces="Client",
filtered_by_type=True,
)
# Return all interfaces
audio_controller.get_list_interfaces(
filtered_by_type=False,
)
Documentation
You can check the automatic build documentation HERE
Roadmap
Future implementations, next steps, API implementation and Control over Pipewire directly from python in the ROADMAP.
Contributions
PR, FR, and issues are welcome. Changes with PR in dev
branch please due documentation runs after each commit in main
branch. Check more here
License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for pipewire_python-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2f7a117151ed4307994cc7f6bdf645b452e62fbc3d8d7fc773b9eb8f25802c6a |
|
MD5 | 7838294728d5ba8b8965f9137a8a17a7 |
|
BLAKE2b-256 | e262282f9b1fff806ca8fcb45f82e1f08493d0efe469529863217375ffa62f69 |