Audio
exception CvcImportError (*args)
Section titled “ CvcImportError ”Bases: ImportError
class AudioStream (stream: MixerStream, control: MixerControl, parent: Audio, **kwargs)
Section titled “ AudioStream ”Bases: Service
A class representing a stream of audio (i.e. speakers, microphones, applications and recorders)
This class also enables the control of the contained stream (e.g. volume and mute state)
Default service constructor (base constructor)
-
Parameters: **kwargs —
mapped to signal connections (e.g. on_clicked=lambda *_: … connects the given function to the signal “clicked”, notify_my_property=my_func connects the given function to the signal “notify::my-property”)
signal changed (self)NoneType
Section titled “ changed ”signal closed (self)NoneType
Section titled “ closed ”property icon_name str
Section titled “ icon_name ”A suggested icon name for this stream type
- Return type: str
property id int
Section titled “ id ”The identifier of this stream
- Return type: int
property name str
Section titled “ name ”The display name associated with this stream
- Return type: str
property description str
Section titled “ description ”Text descriping this stream’s purpose
- Return type: str
property application_id str
Section titled “ application_id ”This stream’s application’s identifier (if any)
- Return type: str
property state str
Section titled “ state ”The state this stream is currently in
- Return type: str
property stream MixerStream
Section titled “ stream ”The actual stream object this class is holding
- Return type: Cvc.MixerStream
property volume float
Section titled “ volume ”The current volume value for this stream (limited to parent’s max_volume)
- Return type: float
property muted bool
Section titled “ muted ”Whether this stream is in a mute state currently or not
- Return type: bool
property type str
Section titled “ type ”def notifier (name: str, *args)
Section titled “ notifier ”def close ()
Section titled “ close ”class Audio (max_volume: int = 100, controller_name: str = 'fabric audio control', **kwargs)
Section titled “ Audio ”Bases: Service
- Parameters:
- max_volume (int , optional) — default maximum volume for all streams, this limit only works if volume setting is done through this service, defaults to 100
- controller_name (str , optional) — the name of this service’s mixer controll, defaults to “fabric audio control”
signal changed (self)NoneType
Section titled “ changed ”signal speaker_changed (self)NoneType
Section titled “ speaker_changed ”signal microphone_changed (self)NoneType
Section titled “ microphone_changed ”signal stream_added (self)NoneType
Section titled “ stream_added ”signal stream_removed (self)NoneType
Section titled “ stream_removed ”property speaker AudioStream
Section titled “ speaker ”The default speaker stream begin currently in use (if any)
- Return type: AudioStream
property speakers list[AudioStream]
Section titled “ speakers ”A list of all speaker streams connected to this device
- Return type: list[AudioStream]
property microphone AudioStream
Section titled “ microphone ”The default microphone stream (if any)
- Return type: AudioStream
property microphones list[AudioStream]
Section titled “ microphones ”A list of all microphone streams connected to this device
- Return type: list[AudioStream]
property applications list[AudioStream]
Section titled “ applications ”A list of all application streams outputing audio at the moment
- Return type: list[AudioStream]
property recorders list[AudioStream]
Section titled “ recorders ”A list of application streams recording audio at the moment
- Return type: list[AudioStream]
property max_volume int
Section titled “ max_volume ”The maximum volume value all streams can reach by setting the volume through this service
- Return type: int