snd_pcm_info

Name

snd_pcm_info -- obtain general information about the PCM device

Synopsis

int snd_pcm_info(snd_pcm_t *handle, snd_pcm_info_t *info);

Description

Fills the info structure with data about the PCM device selected by handle. Function returns zero if successful, otherwise it returns an error code.

typedef struct snd_pcm_info {
	unsigned int type;	/* soundcard type */
	unsigned int flags;	/* see SND_PCM_INFO_XXXX */
	unsigned char id[64];	/* ID of this PCM device */
	unsigned char name[80];	/* name of this device */
	int playback;		/* playback subdevices - 1 */
	int capture;		/* capture subdevices - 1 */
	char reserved[64];	/* reserved for future... */
} snd_pcm_info_t;

FlagDescription
SND_PCM_INFO_PLAYBACKPlayback channel is present.
SND_PCM_INFO_CAPTURECapture channel is present.
SND_PCM_INFO_DUPLEXHardware is capable the duplex operation.
SND_PCM_INFO_DUPLEX_RATEPlayback and capture rates must be same for the duplex operation.
SND_PCM_INFO_DUPLEX_RATEPlayback and capture must be monophonic for the duplex operation.