fix: use description instead of name
This commit is contained in:
+4
-2
@@ -194,9 +194,11 @@ impl AudioVisualizer {
|
||||
{
|
||||
if let Ok(devices) = host.devices() {
|
||||
for dev in devices {
|
||||
if let Ok(name) = dev.name() {
|
||||
// Monitor devices mirror system output under PulseAudio/PipeWire
|
||||
if let Ok(desc) = dev.description() {
|
||||
let name = desc.to_string();
|
||||
|
||||
if name.contains("monitor") {
|
||||
// Monitor devices mirror system output under PulseAudio/PipeWire
|
||||
if let Ok(config) = dev.default_input_config() {
|
||||
return Ok((dev, config.into()));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user