From bdf49cfec066f25bf48aabe7da0e41ef6bce4311 Mon Sep 17 00:00:00 2001 From: gheskett Date: Wed, 2 Nov 2022 21:50:22 -0400 Subject: [PATCH] Increase max number of concurrent layers and channels At worst, this eats up a few KB of memory. Runtime difference should be negligible when the extra data is not being used. --- src/audio/internal.h | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/src/audio/internal.h b/src/audio/internal.h index d01da2804..c2834dc66 100644 --- a/src/audio/internal.h +++ b/src/audio/internal.h @@ -5,6 +5,16 @@ #include "types.h" +#ifdef EXPAND_AUDIO_HEAP // Not technically on the heap but it's memory nonetheless... +#if defined(VERSION_EU) || defined(VERSION_SH) +#define SEQUENCE_PLAYERS 4 +#define SEQUENCE_CHANNELS 64 +#else +#define SEQUENCE_PLAYERS 3 +#define SEQUENCE_CHANNELS 48 +#endif +#define SEQUENCE_LAYERS (SEQUENCE_CHANNELS * 2) +#else // EXPAND_AUDIO_HEAP #if defined(VERSION_EU) || defined(VERSION_SH) #define SEQUENCE_PLAYERS 4 #define SEQUENCE_CHANNELS 48 @@ -12,12 +22,9 @@ #else #define SEQUENCE_PLAYERS 3 #define SEQUENCE_CHANNELS 32 -#ifdef VERSION_JP -#define SEQUENCE_LAYERS 48 -#else #define SEQUENCE_LAYERS 52 #endif -#endif +#endif // EXPAND_AUDIO_HEAP #define LAYERS_MAX 4 #define CHANNELS_MAX 16