From 36f7af4ffcdfad5b094ef57ada26631febf62c4a Mon Sep 17 00:00:00 2001 From: James Courtier-Dutton Date: Sat, 16 Apr 2005 13:23:52 +0000 Subject: [PATCH] Implement order for 8-channel sound, arranged in 7.1 mode. --- speaker-test/speaker-test.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/speaker-test/speaker-test.c b/speaker-test/speaker-test.c index 867735c..f98a3a7 100644 --- a/speaker-test/speaker-test.c +++ b/speaker-test/speaker-test.c @@ -99,6 +99,16 @@ static const int channels6[] = { 2, 5 }; +static const int channels8[] = { + 0, + 4, + 1, + 7, + 3, + 2, + 6, + 5 +}; static void generate_sine(signed short *samples, int channel, int count, double *_phase) { double phase = *_phase; @@ -588,6 +598,9 @@ loop: if (channels == 6) { channel=channels6[chn]; } + if (channels == 8) { + channel=channels8[chn]; + } printf(" %d - %s\n", channel, channel_name[channel]); err = write_loop(handle, channel, ((rate*3)/period_size), samples); -- 2.47.1