lynks-- / lifebar

Transparent workspace bar for i3 window manager.
GNU General Public License v2.0
36 stars 6 forks source link

[ Feature request ] Add support for mic status #22

Open cig0 opened 9 years ago

cig0 commented 9 years ago

Hey lynks! As lot of other people, my job involves being connected during working hours with my team and clients via different messaging systems like Skype, Hangouts, Linphone and so on - including a lot of calls of course. I currently hold an alsamixer console full-screen on WS10 to which I jump forth and back several times during the day to control my audio settings but mostly to check if the mic is muted; it would be really useful therefore to be able to monitor mic's status at a glance looking at the status bar, like a green icon for when it is muted and a bright-red-blinking-fireworks-thrower icon when it is not :) Cheers.

lynks-- commented 9 years ago

I have always indented on adding an audio module, primarily to display volume for a particular device or two. Other statuses such as mic should be fairly easy to add.

A minor issue would be that there are so many places in which a mic can be switched off; Many have hardware switches, the audio subsystem can mute the channel, and the application itself will often contain a mute button, but lifebar could report the subsystem status.

Also, I tend to lean towards pulse audio and so use pavucontrol to manage audio, its much, mutch nicer than alsamixer!

cig0 commented 9 years ago

With PulseAudio you can use something in the line of {bindsym $mod+Ctrl+m exec /usr/bin/pactl set-source-mute 1 toggle} while with AlsaMixer I think it would be something like {bindsym $mod+Alt+c exec --no-startup-id "konsole -e 'amixer set Capture toggle &> /dev/null'"}.

Regarding which one you should 'attack' first, I would love it would be PA mainly because is the one I'm using ^_^ but still I believe there are some valid arguments to go that way:

  1. It is mainstream and widely implemented almost everywhere;
  2. From what you say it would be easier/faster to implement it over AlsaMixer;

I suck at C but let me know if I can be of any help. Cheers!