-
Notifications
You must be signed in to change notification settings - Fork 476
Open
Labels
Description
I want to be able to use this library to control the volume and mute state of input and output Devices, ie:
let input_device = host.default_input_device().unwrap();
println!("microphone mute state: {}", input_device.get_mute());
input_device.set_mute(true);
let output_device = host.default_output_device().unwrap();
println!("output device volume: {} dB, {}%",
output_device.get_volume_db(),
output_device.get_volume_scalar() * 100);
// Set output volume to -10dB
output_device.set_volume_db(-10.);
// Set output volume to "scalar" 50% of maximum
output_device.set_volume_scalar(0.5);weilbith and felipecrsCongee