Get information about a mixer element


#include <sys/asoundlib.h>

int snd_mixer_element_info(
       snd_mixer_t *mixer, 
       snd_mixer_element_info_t *info );


The handle for the mixer device. This must have been created by snd_mixer_open().
A pointer to a snd_mixer_element_info_t.


Use the -l asound option with qcc to link against this library.


The snd_mixer_element_info() function gets information about a mixer element.

The caller must fill in the element ID member (eid) of the information structure to target the information request at a specific mixer element.

The data member of the information structure is a union of specific information structures for the various element types. It is dependent on the element type for which information is being requested. The caller must provide adequate buffering for the element information but its size can vary. If the required buffering varies, the mixer element information data structure includes a *_size variable, an *_over variable, and a buffer pointer. The *_size variable specifies the client-provided buffer size that the buffer pointer points to, and the *_over variable is used by the server to communicate back to the call if additional buffer space is required. If additional space is required, the buffer can be resized and the call can be made a second time to read the full element information.

The snd_mixer_element_info_build() function performs the same task as snd_mixer_element_info(), but it also allocates the extra buffering that a caller must provide to hold the full element information.


EOK on success, a negative errno upon failure.


NULL mixer or info argument, or invalid element type.
The element wasn't found.
No element information available.


QNX Neutrino

Cancellation point No
Interrupt handler No
Signal handler Yes
Thread Yes