Use snd_ctl_elem_type_name() to detect the value of the type comment
instead of using hardcoded strings.
The types list now also includes the BYTES type (Debian bug 481515).
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
When using alsactl to save or restore the card settings, it currently
skips over controls that don't have the appropriate read/write
permissions. It should also skip over inactive controls, otherwise it
will get an error when it tries to access that control, and will fail to
save the card state (or fully restore it.)
From: Dave Dillow <dave@thedillows.org>
When alsactl saved state has dB level information and an attribute
of a control element is changed after save (e.g. volume range is
changed), try to restore the values to keep the same dB level.
This change requires the new alsa-lib functions for TLV dB
conversion, so we check it in configure (until AM_PATH_ALSA(1.0.16)
works).
Make "alsactl restore" a bit more robust. Now it tries to parse the
compound items in the case that the number of channels was changed.
The former mono-value is expanded to all channels.