//
// sub_67A08 from 0x67a08 to 0x67afe (246 bytes)
//
// 6 xrefs:
// > sub_67B2C @ 0x67c32
// > sub_67B2C @ 0x67c88
// > sub_67B2C @ 0x67ca2
// > sub_67B2C @ 0x67d28
// > sub_67B2C @ 0x67d40
// > sub_67DB8 @ 0x67df4
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:40:56 +0000
//
int __fastcall sub_67A08(int a1, int *a2, int a3)
{
int v4; // r0
int v6; // r0
int v7; // r6
int v8; // r1
int *v9; // r1
int v10; // t1
int v11; // r2
int v12; // r1
int v13; // r1
int v14; // r0
int v15; // r1
int v16; // r2
v4 = *a2;
if ( *a2 == -1 )
return 0;
if ( v4 == 2 )
{
v6 = *(_DWORD *)(a1 + 56);
if ( v6 == 1 )
{
v4 = 0;
goto LABEL_8;
}
if ( v6 == 2 )
{
v4 = 1;
LABEL_8:
*a2 = v4;
goto LABEL_10;
}
v4 = 2;
}
LABEL_10:
v8 = a1 + 4 * v4;
v10 = *(_DWORD *)(v8 + 36);
v9 = (int *)(v8 + 36);
v11 = a3 + v10;
*v9 = v11;
if ( v11 <= -1 )
{
*v9 = 0;
goto LABEL_14;
}
if ( !v11 )
{
LABEL_14:
v12 = *(_DWORD *)(a1 + 4 * v4);
v7 = 0;
if ( !v12 )
return v7;
sub_BD7AC(*(int *)((char *)&dword_14C + (_DWORD)off_E8000), v12, "../../src/fmod_dsp_transceiver.cpp", 182, 1);
v4 = *a2;
v13 = a1 + 8 * *a2;
*(_DWORD *)(a1 + 4 * *a2) = 0;
*(_DWORD *)(v13 + 12) = 0;
*(_DWORD *)(v13 + 16) = 0;
*(_WORD *)(a1 + 2 * v4 + 64) = 0;
if ( !*(_DWORD *)(a1 + 4 * v4 + 36) )
return v7;
}
v7 = 0;
if ( !*(_DWORD *)(a1 + 4 * v4) )
{
v14 = sub_BD580(
*(int *)((char *)&dword_14C + (_DWORD)off_E8000),
8 * *(_DWORD *)(a1 + 4 * v4 + 48) * *(_DWORD *)(a1 + 60),
"../../src/fmod_dsp_transceiver.cpp",
191,
0);
v15 = *a2;
*(_DWORD *)(a1 + 4 * *a2) = v14;
if ( v14 )
{
v16 = a1 + 8 * v15;
v7 = 0;
*(_DWORD *)(v16 + 12) = v14;
*(_DWORD *)(v16 + 16) = *(_DWORD *)(a1 + 4 * v15) + 4 * *(_DWORD *)(a1 + 4 * v15 + 48) * *(_DWORD *)(a1 + 60);
*(_WORD *)(a1 + 2 * v15 + 64) = 0;
}
else
{
return 38;
}
}
return v7;
}