// // LogL16fromY from 0xecc7a8 to 0xecc8d0 (296 bytes) // // 3 xrefs: // > sub_ECC910 @ 0xecc94c // > LogLuv32fromXYZ @ 0xecd5c4 // > @ 0x949d8 // // 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:11:38 +0000 // __int64 __fastcall LogL16fromY(int a1, double a2) { unsigned int v2; // w1 double v4; // d0 double v5; // [xsp+10h] [xbp+10h] double v6; // [xsp+10h] [xbp+10h] v2 = 0x7FFF; if ( a2 < 1.8371976e19 ) { v2 = 0xFFFF; if ( a2 > -1.8371976e19 ) { if ( a2 <= 5.4136769e-20 ) { v2 = 0; if ( a2 < -5.4136769e-20 ) { v4 = -a2; if ( a1 ) { v6 = log(v4); return (int)((double)rand() * 4.65661288e-10 + (v6 * 1.44269504 + 64.0) * 256.0 - 0.5) | 0xFFFF8000; } else { return (int)((log(v4) * 1.44269504 + 64.0) * 256.0) | 0xFFFF8000; } } } else if ( a1 ) { v5 = log(a2); return (unsigned int)(int)((double)rand() * 4.65661288e-10 + (v5 * 1.44269504 + 64.0) * 256.0 - 0.5); } else { return (unsigned int)(int)((log(a2) * 1.44269504 + 64.0) * 256.0); } } } return v2; }
GD Web Decomp Icon

GD Web Decomp

Raw Source