//
// png_reciprocal2 from 0xe40558 to 0xe405a0 (72 bytes)
//
// 6 xrefs:
// > png_build_gamma_table @ 0xe4089c
// > png_build_gamma_table @ 0xe40b94
// > png_init_read_transformations @ 0xe4f2cc
// > png_init_read_transformations @ 0xe4f414
// > png_init_read_transformations @ 0xe4f4fc
// > ??> @ 0x5fff8
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// 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 13:10:02 +0000
//
__int64 __fastcall png_reciprocal2(int a1, int a2)
{
double v2; // d0
v2 = floor(1.0e15 / (double)a1 / (double)a2 + 0.5);
if ( v2 > 2147483650.0 || v2 < -2147483650.0 )
return 0;
else
return (unsigned int)(int)v2;
}