larsimmisch / pyalsaaudio

ALSA wrappers for Python
http://larsimmisch.github.io/pyalsaaudio/
Other
216 stars 74 forks source link

Add the ability to retrieve control, similar to: `amixer -D hw:1 scontrols` #101

Open charlesomer opened 3 years ago

charlesomer commented 3 years ago

Hi,

I'm not sure if this would be possible or already exists (I don't think it does) but it would be great if it was possible to get the control for a device similar to amixer -D hw:1 scontrols. At the moment I am extracting the string which isn't elegant but does work for now.

Thank you Charles

RonaldAJ commented 3 years ago

You can have a look whether the function called from amixer can be made available in pyalsaaudio. I have no experience with the mixer side, but extending the sound acquisition side was doable.

There are a few pitfalls related to memory management when extending pyalsaaudio functionality. But all in all it is not extremely hard, just takes some time.

ossilator commented 9 months ago

isn't the request just asking for an enumeration of controls? that's what alsaaudio.mixers() is supposed to do.