From 2fa574684c2e9e8fbc4ddf4f719595e741616dbe Mon Sep 17 00:00:00 2001 From: Gwilym Inzani Date: Sat, 8 Jun 2024 16:35:30 +0100 Subject: [PATCH] Number of channel is configurable --- tracker/desktop-player/src/mixer.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tracker/desktop-player/src/mixer.rs b/tracker/desktop-player/src/mixer.rs index e763da88..e5c5fe19 100644 --- a/tracker/desktop-player/src/mixer.rs +++ b/tracker/desktop-player/src/mixer.rs @@ -2,11 +2,12 @@ use agb_fixnum::Num; use std::{borrow::Cow, num::Wrapping}; const BUFFER_SIZE: usize = 560; +const NUM_CHANNELS: usize = 8; #[derive(Default)] pub struct Mixer { - channels: [Option; 8], - indices: [Wrapping; 8], + channels: [Option; NUM_CHANNELS], + indices: [Wrapping; NUM_CHANNELS], } impl Mixer {