From d4ca7b696bee74d3771c5a4191d9dca1a91d829b Mon Sep 17 00:00:00 2001 From: PJB3005 Date: Thu, 6 Aug 2026 01:05:19 +0200 Subject: [PATCH] Fix include shenanigans --- .../include/JSystem/JAudio2/JASChannel.h | 12 +----------- .../JSystem/JAudio2/JASSampleDataReference.h | 18 ++++++++++++++++++ .../include/JSystem/JAudio2/JASWaveInfo.h | 2 +- src/dusk/mods/svc/audio_res/audio_res.hpp | 1 + 4 files changed, 21 insertions(+), 12 deletions(-) create mode 100644 libs/JSystem/include/JSystem/JAudio2/JASSampleDataReference.h diff --git a/libs/JSystem/include/JSystem/JAudio2/JASChannel.h b/libs/JSystem/include/JSystem/JAudio2/JASChannel.h index f8579c4be3..77bfb45966 100644 --- a/libs/JSystem/include/JSystem/JAudio2/JASChannel.h +++ b/libs/JSystem/include/JSystem/JAudio2/JASChannel.h @@ -17,17 +17,7 @@ namespace JASDsp { } #if TARGET_PC -/** - * An object to manage the lifetime of the sample data pointed to by JASChannel. - * - * JASChannel can (optionally) accept an unique_ptr to an object to this type, - * in which case it will be destroyed when the JASChannel is done. - * - * @see JASChannel::mSampleReference - */ -struct JASSampleDataReference { - virtual ~JASSampleDataReference() = default; -}; +#include "JSystem/JAudio2/JASSampleDataReference.h" #endif /** diff --git a/libs/JSystem/include/JSystem/JAudio2/JASSampleDataReference.h b/libs/JSystem/include/JSystem/JAudio2/JASSampleDataReference.h new file mode 100644 index 0000000000..d196b4f34c --- /dev/null +++ b/libs/JSystem/include/JSystem/JAudio2/JASSampleDataReference.h @@ -0,0 +1,18 @@ +#ifndef DUSKLIGHT_JASSAMPLEDATAREFERENCE_H +#define DUSKLIGHT_JASSAMPLEDATAREFERENCE_H + +#if TARGET_PC +/** + * An object to manage the lifetime of the sample data pointed to by JASChannel. + * + * JASChannel can (optionally) accept an unique_ptr to an object to this type, + * in which case it will be destroyed when the JASChannel is done. + * + * @see JASChannel::mSampleReference + */ +struct JASSampleDataReference { + virtual ~JASSampleDataReference() = default; +}; +#endif + +#endif // DUSKLIGHT_JASSAMPLEDATAREFERENCE_H diff --git a/libs/JSystem/include/JSystem/JAudio2/JASWaveInfo.h b/libs/JSystem/include/JSystem/JAudio2/JASWaveInfo.h index 45874f5aa7..a092f7450e 100644 --- a/libs/JSystem/include/JSystem/JAudio2/JASWaveInfo.h +++ b/libs/JSystem/include/JSystem/JAudio2/JASWaveInfo.h @@ -5,7 +5,7 @@ #include #if TARGET_PC -struct JASSampleDataReference; +#include "JSystem/JAudio2/JASSampleDataReference.h" #endif struct JASWaveArc; diff --git a/src/dusk/mods/svc/audio_res/audio_res.hpp b/src/dusk/mods/svc/audio_res/audio_res.hpp index 4ae3e0dd1c..ce46db0721 100644 --- a/src/dusk/mods/svc/audio_res/audio_res.hpp +++ b/src/dusk/mods/svc/audio_res/audio_res.hpp @@ -1,6 +1,7 @@ #pragma once #include +#include #include "JSystem/JAudio2/JASChannel.h" #include "JSystem/JAudio2/JASWaveInfo.h" #include "absl/container/flat_hash_map.h"