[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Ayatana] Two suggested designs for the Sound Indicator



On Fri, May 7, 2010 at 3:58 PM, Matthew Paul Thomas <mpt@xxxxxxxxxxxxx> wrote:
[...]
It is awkward that we have separate system and application-specific
volume settings, but I don't see how getting rid of the system volume
setting would work.

PulseAudio has a solution for precisely this problem: the so-called flat volumes [1, 2]. Basically, what they do is setting the global volume in such a way that the original volumes defined for the various streams are kept unaltered when mixed into the final, single stream (i.e., a high volume set for one of the streams will result in a high overall volume.) This is already implemented in PulseAudio, by the way, but inactive in Lucid. If you want to activate it, though, it's as easy as changing the flat-volumes setting in /etc/pulse/daemon.conf to "yes".

I suppose this feature is currently deactivated because it makes the main volume slider behave in a very strange way. Actually, the right solution when flat volumes are active would be to hide this slider completely, and rather provide a slider that controls the currently sounding stream. I have the impression that this would be a lot more intuitive to use for most people.
 
Ensuring the alert sounds are loud enough to be heard over other sounds
- -- whether by making them temporarily louder, or making the other sounds
temporarily softer -- is an interesting idea, but it seems out of scope
for the sound menu itself.

I proposed the idea of automatically controlling the volume of (or around) notification sounds as a way to eliminate one more aspect with which users must currently fiddle. If we managed to implement this (I know it isn't so easy) this would definitely simplify the user interface, which is one of the main goals you stated.

My idea to implement this, by the way, would be to measure the perceptual loudness [3] of the current stream using Replay Gain [4] or similar. The resulting (instant) value would be used to set the volume for the notification stream. This can probably be all done inside PulseAudio by creating an appropriate module.

Since I'm not an expert in signal processing, however, I don't know how difficult it would be to implement Replay Gain or a similar loudness measure in a way that can be used for this purpose. I also wonder what the impact on battery life would be. I'll try to look a bit more into these issues and report here when/if I find some answers. Of course, any useful pointers will be greatly appreciated.

Cheers,

M. S.

[1] http://0pointer.de/blog/projects/oh-nine-fifteen.html

[2] http://www.pulseaudio.org/wiki/WritingVolumeControlUIs (there's a section called "Flat Volumes" down the page)

[3] http://en.wikipedia.org/wiki/Equal-loudness_contour

[4] http://en.wikipedia.org/wiki/Replay_gain