mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-09-01 08:22:58 -04:00
Merge decomp/main into dusk
Merges 44 upstream commits from zeldaret/tp decomp/main. Conflict resolutions: - .github/workflows/build.yml: keep deleted (not needed for PC port) - README.md: keep PC port README - J3DAnimation.h: keep OFFSET_PTR macro + add upstream forward decl - J3DModelLoader.h: keep BE(u32) mBlockNum + add field_0x1c - d_com_inf_game.h: keep PC port inlines + add upstream declarations - global.h: keep MULTI_CHAR macro + add FABSF macro - JUTConsole.cpp: keep uintptr_t cast for 64-bit - JUTDbPrint.cpp: keep PC enter_() helper + add cstring include - JUTResFont.cpp: take upstream loop/struct improvements with BE types - JUTCacheFont.cpp: take upstream decomp fix - float.h: use upstream !PLATFORM_GCN guard - d_a_npc_bouS/theB.cpp: keep MULTI_CHAR() for PC portability - d_a_npc_henna.cpp: keep uintptr_t + use upstream var name - d_demo.cpp: keep near_/far_ field renames for PC - d_resorce.cpp: keep uintptr_t + fix var name to res - d_s_room.cpp, m_Do_graphic.cpp: keep dusk includes + add cstring - m_Do_main.cpp: keep JHIComPortManager + use JAS_GLOBAL_INSTANCE_INIT - angle_utils.h: remove redundant types.h include
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
#include "JSystem/JSupport/JSUList.h"
|
||||
|
||||
class JAISeqMgr;
|
||||
class JAISoundChild;
|
||||
struct JAISoundChild;
|
||||
|
||||
/**
|
||||
* @ingroup jsystem-jaudio
|
||||
|
||||
@@ -253,7 +253,7 @@ class JAIAudible;
|
||||
struct JAIAudience;
|
||||
class JAISe;
|
||||
class JAISeq;
|
||||
class JAISoundChild;
|
||||
struct JAISoundChild;
|
||||
class JAIStream;
|
||||
class JAITempoMgr;
|
||||
|
||||
|
||||
@@ -2,10 +2,11 @@
|
||||
#define JASCALC_H
|
||||
|
||||
#include <dolphin/types.h>
|
||||
#include <limits>
|
||||
|
||||
/**
|
||||
* @ingroup jsystem-jaudio
|
||||
*
|
||||
*
|
||||
*/
|
||||
struct JASCalc {
|
||||
static void imixcopy(const s16*, const s16*, s16*, u32);
|
||||
@@ -15,15 +16,8 @@ struct JASCalc {
|
||||
static void bzero(void* dest, u32 size);
|
||||
static f32 pow2(f32);
|
||||
|
||||
// Could not make it work as inline - specialization is in JASCalc.cpp
|
||||
template <typename A, typename B>
|
||||
static A clamp(B x); /* {
|
||||
if (std::numeric_limits<A>::min() >= x)
|
||||
return std::numeric_limits<A>::min();
|
||||
if (x >= std::numeric_limits<A>::max())
|
||||
return std::numeric_limits<A>::max();
|
||||
return x;
|
||||
} */
|
||||
static A clamp(B x);
|
||||
|
||||
static f32 clamp01(f32 i_value) {
|
||||
if (i_value <= 0.0f) {
|
||||
@@ -42,4 +36,13 @@ struct JASCalc {
|
||||
static const s16 CUTOFF_TO_IIR_TABLE[128][4];
|
||||
};
|
||||
|
||||
template <typename A, typename B>
|
||||
A JASCalc::clamp(B x) {
|
||||
if (x <= std::numeric_limits<A>::min())
|
||||
return std::numeric_limits<A>::min();
|
||||
if (x >= std::numeric_limits<A>::max())
|
||||
return std::numeric_limits<A>::max();
|
||||
return x;
|
||||
}
|
||||
|
||||
#endif /* JASCALC_H */
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
#include "JSystem/JAudio2/JASWaveInfo.h"
|
||||
#include <dolphin/os.h>
|
||||
|
||||
class JASDSPChannel;
|
||||
struct JASDSPChannel;
|
||||
|
||||
namespace JASDsp {
|
||||
struct TChannel;
|
||||
|
||||
@@ -4,6 +4,12 @@
|
||||
#include "JSystem/JUtility/JUTAssert.h"
|
||||
#include <string>
|
||||
|
||||
#ifdef __MWERKS__
|
||||
#define JAS_GLOBAL_INSTANCE_INIT
|
||||
#else
|
||||
#define JAS_GLOBAL_INSTANCE_INIT {}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @ingroup jsystem-jaudio
|
||||
*
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
|
||||
class JKRHeap;
|
||||
class JASWaveBank;
|
||||
class JASBasicWaveBank;
|
||||
class JASSimpleWaveBank;
|
||||
struct JASBasicWaveBank;
|
||||
struct JASSimpleWaveBank;
|
||||
|
||||
/**
|
||||
* @ingroup jsystem-jaudio
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
#ifndef JAUAUDIENCE_H
|
||||
#define JAUAUDIENCE_H
|
||||
|
||||
// NONMATCHING
|
||||
|
||||
#endif /* JAUAUDIENCE_H */
|
||||
@@ -0,0 +1,6 @@
|
||||
#ifndef JAUSOUNDOBJECT_H
|
||||
#define JAUSOUNDOBJECT_H
|
||||
|
||||
// NONMATCHING
|
||||
|
||||
#endif /* JAUSOUNDOBJECT_H */
|
||||
Reference in New Issue
Block a user