mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-09-12 11:35:09 -04:00
JASBNKParser OK, Z2Audience OK (#2929)
This commit is contained in:
@@ -498,7 +498,7 @@ void JASAramStream::updateChannel(u32 i_callbackType, JASChannel* i_channel,
|
||||
field_0x0b4 = i_dspChannel->field_0x074 + i_dspChannel->field_0x064;
|
||||
if (field_0x118 >= field_0x160 - 2) {
|
||||
JUT_WARN_DEVICE(810, 1, "%s", "buffer under error");
|
||||
field_0x0ae |= 4;
|
||||
field_0x0ae |= (u8)4;
|
||||
}
|
||||
} else {
|
||||
if (field_0x12c & 1) {
|
||||
|
||||
@@ -305,3 +305,7 @@ JASOscillator::Point const* JASBNKParser::Ver0::getOscTableEndPtr(JASOscillator:
|
||||
} while (tmp <= 10);
|
||||
return points;
|
||||
}
|
||||
|
||||
// Fakematch? Why is this here?
|
||||
template<>
|
||||
JASMemPool_MultiThreaded<JASChannel> JASPoolAllocObject_MultiThreaded<JASChannel>::memPool_;
|
||||
|
||||
@@ -195,11 +195,19 @@ JASGenericMemPool::~JASGenericMemPool() {
|
||||
|
||||
JKRSolidHeap* JASDram;
|
||||
|
||||
void JASGenericMemPool::newMemPool(u32 size, int param_1) {
|
||||
// TODO: What is this and Where does it go?
|
||||
struct TNextOnFreeList {
|
||||
u8 pad[4];
|
||||
}; // Size: 0x4
|
||||
|
||||
void JASGenericMemPool::newMemPool(u32 n, int param_1) {
|
||||
JUT_ASSERT(734, n >= sizeof(TNextOnFreeList));
|
||||
void* runner;
|
||||
for (int i = 0; i < param_1; i++) {
|
||||
void* chunk = new (JASDram, 0) u8[size];
|
||||
*(void**)chunk = field_0x0;
|
||||
field_0x0 = chunk;
|
||||
runner = new (JASDram, 0) u8[n];
|
||||
JUT_ASSERT(739, runner);
|
||||
*(void**)runner = field_0x0;
|
||||
field_0x0 = runner;
|
||||
}
|
||||
freeMemCount += param_1;
|
||||
totalMemCount += param_1;
|
||||
|
||||
@@ -500,7 +500,11 @@ Z2Audience::Z2Audience() : JASGlobalInstance<Z2Audience>(true), field_0x4(1.0f),
|
||||
}
|
||||
|
||||
Z2Audience::~Z2Audience() {
|
||||
// JUT_ASSERT(751, !isActive()); // TODO: need to setup rest of JASMemPool stuff
|
||||
JUT_ASSERT(751, !isActive());
|
||||
}
|
||||
|
||||
bool Z2Audience::isActive() const {
|
||||
return Z2Audible::getTotalMemCount() != Z2Audible::getFreeMemCount();
|
||||
}
|
||||
|
||||
void Z2Audience::setAudioCamera(f32 (*param_0)[4], Vec& pos, Vec& param_2, f32 param_3,
|
||||
|
||||
Reference in New Issue
Block a user