Skip to content

Commit

Permalink
ao_pipewire: Add PipeWire audio backend
Browse files Browse the repository at this point in the history
Based-on-patch-by: Oschowa <oschowa@web.de>
Based-on-patch-by: Andreas Kempf <aakempf@gmail.com>
  • Loading branch information
t-8ch committed Jan 6, 2022
1 parent 0e76372 commit ae7efa4
Show file tree
Hide file tree
Showing 7 changed files with 416 additions and 0 deletions.
13 changes: 13 additions & 0 deletions DOCS/man/ao.rst
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,19 @@ Available audio output drivers are:
Allow mpv to use PulseAudio even if the sink is suspended (default: no).
Can be useful if PulseAudio is running as a bridge to jack and mpv has its sink-input set to the one jack is using.

``pipewire``
PipeWire audio output driver

The following global options are supported by this audio output:

``--pipewire-buffer-samples=<n>``
Set the audio buffer size in samples. A higher value buffers
more data, and has a lower probability of buffer underruns. A smaller
value makes the audio stream react faster, e.g. to playback speed
changes.
The effective size of the buffer depends on the amount of buffered
samples and the samplerate.

``sdl``
SDL 1.2+ audio output driver. Should work on any platform supported by SDL
1.2, but may require the ``SDL_AUDIODRIVER`` environment variable to be set
Expand Down
4 changes: 4 additions & 0 deletions audio/out/ao.c
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ extern const struct ao_driver audio_out_audiounit;
extern const struct ao_driver audio_out_coreaudio;
extern const struct ao_driver audio_out_coreaudio_exclusive;
extern const struct ao_driver audio_out_rsound;
extern const struct ao_driver audio_out_pipewire;
extern const struct ao_driver audio_out_pulse;
extern const struct ao_driver audio_out_jack;
extern const struct ao_driver audio_out_openal;
Expand Down Expand Up @@ -87,6 +88,9 @@ static const struct ao_driver * const audio_out_drivers[] = {
#endif
#if HAVE_SDL2_AUDIO
&audio_out_sdl,
#endif
#if HAVE_PIPEWIRE
&audio_out_pipewire,
#endif
&audio_out_null,
#if HAVE_COREAUDIO
Expand Down
Loading

0 comments on commit ae7efa4

Please sign in to comment.