summaryrefslogtreecommitdiff
path: root/include/sound
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2012-08-21 15:07:44 +0200
committerTakashi Iwai <tiwai@suse.de>2012-09-13 08:24:47 +0200
commit0f36270dd315b9baf3a93f5586776b91c0bcf589 (patch)
tree9e0f3a141c2226d98e887a40f4c909a9e582bda8 /include/sound
parent915b26bfe8af876d467a37c336c6bf22d5e370fe (diff)
downloadalsa-lib-0f36270dd315b9baf3a93f5586776b91c0bcf589.tar.gz
Follow channel position definitions to mixer channel in mixer.h
mixer.h already contains some channel position definitions. To be more consistent over all systems, better to follow the same order for the new channel map, too. But since UNKNOWN channel must be zero but the definition in mixer.h contains -1 as UNKNOWN, simply shift the value with 1. If the conversion is required between SND_CHMAP and SND_MIXER_SCHN, just increment/decrement 1. Eventually I'll provide helper functions for that... Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'include/sound')
-rw-r--r--include/sound/asound.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/include/sound/asound.h b/include/sound/asound.h
index e635c99b..bb6db9d2 100644
--- a/include/sound/asound.h
+++ b/include/sound/asound.h
@@ -479,20 +479,22 @@ enum {
/* channel positions */
enum {
+ /* this follows the alsa-lib mixer channel value + 1*/
SNDRV_CHMAP_UNKNOWN = 0,
SNDRV_CHMAP_FL, /* front left */
- SNDRV_CHMAP_FC, /* front center */
SNDRV_CHMAP_FR, /* front right */
- SNDRV_CHMAP_FLC, /* front left center */
- SNDRV_CHMAP_FRC, /* front right center */
SNDRV_CHMAP_RL, /* rear left */
- SNDRV_CHMAP_RC, /* rear center */
SNDRV_CHMAP_RR, /* rear right */
- SNDRV_CHMAP_RLC, /* rear left center */
- SNDRV_CHMAP_RRC, /* rear right center */
+ SNDRV_CHMAP_FC, /* front center */
+ SNDRV_CHMAP_LFE, /* LFE */
SNDRV_CHMAP_SL, /* side left */
SNDRV_CHMAP_SR, /* side right */
- SNDRV_CHMAP_LFE, /* LFE */
+ SNDRV_CHMAP_RC, /* rear center */
+ /* new definitions */
+ SNDRV_CHMAP_FLC, /* front left center */
+ SNDRV_CHMAP_FRC, /* front right center */
+ SNDRV_CHMAP_RLC, /* rear left center */
+ SNDRV_CHMAP_RRC, /* rear right center */
SNDRV_CHMAP_FLW, /* front left wide */
SNDRV_CHMAP_FRW, /* front right wide */
SNDRV_CHMAP_FLH, /* front left high */