2019-03-09 01:34:12 +03:00
|
|
|
# -*- mode: python -*-
|
2021-12-20 17:56:24 +03:00
|
|
|
# vim: filetype=python
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# Copyright (C) 2015-2019 Zoltán Kővágó <DirtY.iCE.hu@gmail.com>
|
|
|
|
#
|
|
|
|
# This work is licensed under the terms of the GNU GPL, version 2 or later.
|
|
|
|
# See the COPYING file in the top-level directory.
|
|
|
|
|
2020-11-02 11:15:50 +03:00
|
|
|
##
|
|
|
|
# = Audio
|
|
|
|
##
|
|
|
|
|
2019-03-09 01:34:12 +03:00
|
|
|
##
|
|
|
|
# @AudiodevPerDirectionOptions:
|
|
|
|
#
|
|
|
|
# General audio backend options that are used for both playback and
|
|
|
|
# recording.
|
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @mixing-engine: use QEMU's mixing engine to mix all streams inside
|
|
|
|
# QEMU and convert audio formats when not supported by the
|
|
|
|
# backend. When set to off, fixed-settings must be also off
|
|
|
|
# (default on, since 4.2)
|
audio: add mixing-engine option (documentation)
This will allow us to disable mixeng when we use a decent backend.
Disabling mixeng have a few advantages:
* we no longer convert the audio output from one format to another, when
the underlying audio system would just convert it to a third format.
We no longer convert, only the underlying system, when needed.
* the underlying system probably has better resampling and sample format
converting methods anyway...
* we may support formats that the mixeng currently does not support (S24
or float samples, more than two channels)
* when using an audio server (like pulseaudio) different sound card
outputs will show up as separate streams, even if we use only one
backend
Disadvantages:
* audio capturing no longer works (wavcapture, and vnc audio extension)
* some backends only support a single playback stream or very picky
about the audio format. In this case we can't disable mixeng.
Originally thw two main use cases of the disabled option was: using
unsupported audio formats (5.1 and 7.1 audio) and having different
pulseaudio streams per audio frontend. Since we can have multiple
-audiodevs, the latter is not that important, so currently you only need
this option if you want to use 5.1 or 7.1 audio (implemented in a later
patch), otherwise it's probably better to stick to the old and tried
mixeng, since it's less picky about the backends.
The ideal solution would be to port as much as possible to gstreamer,
but this is currently out of scope:
https://wiki.qemu.org/Internships/ProjectIdeas/AudioGStreamer
Signed-off-by: Kővágó, Zoltán <DirtY.iCE.hu@gmail.com>
Message-id: 5765186a7aadd51a72bc7d3e804307f0ee8a34ce.1570996490.git.DirtY.iCE.hu@gmail.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2019-10-13 22:57:58 +03:00
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @fixed-settings: use fixed settings for host input/output. When
|
|
|
|
# off, frequency, channels and format must not be specified
|
|
|
|
# (default true)
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @frequency: frequency to use when using fixed settings (default
|
|
|
|
# 44100)
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# @channels: number of channels when using fixed settings (default 2)
|
|
|
|
#
|
|
|
|
# @voices: number of voices to use (default 1)
|
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @format: sample format to use when using fixed settings (default
|
|
|
|
# s16)
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# @buffer-length: the buffer length in microseconds
|
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevPerDirectionOptions',
|
|
|
|
'data': {
|
audio: add mixing-engine option (documentation)
This will allow us to disable mixeng when we use a decent backend.
Disabling mixeng have a few advantages:
* we no longer convert the audio output from one format to another, when
the underlying audio system would just convert it to a third format.
We no longer convert, only the underlying system, when needed.
* the underlying system probably has better resampling and sample format
converting methods anyway...
* we may support formats that the mixeng currently does not support (S24
or float samples, more than two channels)
* when using an audio server (like pulseaudio) different sound card
outputs will show up as separate streams, even if we use only one
backend
Disadvantages:
* audio capturing no longer works (wavcapture, and vnc audio extension)
* some backends only support a single playback stream or very picky
about the audio format. In this case we can't disable mixeng.
Originally thw two main use cases of the disabled option was: using
unsupported audio formats (5.1 and 7.1 audio) and having different
pulseaudio streams per audio frontend. Since we can have multiple
-audiodevs, the latter is not that important, so currently you only need
this option if you want to use 5.1 or 7.1 audio (implemented in a later
patch), otherwise it's probably better to stick to the old and tried
mixeng, since it's less picky about the backends.
The ideal solution would be to port as much as possible to gstreamer,
but this is currently out of scope:
https://wiki.qemu.org/Internships/ProjectIdeas/AudioGStreamer
Signed-off-by: Kővágó, Zoltán <DirtY.iCE.hu@gmail.com>
Message-id: 5765186a7aadd51a72bc7d3e804307f0ee8a34ce.1570996490.git.DirtY.iCE.hu@gmail.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2019-10-13 22:57:58 +03:00
|
|
|
'*mixing-engine': 'bool',
|
2019-03-09 01:34:12 +03:00
|
|
|
'*fixed-settings': 'bool',
|
|
|
|
'*frequency': 'uint32',
|
|
|
|
'*channels': 'uint32',
|
|
|
|
'*voices': 'uint32',
|
|
|
|
'*format': 'AudioFormat',
|
|
|
|
'*buffer-length': 'uint32' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevGenericOptions:
|
|
|
|
#
|
|
|
|
# Generic driver-specific options.
|
|
|
|
#
|
|
|
|
# @in: options of the capture stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevGenericOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevPerDirectionOptions',
|
|
|
|
'*out': 'AudiodevPerDirectionOptions' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevAlsaPerDirectionOptions:
|
|
|
|
#
|
|
|
|
# Options of the ALSA backend that are used for both playback and
|
|
|
|
# recording.
|
|
|
|
#
|
|
|
|
# @dev: the name of the ALSA device to use (default 'default')
|
|
|
|
#
|
|
|
|
# @period-length: the period length in microseconds
|
|
|
|
#
|
|
|
|
# @try-poll: attempt to use poll mode, falling back to non-polling
|
2023-04-28 13:54:29 +03:00
|
|
|
# access on failure (default true)
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevAlsaPerDirectionOptions',
|
|
|
|
'base': 'AudiodevPerDirectionOptions',
|
|
|
|
'data': {
|
|
|
|
'*dev': 'str',
|
|
|
|
'*period-length': 'uint32',
|
|
|
|
'*try-poll': 'bool' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevAlsaOptions:
|
|
|
|
#
|
|
|
|
# Options of the ALSA audio backend.
|
|
|
|
#
|
|
|
|
# @in: options of the capture stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
|
|
|
# @threshold: set the threshold (in microseconds) when playback starts
|
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevAlsaOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevAlsaPerDirectionOptions',
|
|
|
|
'*out': 'AudiodevAlsaPerDirectionOptions',
|
|
|
|
'*threshold': 'uint32' } }
|
|
|
|
|
2022-09-07 16:23:42 +03:00
|
|
|
##
|
|
|
|
# @AudiodevSndioOptions:
|
|
|
|
#
|
|
|
|
# Options of the sndio audio backend.
|
|
|
|
#
|
|
|
|
# @in: options of the capture stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
|
|
|
# @dev: the name of the sndio device to use (default 'default')
|
|
|
|
#
|
|
|
|
# @latency: play buffer size (in microseconds)
|
|
|
|
#
|
|
|
|
# Since: 7.2
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevSndioOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevPerDirectionOptions',
|
|
|
|
'*out': 'AudiodevPerDirectionOptions',
|
|
|
|
'*dev': 'str',
|
|
|
|
'*latency': 'uint32'} }
|
|
|
|
|
2019-03-09 01:34:12 +03:00
|
|
|
##
|
|
|
|
# @AudiodevCoreaudioPerDirectionOptions:
|
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# Options of the Core Audio backend that are used for both playback
|
|
|
|
# and recording.
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# @buffer-count: number of buffers
|
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevCoreaudioPerDirectionOptions',
|
|
|
|
'base': 'AudiodevPerDirectionOptions',
|
|
|
|
'data': {
|
|
|
|
'*buffer-count': 'uint32' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevCoreaudioOptions:
|
|
|
|
#
|
|
|
|
# Options of the coreaudio audio backend.
|
|
|
|
#
|
|
|
|
# @in: options of the capture stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevCoreaudioOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevCoreaudioPerDirectionOptions',
|
|
|
|
'*out': 'AudiodevCoreaudioPerDirectionOptions' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevDsoundOptions:
|
|
|
|
#
|
|
|
|
# Options of the DirectSound audio backend.
|
|
|
|
#
|
|
|
|
# @in: options of the capture stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @latency: add extra latency to playback in microseconds (default
|
|
|
|
# 10000)
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevDsoundOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevPerDirectionOptions',
|
|
|
|
'*out': 'AudiodevPerDirectionOptions',
|
|
|
|
'*latency': 'uint32' } }
|
|
|
|
|
2020-04-29 08:53:58 +03:00
|
|
|
##
|
|
|
|
# @AudiodevJackPerDirectionOptions:
|
|
|
|
#
|
|
|
|
# Options of the JACK backend that are used for both playback and
|
|
|
|
# recording.
|
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @server-name: select from among several possible concurrent server
|
|
|
|
# instances (default: environment variable $JACK_DEFAULT_SERVER if
|
|
|
|
# set, else "default")
|
2020-04-29 08:53:58 +03:00
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @client-name: the client name to use. The server will modify this
|
|
|
|
# name to create a unique variant, if needed unless @exact-name is
|
|
|
|
# true (default: the guest's name)
|
2020-04-29 08:53:58 +03:00
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @connect-ports: if set, a regular expression of JACK client port
|
|
|
|
# name(s) to monitor for and automatically connect to
|
2020-04-29 08:53:58 +03:00
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @start-server: start a jack server process if one is not already
|
|
|
|
# present (default: false)
|
2020-04-29 08:53:58 +03:00
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @exact-name: use the exact name requested otherwise JACK
|
|
|
|
# automatically generates a unique one, if needed (default: false)
|
2020-04-29 08:53:58 +03:00
|
|
|
#
|
|
|
|
# Since: 5.1
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevJackPerDirectionOptions',
|
|
|
|
'base': 'AudiodevPerDirectionOptions',
|
|
|
|
'data': {
|
|
|
|
'*server-name': 'str',
|
|
|
|
'*client-name': 'str',
|
|
|
|
'*connect-ports': 'str',
|
|
|
|
'*start-server': 'bool',
|
|
|
|
'*exact-name': 'bool' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevJackOptions:
|
|
|
|
#
|
|
|
|
# Options of the JACK audio backend.
|
|
|
|
#
|
|
|
|
# @in: options of the capture stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
|
|
|
# Since: 5.1
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevJackOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevJackPerDirectionOptions',
|
|
|
|
'*out': 'AudiodevJackPerDirectionOptions' } }
|
|
|
|
|
2019-03-09 01:34:12 +03:00
|
|
|
##
|
|
|
|
# @AudiodevOssPerDirectionOptions:
|
|
|
|
#
|
|
|
|
# Options of the OSS backend that are used for both playback and
|
|
|
|
# recording.
|
|
|
|
#
|
|
|
|
# @dev: file name of the OSS device (default '/dev/dsp')
|
|
|
|
#
|
|
|
|
# @buffer-count: number of buffers
|
|
|
|
#
|
|
|
|
# @try-poll: attempt to use poll mode, falling back to non-polling
|
2023-04-28 13:54:29 +03:00
|
|
|
# access on failure (default true)
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevOssPerDirectionOptions',
|
|
|
|
'base': 'AudiodevPerDirectionOptions',
|
|
|
|
'data': {
|
|
|
|
'*dev': 'str',
|
|
|
|
'*buffer-count': 'uint32',
|
|
|
|
'*try-poll': 'bool' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevOssOptions:
|
|
|
|
#
|
|
|
|
# Options of the OSS audio backend.
|
|
|
|
#
|
|
|
|
# @in: options of the capture stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
|
|
|
# @try-mmap: try using memory-mapped access, falling back to
|
2023-04-28 13:54:29 +03:00
|
|
|
# non-memory-mapped access on failure (default true)
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @exclusive: open device in exclusive mode (vmix won't work) (default
|
|
|
|
# false)
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# @dsp-policy: set the timing policy of the device (between 0 and 10,
|
2023-04-28 13:54:29 +03:00
|
|
|
# where smaller number means smaller latency but higher CPU usage)
|
|
|
|
# or -1 to use fragment mode (option ignored on some platforms)
|
|
|
|
# (default 5)
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevOssOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevOssPerDirectionOptions',
|
|
|
|
'*out': 'AudiodevOssPerDirectionOptions',
|
|
|
|
'*try-mmap': 'bool',
|
|
|
|
'*exclusive': 'bool',
|
|
|
|
'*dsp-policy': 'uint32' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevPaPerDirectionOptions:
|
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# Options of the Pulseaudio backend that are used for both playback
|
|
|
|
# and recording.
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# @name: name of the sink/source to use
|
|
|
|
#
|
2019-09-11 02:26:20 +03:00
|
|
|
# @stream-name: name of the PulseAudio stream created by qemu. Can be
|
2023-04-28 13:54:29 +03:00
|
|
|
# used to identify the stream in PulseAudio when you create
|
|
|
|
# multiple PulseAudio devices or run multiple qemu instances
|
|
|
|
# (default: audiodev's id, since 4.2)
|
2019-09-11 02:26:20 +03:00
|
|
|
#
|
2019-03-15 11:46:52 +03:00
|
|
|
# @latency: latency you want PulseAudio to achieve in microseconds
|
2023-04-28 13:54:29 +03:00
|
|
|
# (default 15000)
|
2019-03-15 11:46:52 +03:00
|
|
|
#
|
2019-03-09 01:34:12 +03:00
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevPaPerDirectionOptions',
|
|
|
|
'base': 'AudiodevPerDirectionOptions',
|
|
|
|
'data': {
|
2019-03-15 11:46:52 +03:00
|
|
|
'*name': 'str',
|
2019-09-11 02:26:20 +03:00
|
|
|
'*stream-name': 'str',
|
2019-03-15 11:46:52 +03:00
|
|
|
'*latency': 'uint32' } }
|
2019-03-09 01:34:12 +03:00
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevPaOptions:
|
|
|
|
#
|
|
|
|
# Options of the PulseAudio audio backend.
|
|
|
|
#
|
|
|
|
# @in: options of the capture stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
|
|
|
# @server: PulseAudio server address (default: let PulseAudio choose)
|
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevPaOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevPaPerDirectionOptions',
|
|
|
|
'*out': 'AudiodevPaPerDirectionOptions',
|
|
|
|
'*server': 'str' } }
|
|
|
|
|
2023-04-17 13:56:54 +03:00
|
|
|
##
|
|
|
|
# @AudiodevPipewirePerDirectionOptions:
|
|
|
|
#
|
2023-05-06 19:37:26 +03:00
|
|
|
# Options of the PipeWire backend that are used for both playback and
|
2023-04-17 13:56:54 +03:00
|
|
|
# recording.
|
|
|
|
#
|
|
|
|
# @name: name of the sink/source to use
|
|
|
|
#
|
2023-05-06 19:37:26 +03:00
|
|
|
# @stream-name: name of the PipeWire stream created by qemu. Can be
|
|
|
|
# used to identify the stream in PipeWire when you create multiple
|
|
|
|
# PipeWire devices or run multiple qemu instances (default:
|
2023-04-28 13:54:29 +03:00
|
|
|
# audiodev's id)
|
2023-04-17 13:56:54 +03:00
|
|
|
#
|
2023-05-06 19:37:26 +03:00
|
|
|
# @latency: latency you want PipeWire to achieve in microseconds
|
2023-04-28 13:54:29 +03:00
|
|
|
# (default 46000)
|
2023-04-17 13:56:54 +03:00
|
|
|
#
|
|
|
|
# Since: 8.1
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevPipewirePerDirectionOptions',
|
|
|
|
'base': 'AudiodevPerDirectionOptions',
|
|
|
|
'data': {
|
|
|
|
'*name': 'str',
|
|
|
|
'*stream-name': 'str',
|
|
|
|
'*latency': 'uint32' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevPipewireOptions:
|
|
|
|
#
|
2023-05-06 19:37:26 +03:00
|
|
|
# Options of the PipeWire audio backend.
|
2023-04-17 13:56:54 +03:00
|
|
|
#
|
|
|
|
# @in: options of the capture stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
|
|
|
# Since: 8.1
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevPipewireOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevPipewirePerDirectionOptions',
|
|
|
|
'*out': 'AudiodevPipewirePerDirectionOptions' } }
|
|
|
|
|
2021-01-10 13:02:19 +03:00
|
|
|
##
|
|
|
|
# @AudiodevSdlPerDirectionOptions:
|
|
|
|
#
|
|
|
|
# Options of the SDL audio backend that are used for both playback and
|
|
|
|
# recording.
|
|
|
|
#
|
|
|
|
# @buffer-count: number of buffers (default 4)
|
|
|
|
#
|
|
|
|
# Since: 6.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevSdlPerDirectionOptions',
|
|
|
|
'base': 'AudiodevPerDirectionOptions',
|
|
|
|
'data': {
|
|
|
|
'*buffer-count': 'uint32' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevSdlOptions:
|
|
|
|
#
|
|
|
|
# Options of the SDL audio backend.
|
|
|
|
#
|
|
|
|
# @in: options of the recording stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
|
|
|
# Since: 6.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevSdlOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevSdlPerDirectionOptions',
|
|
|
|
'*out': 'AudiodevSdlPerDirectionOptions' } }
|
|
|
|
|
2019-03-09 01:34:12 +03:00
|
|
|
##
|
|
|
|
# @AudiodevWavOptions:
|
|
|
|
#
|
|
|
|
# Options of the wav audio backend.
|
|
|
|
#
|
|
|
|
# @in: options of the capture stream
|
|
|
|
#
|
|
|
|
# @out: options of the playback stream
|
|
|
|
#
|
|
|
|
# @path: name of the wav file to record (default 'qemu.wav')
|
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'struct': 'AudiodevWavOptions',
|
|
|
|
'data': {
|
|
|
|
'*in': 'AudiodevPerDirectionOptions',
|
|
|
|
'*out': 'AudiodevPerDirectionOptions',
|
|
|
|
'*path': 'str' } }
|
|
|
|
|
|
|
|
##
|
|
|
|
# @AudioFormat:
|
|
|
|
#
|
|
|
|
# An enumeration of possible audio formats.
|
|
|
|
#
|
2020-03-08 22:33:16 +03:00
|
|
|
# @u8: unsigned 8 bit integer
|
|
|
|
#
|
|
|
|
# @s8: signed 8 bit integer
|
|
|
|
#
|
|
|
|
# @u16: unsigned 16 bit integer
|
|
|
|
#
|
|
|
|
# @s16: signed 16 bit integer
|
|
|
|
#
|
|
|
|
# @u32: unsigned 32 bit integer
|
|
|
|
#
|
|
|
|
# @s32: signed 32 bit integer
|
|
|
|
#
|
|
|
|
# @f32: single precision floating-point (since 5.0)
|
|
|
|
#
|
2019-03-09 01:34:12 +03:00
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'enum': 'AudioFormat',
|
2020-02-02 22:38:07 +03:00
|
|
|
'data': [ 'u8', 's8', 'u16', 's16', 'u32', 's32', 'f32' ] }
|
2019-03-09 01:34:12 +03:00
|
|
|
|
|
|
|
##
|
|
|
|
# @AudiodevDriver:
|
|
|
|
#
|
|
|
|
# An enumeration of possible audio backend drivers.
|
|
|
|
#
|
2020-04-29 08:53:58 +03:00
|
|
|
# @jack: JACK audio backend (since 5.1)
|
|
|
|
#
|
2019-03-09 01:34:12 +03:00
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'enum': 'AudiodevDriver',
|
2023-01-23 11:39:57 +03:00
|
|
|
'data': [ 'none',
|
|
|
|
{ 'name': 'alsa', 'if': 'CONFIG_AUDIO_ALSA' },
|
|
|
|
{ 'name': 'coreaudio', 'if': 'CONFIG_AUDIO_COREAUDIO' },
|
|
|
|
{ 'name': 'dbus', 'if': 'CONFIG_DBUS_DISPLAY' },
|
|
|
|
{ 'name': 'dsound', 'if': 'CONFIG_AUDIO_DSOUND' },
|
|
|
|
{ 'name': 'jack', 'if': 'CONFIG_AUDIO_JACK' },
|
|
|
|
{ 'name': 'oss', 'if': 'CONFIG_AUDIO_OSS' },
|
|
|
|
{ 'name': 'pa', 'if': 'CONFIG_AUDIO_PA' },
|
2023-04-17 13:56:54 +03:00
|
|
|
{ 'name': 'pipewire', 'if': 'CONFIG_AUDIO_PIPEWIRE' },
|
2023-01-23 11:39:57 +03:00
|
|
|
{ 'name': 'sdl', 'if': 'CONFIG_AUDIO_SDL' },
|
|
|
|
{ 'name': 'sndio', 'if': 'CONFIG_AUDIO_SNDIO' },
|
|
|
|
{ 'name': 'spice', 'if': 'CONFIG_SPICE' },
|
|
|
|
'wav' ] }
|
2019-03-09 01:34:12 +03:00
|
|
|
|
|
|
|
##
|
|
|
|
# @Audiodev:
|
|
|
|
#
|
|
|
|
# Options of an audio backend.
|
|
|
|
#
|
|
|
|
# @id: identifier of the backend
|
|
|
|
#
|
|
|
|
# @driver: the backend driver to use
|
|
|
|
#
|
2023-04-28 13:54:29 +03:00
|
|
|
# @timer-period: timer period (in microseconds, 0: use lowest
|
|
|
|
# possible)
|
2019-03-09 01:34:12 +03:00
|
|
|
#
|
|
|
|
# Since: 4.0
|
|
|
|
##
|
|
|
|
{ 'union': 'Audiodev',
|
|
|
|
'base': {
|
|
|
|
'id': 'str',
|
|
|
|
'driver': 'AudiodevDriver',
|
|
|
|
'*timer-period': 'uint32' },
|
|
|
|
'discriminator': 'driver',
|
|
|
|
'data': {
|
|
|
|
'none': 'AudiodevGenericOptions',
|
2023-01-23 11:39:57 +03:00
|
|
|
'alsa': { 'type': 'AudiodevAlsaOptions',
|
|
|
|
'if': 'CONFIG_AUDIO_ALSA' },
|
|
|
|
'coreaudio': { 'type': 'AudiodevCoreaudioOptions',
|
|
|
|
'if': 'CONFIG_AUDIO_COREAUDIO' },
|
|
|
|
'dbus': { 'type': 'AudiodevGenericOptions',
|
|
|
|
'if': 'CONFIG_DBUS_DISPLAY' },
|
|
|
|
'dsound': { 'type': 'AudiodevDsoundOptions',
|
|
|
|
'if': 'CONFIG_AUDIO_DSOUND' },
|
|
|
|
'jack': { 'type': 'AudiodevJackOptions',
|
|
|
|
'if': 'CONFIG_AUDIO_JACK' },
|
|
|
|
'oss': { 'type': 'AudiodevOssOptions',
|
|
|
|
'if': 'CONFIG_AUDIO_OSS' },
|
|
|
|
'pa': { 'type': 'AudiodevPaOptions',
|
|
|
|
'if': 'CONFIG_AUDIO_PA' },
|
2023-04-17 13:56:54 +03:00
|
|
|
'pipewire': { 'type': 'AudiodevPipewireOptions',
|
|
|
|
'if': 'CONFIG_AUDIO_PIPEWIRE' },
|
2023-01-23 11:39:57 +03:00
|
|
|
'sdl': { 'type': 'AudiodevSdlOptions',
|
|
|
|
'if': 'CONFIG_AUDIO_SDL' },
|
|
|
|
'sndio': { 'type': 'AudiodevSndioOptions',
|
|
|
|
'if': 'CONFIG_AUDIO_SNDIO' },
|
|
|
|
'spice': { 'type': 'AudiodevGenericOptions',
|
|
|
|
'if': 'CONFIG_SPICE' },
|
2019-03-09 01:34:12 +03:00
|
|
|
'wav': 'AudiodevWavOptions' } }
|
2023-01-23 11:39:56 +03:00
|
|
|
|
|
|
|
##
|
|
|
|
# @query-audiodevs:
|
|
|
|
#
|
|
|
|
# Returns information about audiodev configuration
|
|
|
|
#
|
|
|
|
# Returns: array of @Audiodev
|
|
|
|
#
|
|
|
|
# Since: 8.0
|
|
|
|
##
|
|
|
|
{ 'command': 'query-audiodevs',
|
|
|
|
'returns': ['Audiodev'] }
|