Information structure for a PCM channel
Synopsis:
#include <sys/asound_common.h>
typedef struct snd_pcm_channel_info
{
int32_t subdevice;
int8_t subname[36];
int32_t channel;
int32_t zero1;
int32_t output_class;
int32_t output_classes;
int32_t zero2[2];
uint32_t flags;
uint32_t formats;
uint32_t rates;
int32_t min_rate;
int32_t max_rate;
int32_t min_voices;
int32_t max_voices;
int32_t max_buffer_size;
int32_t min_fragment_size;
int32_t max_fragment_size;
int32_t fragment_align;
int32_t fifo_size;
int32_t transfer_block_size;
uint8_t zero3[4];
snd_pcm_digital_t dig_mask;
uint32_t zero4;
int32_t mixer_device;
snd_mixer_eid_t mixer_eid;
snd_mixer_gid_t mixer_gid;
uint8_t reserved[128];
} snd_pcm_channel_info_t;
Description:
The snd_pcm_channel_info_t structure describes PCM channel information.
The members include:
- subdevice
- The subdevice number.
- subname[32]
- The subdevice name.
- channel
- The channel direction; either SND_PCM_CHANNEL_CAPTURE or
SND_PCM_CHANNEL_PLAYBACK.
- zerp1
- Padding of size uint32_t.
- output_class
- The output class that's used for DRM purposes. These are the valid values you can use:
- SND_OUTPUT_CLASS_UKNOWN
- The output channel is for an unknown type.
- SND_OUTPUT_CLASS_SPEAKER
- Indicates that the output channel is for speakers connected to the system.
- SND_OUTPUT_CLASS_HEADPHONE
- Indicates that the output channel is for headphones connected to the system.
- SND_OUTPUT_CLASS_LINEOUT
- Indicates that the output channel is for the line-out for the system.
- SND_OUTPUT_CLASS_BLUETOOTH
- Indicates that the output channel is for Bluetooth.
- SND_OUTPUT_CLASS_TOSLINK
- Indicates the output channel is for an S-Link connector.
- SND_OUTPUT_CLASS_MIRACAST
- Indicates that the output channel is for Miracast.
- SND_NUM_OUTPUT_CLASSES
- An end-of-list identifier that indicates the total number of output types
recognized by this library.
- output_classes
- The mask of the supported output classes that are used for DRM purposes.
- flags
- Any combination of:
- SND_PCM_CHNINFO_BLOCK — the hardware supports
block mode.
- SND_PCM_CHNINFO_BLOCK_TRANSFER — the
hardware transfers samples by chunks (for example PCI burst transfers).
- SND_PCM_CHNINFO_INTERLEAVE — the
hardware accepts audio data composed of interleaved samples.
- SND_PCM_CHNINFO_MMAP — the hardware supports
mmap access.
- SND_PCM_CHNINFO_MMAP_VALID — fragment samples are
valid during transfer.
This means that the fragment samples may be used when the io
member from the mmap control structure
snd_pcm_mmap_control_t is set (the fragment is being
transferred).
- SND_PCM_CHNINFO_NONINTERLEAVE — the
hardware accepts audio data composed of noninterleaved samples.
- SND_PCM_CHNINFO_OVERRANGE — the
hardware supports ADC (capture) overrange detection.
- SND_PCM_CHNINFO_PAUSE —
the PCM device, underlying hardware, or both supports pausing and resuming of the audio stream (playback only).
- SND_PCM_CHNINFO_RESTRICTED — the
hardware supports muting of channel data.
- SND_PCM_CHNINFO_ROUTING — the hardware
supports redirecting the channel to a different transducer.
- SND_PCM_CHNINFO_LOGGING — PCM logging
is enabled on the channel.
- SND_PCM_CHNINFO_PROTECTED_VOICE — the hardware
supports a protected voice channel. A protected voice channel contains only voice data.
- formats
- The supported formats (SND_PCM_FMT_*).
- rates
- Hardware rates (SND_PCM_RATE_*).
- min_rate
- The minimum rate (in Hz).
- max_rate
- The maximum rate (in Hz).
- min_voices
- The minimum number of voices (probably always 1).
- max_voices
- The maximum number of voices.
- max_buffer_size
- The maximum buffer size, in bytes.
- min_fragment_size
- The minimum fragment size, in bytes.
- max_fragment_size
- The maximum fragment size, in bytes.
- fragment_align
- If this value is set, the size of the buffer fragments must be a multiple
of this value, so that they are in the proper alignment.
- fifo_size
- The stream FIFO size, in bytes.
Deprecated; don't use this member.
- transfer_block_size
- The bus transfer block size in bytes.
- dig_mask
- Not currently implemented.
- mixer_device
- The mixer device for this channel.
- mixer_eid
- A
snd_mixer_eid_t
structure that describes the mixer element identification for this channel.
- mixer_gid
- The mixer group identification for this channel; see snd_mixer_gid_t. You should use this mixer group in
applications that are implementing their own volume controls.
This mixer group is guaranteed to be the lowest-level mixer group for your channel
(or subchannel), as determined at the time that you call snd_ctl_pcm_channel_info(). If you call this function
after the channel has been configured, and a subchannel has been allocated (i.e.,
after calling snd_pcm_channel_params()), this mixer group is the
subchannel mixer group that's specific to the application's current subchannel.
If the rates, formats, min_rate,
max_rate, min_voices, max_voices, and
max_fragsize fields of snd_pcm_channel_info_t all contain zeroed
data, the PCM device is currently not available for further playback or capture sessions.
Classification:
QNX Neutrino