//
// FMOD::DSP::getActive from 0x1004853e4 to 0x1004854d8 (244 bytes)
//
// 1 xrefs:
// > sub_100454070 @ 0x10045408c
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
FMOD_RESULT __fastcall FMOD::DSP::getActive(FMOD::DSP *a1, bool *a2)
{
int v4; // w3
int v5; // w4
int v6; // w5
int v7; // w6
int v8; // w7
__int64 v9; // x19
__int64 v10; // x0
char v12; // w8
__int64 v13; // [xsp+8h] [xbp-138h] BYREF
__int64 v14; // [xsp+10h] [xbp-130h] BYREF
_BYTE v15[256]; // [xsp+18h] [xbp-128h] BYREF
v13 = 0;
v9 = sub_1004A3DB0(a1, &v14, &v13);
if ( !(_DWORD)v9 )
{
if ( a2 )
{
LODWORD(v9) = 0;
v12 = atomic_load((unsigned int *)(v14 + 100));
*a2 = v12 < 0;
v10 = v13;
if ( !v13 )
return (unsigned int)v9;
goto LABEL_5;
}
v9 = 31;
}
if ( (*((_BYTE *)off_1008524C8 + 32) & 0x80) != 0 )
{
sub_1004361F4((int)v15, 0x100u, (__int64)a2, v4, v5, v6, v7, v8);
sub_10048489C(v9, 7, (__int64)a1, (__int64)"DSP::getActive", (__int64)v15);
}
v10 = v13;
if ( v13 )
LABEL_5:
sub_100442D80(v10);
return (unsigned int)v9;
}