Toggling hardware volume for a card or port in pavucontrol

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

 



Hi,

Related to previous discussions[1][2][3] about dealing with volume on
certain type of usb sound cards, I'd like to make it possible to enable
and disable hardware volume for individual cards and/or ports in
pavucontrol.

Here's the specific use case: the Terratec Aureon Dual USB sound card
has a single output jack that can used in both analog and digital modes
(there are other similar usb sound cards too). PulseAudio has no way to
know which mode is in use. Hardware volume works only in the analog
mode. Currently that means that PulseAudio's volume control has no
effect in the digital mode, because PulseAudio controls a mixer element
that doesn't do anything.

I want to disable hardware volume for that card by default, because
that's the only safe default. That reduces the audio quality a bit,
however, so it would be good to allow concerned users to enable
hardware volume for the card without too much hassle.

I'd like some feedback to guide the design:

0) Is this feature worth the maintenance burden the new code causes, or
should I just forget about this? (My answer: it's worth doing.)

1) Should the client API be specific to alsa, or should it be added to
the core interface? A third option exists too: don't make it specific
to alsa, but implement the client API in a module with a protocol
extension, and hook to the new module from alsa code. (My answer:
core.)

2) Should the hardware volume toggle be associated with a card or a
port or both? Associating it with the card would make the UI a bit
simpler. Logically, though, the toggle should be associated with a
port, because in the specific use case that I'm concentrating on the
volume problem concerns only the output path, not the input path.
There's no reason to disable hardware volume for the input path.
Whatever we choose, it's always possible to extend the code to support
both per-card and per-port toggles. (My answer: start with per-port.)

[1] http://thread.gmane.org/gmane.comp.audio.pulseaudio.general/22253
[2] http://thread.gmane.org/gmane.comp.audio.pulseaudio.general/23351
[3] http://thread.gmane.org/gmane.comp.audio.pulseaudio.general/23434

-- 
Tanu


[Index of Archives]     [Linux Audio Users]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux