//
// jinit_huff_encoder from 0x87da9c to 0x87daf2 (86 bytes)
//
// 2 xrefs:
// > jinit_compress_master @ 0x87db8e
// > jpeg_write_coefficients @ 0x8840fa
//
// 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 12:03:08 +0000
//
void *__fastcall jinit_huff_encoder(int a1)
{
_DWORD *v2; // r4
void *result; // r0
v2 = (_DWORD *)(**(int (***)(void))(a1 + 4))();
*(_DWORD *)(a1 + 424) = v2;
*v2 = sub_87B824;
memset(v2 + 15, 0, 0x10u);
memset(v2 + 11, 0, 0x10u);
memset(v2 + 23, 0, 0x10u);
result = memset(v2 + 19, 0, 0x10u);
if ( *(_DWORD *)(a1 + 268) )
v2[34] = 0;
return result;
}