//
// sub_BEB8C from 0xbeb8c to 0xbec42 (182 bytes)
//
// 0 xrefs:
//
// 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:41:47 +0000
//
int __fastcall sub_BEB8C(unsigned __int64 **a1, int a2, int a3, int *a4, _DWORD *a5, int *a6, int *a7, unsigned int a8)
{
unsigned __int64 *v10; // r0
unsigned __int64 *v11; // r4
int v12; // r1
int v13; // r5
int v14; // r0
int v15; // r5
unsigned __int64 *v16; // r0
unsigned int v18; // [sp+8h] [bp-20h] BYREF
if ( !*a5 )
{
*a5 = 3;
*a6 = 2;
}
v10 = sub_BD580(
*(int *)((char *)&dword_14C + (_DWORD)off_E8000),
0x1Cu,
"../../src/fmod_output_nosound.cpp",
0x43u,
0);
*a1 = v10;
if ( !v10 )
return 38;
v11 = v10;
v12 = *a4;
*(_DWORD *)v10 = *a4;
*((_DWORD *)v10 + 1) = a8;
v13 = (int)(1000 * a8) / v12;
v14 = v13 / 3;
if ( v13 < 3 )
v14 = 1;
*((_DWORD *)v11 + 2) = v14;
v18 = 0;
v15 = sub_4C6EA(a8, &v18, *a6, *a7);
if ( !v15 )
{
v15 = 0;
v16 = sub_BD580(
*(int *)((char *)&dword_14C + (_DWORD)off_E8000),
v18,
"../../src/fmod_output_nosound.cpp",
0x54u,
0);
*((_DWORD *)v11 + 6) = v16;
if ( !v16 )
return 38;
}
return v15;
}