34 lines
1.1 KiB
Diff
34 lines
1.1 KiB
Diff
--- cmixer.pl.orig
|
|
+++ cmixer.pl
|
|
@@ -34,23 +34,6 @@
|
|
|
|
sub read_mixerctl {
|
|
my $self = shift;
|
|
- foreach (`mixerctl 2>&1`) {
|
|
- #mixerctl: /dev/mixer: Device not configured
|
|
- die "No mixer device found" if (/^mixerctl: \/dev\/mixer.: Device not configured$/);
|
|
- #outputs.master=255,255 volume
|
|
- if (/^(outputs|inputs|record)\.([^\.]*)=(\d+),(\d+)\s+/) {
|
|
- $self->{mixer}{$1}{$2}{volume}{left} = $3;
|
|
- $self->{mixer}{$1}{$2}{volume}{right} = $4;
|
|
- # outputs.mono=255 volume
|
|
- } elsif (/^(outputs|inputs|record)\.([^\.]*)=(\d+)\s+/) {
|
|
- $self->{mixer}{$1}{$2}{volume}{center} = $3;
|
|
- # outputs.master.mute=off [ off on ]
|
|
- } elsif (/^(outputs|inputs|record)\.(.*)\.mute=(on|off)\s+/) {
|
|
- $self->{mixer}{$1}{$2}{mute} = $3;
|
|
- }
|
|
- #todo: record.source=mic [ mic cd video aux line mixerout mixeroutmono phone ]
|
|
- #inputs.mix_source=mic,beep,hp { mic mic2 beep hp }
|
|
- }
|
|
foreach (`aucatctl 2>&1`) {
|
|
die "Failed to connect to sndiod" if (/couldn't open MIDI device$/);
|
|
#mplayer0=127
|
|
@@ -59,7 +42,6 @@
|
|
$self->{mixer}{sndio}{$1}{volume}{center} = 2 * $2;
|
|
}
|
|
}
|
|
- die "No outputs found" unless (exists $self->{mixer}{outputs});
|
|
}
|
|
|
|
sub update_view {
|