Hi, > +## > +# @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') > +# > +# @try-poll: attempt to use poll mode, falling back to non polling access on > +# failure (default on) > +# > +# Since: 4.0 > +## > +{ 'struct': 'AudiodevAlsaPerDirectionOptions', > + 'data': { > + '*dev': 'str', > + '*try-poll': 'bool' } } > + > +## > +# @AudiodevAlsaOptions: > +# > +# Options of the alsa audio backend. > +# > +# @alsa-in: options of the capture stream > +# > +# @alsa-out: options of the playback stream > +# > +# @threshold: set the threshold (in microseconds) when playback starts > +# > +# Since: 4.0 > +## > +{ 'struct': 'AudiodevAlsaOptions', > + 'data': { > + '*alsa-in': 'AudiodevAlsaPerDirectionOptions', > + '*alsa-out': 'AudiodevAlsaPerDirectionOptions', > + '*threshold': 'uint32' } }
Hmm, do we need try-poll as per-direction option? If not we could simplify AudiodevAlsaOptions this way ... { 'struct': 'AudiodevAlsaOptions', 'data': { '*dev-in': 'str', '*dev-out': 'str', '*threshold': 'uint32' '*try-poll': 'bool' } } ... eliminating some nesting. > +## > +# @AudiodevOssPerDirectionOptions: > +# > +# Options of the oss backend that are used for both playback and recording. > +# > +# @dev: file name of the oss device (default '/dev/dsp') > +# > +# @try-poll: attempt to use poll mode, falling back to non polling access on > +# failure (default on) > +# > +# Since: 4.0 > +## > +{ 'struct': 'AudiodevOssPerDirectionOptions', > + 'data': { > + '*dev': 'str', > + '*try-poll': 'bool' } } Same here. > +## > +# @AudiodevPaOptions: > +# > +# Options of the pa (PulseAudio) audio backend. > +# > +# @server: PulseAudio server address (default: let PulseAudio choose) > +# > +# @sink: name of the sink to use > +# > +# @source: name of the source to use > +# > +# Since: 4.0 > +## > +{ 'struct': 'AudiodevPaOptions', > + 'data': { > + '*server': 'str', > + '*sink': 'AudiodevPaPerDirectionOptions', > + '*source': 'AudiodevPaPerDirectionOptions' } } AudiodevPaPerDirectionOptions has only the name field, so we can drop the struct and just use '*sink' : 'str' ... cheers, Gerd