From 0811eb44bc585dd4becaa570907323d537c6a1cf Mon Sep 17 00:00:00 2001 From: Matthew Gregan Date: Wed, 21 Dec 2016 18:24:01 +1300 Subject: Define cubeb_layout_map in cubeb_mixer.cpp rather than cubeb-internal.h. --- src/cubeb_mixer.cpp | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'src/cubeb_mixer.cpp') diff --git a/src/cubeb_mixer.cpp b/src/cubeb_mixer.cpp index 241698a..ec0f535 100644 --- a/src/cubeb_mixer.cpp +++ b/src/cubeb_mixer.cpp @@ -9,6 +9,28 @@ #include "cubeb-internal.h" #include "cubeb_mixer.h" +cubeb_layout_map const CUBEB_CHANNEL_LAYOUT_MAPS[CUBEB_LAYOUT_MAX] = { + { "undefined", 0, CUBEB_LAYOUT_UNDEFINED }, + { "dual mono", 2, CUBEB_LAYOUT_DUAL_MONO }, + { "dual mono lfe", 3, CUBEB_LAYOUT_DUAL_MONO_LFE }, + { "mono", 1, CUBEB_LAYOUT_MONO }, + { "mono lfe", 2, CUBEB_LAYOUT_MONO_LFE }, + { "stereo", 2, CUBEB_LAYOUT_STEREO }, + { "stereo lfe", 3, CUBEB_LAYOUT_STEREO_LFE }, + { "3f", 3, CUBEB_LAYOUT_3F }, + { "3f lfe", 4, CUBEB_LAYOUT_3F_LFE }, + { "2f1", 3, CUBEB_LAYOUT_2F1 }, + { "2f1 lfe", 4, CUBEB_LAYOUT_2F1_LFE }, + { "3f1", 4, CUBEB_LAYOUT_3F1 }, + { "3f1 lfe", 5, CUBEB_LAYOUT_3F1_LFE }, + { "2f2", 4, CUBEB_LAYOUT_2F2 }, + { "2f2 lfe", 5, CUBEB_LAYOUT_2F2_LFE }, + { "3f2", 5, CUBEB_LAYOUT_3F2 }, + { "3f2 lfe", 6, CUBEB_LAYOUT_3F2_LFE }, + { "3f3r lfe", 7, CUBEB_LAYOUT_3F3R_LFE }, + { "3f4 lfe", 8, CUBEB_LAYOUT_3F4_LFE } +}; + static int const CHANNEL_ORDER_TO_INDEX[CUBEB_LAYOUT_MAX][CHANNEL_MAX] = { // M | L | R | C | LS | RS | RLS | RC | RRS | LFE { -1, -1, -1, -1, -1, -1, -1, -1, -1, -1 }, // UNSUPPORTED -- cgit v1.2.3