|
std::optional< std::pair< std::wstring, std::reference_wrapper< const format_t > > > | extract_virtual_sink_info (const std::string &sink) |
| Extract virtual audio sink information possibly encoded in the sink name.
|
|
std::optional< matched_field_t > | find_device_id (const match_fields_list_t &match_list) |
| Search for currently present audio device_id using multiple match fields.
|
|
int | init () |
|
bool | install_steam_audio_drivers () |
| Installs the Steam Streaming Speakers driver, if present.
|
|
bool | is_sink_available (const std::string &sink) override |
| Check if the audio sink is available in the system.
|
|
audio_control_t::match_fields_list_t | match_all_fields (const std::wstring &name) |
|
audio_control_t::match_fields_list_t | match_steam_speakers () |
|
std::unique_ptr< mic_t > | microphone (const std::uint8_t *mapping, int channels, std::uint32_t sample_rate, std::uint32_t frame_size) override |
|
void | reset_default_device () |
| Resets the default audio device from Steam Streaming Speakers.
|
|
std::optional< std::wstring > | set_format (const std::string &sink) |
|
int | set_sink (const std::string &sink) override |
|
std::optional< sink_t > | sink_info () override |
|
◆ match_field_e
Enumerator |
---|
device_id | Match device_id.
|
device_friendly_name | Match endpoint friendly name.
|
adapter_friendly_name | Match adapter friendly name.
|
device_description | Match endpoint description.
|
◆ ~audio_control_t()
platf::audio::audio_control_t::~audio_control_t |
( |
| ) |
|
|
inlineoverridevirtual |
◆ extract_virtual_sink_info()
std::optional< std::pair< std::wstring, std::reference_wrapper< const format_t > > > platf::audio::audio_control_t::extract_virtual_sink_info |
( |
const std::string & | sink | ) |
|
|
inline |
Extract virtual audio sink information possibly encoded in the sink name.
- Parameters
-
- Returns
- A pair of device_id and format reference if the sink name matches our naming scheme for virtual audio sinks,
std::nullopt
otherwise.
◆ find_device_id()
std::optional< matched_field_t > platf::audio::audio_control_t::find_device_id |
( |
const match_fields_list_t & | match_list | ) |
|
|
inline |
Search for currently present audio device_id using multiple match fields.
- Parameters
-
match_list | Pairs of match fields and values |
- Returns
- Optional pair of matched field and device_id
◆ install_steam_audio_drivers()
bool platf::audio::audio_control_t::install_steam_audio_drivers |
( |
| ) |
|
|
inline |
Installs the Steam Streaming Speakers driver, if present.
- Returns
true
if installation was successful.
◆ is_sink_available()
bool platf::audio::audio_control_t::is_sink_available |
( |
const std::string & | sink | ) |
|
|
inlineoverridevirtual |
Check if the audio sink is available in the system.
- Parameters
-
- Returns
- True if available, false otherwise.
Implements platf::audio_control_t.
◆ microphone()
std::unique_ptr< mic_t > platf::audio::audio_control_t::microphone |
( |
const std::uint8_t * | mapping, |
|
|
int | channels, |
|
|
std::uint32_t | sample_rate, |
|
|
std::uint32_t | frame_size ) |
|
inlineoverridevirtual |
◆ set_format()
std::optional< std::wstring > platf::audio::audio_control_t::set_format |
( |
const std::string & | sink | ) |
|
|
inline |
If the requested sink is a virtual sink, meaning no speakers attached to the host, then we can seamlessly set the format to stereo and surround sound.
Any virtual sink detected will be prefixed by: virtual-(format name) If it doesn't contain that prefix, then the format will not be changed
◆ set_sink()
int platf::audio::audio_control_t::set_sink |
( |
const std::string & | sink | ) |
|
|
inlineoverridevirtual |
◆ sink_info()
std::optional< sink_t > platf::audio::audio_control_t::sink_info |
( |
| ) |
|
|
inlineoverridevirtual |
The documentation for this class was generated from the following file: