// // sub_6AF370 from 0x6af370 to 0x6af588 (536 bytes) // // 2 xrefs: // > sub_6B455C @ 0x6b6190 // > sub_6B455C @ 0x6b6cf8 // // This function is hookable on this platform! // // Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings // int __fastcall sub_6AF370(_DWORD *a1, int a2, int *a3) { unsigned int v3; // r3 int v5; // r3 int v6; // r3 unsigned int *v11; // [sp+1Ch] [bp-20h] BYREF unsigned int v12; // [sp+20h] [bp-1Ch] BYREF int v13; // [sp+24h] [bp-18h] int v14; // [sp+28h] [bp-14h] unsigned int *v15; // [sp+2Ch] [bp-10h] _QWORD *v16; // [sp+30h] [bp-Ch] unsigned int i; // [sp+34h] [bp-8h] v3 = *(unsigned __int16 *)(a2 + 2); if ( v3 > 0x12 || ((1 << v3) & 0x52010) == 0 ) return 2; v13 = sub_6AAEA4(a1, a2, (int *)&v12, 8u, (int *)&v11); if ( !v13 && v11 ) { v5 = *(unsigned __int16 *)(a2 + 2); if ( v5 == 16 || v5 == 18 ) { *a3 = (int)v11; if ( (a1[3] & 0x80) != 0 ) TIFFSwabArrayOfLong8(*a3, v12); return 0; } else { v14 = TIFFmalloc(8 * v12); if ( v14 ) { v6 = *(unsigned __int16 *)(a2 + 2); if ( v6 == 4 || v6 == 13 ) { v15 = v11; v16 = (_QWORD *)v14; for ( i = 0; i < v12; ++i ) { if ( (a1[3] & 0x80) != 0 ) TIFFSwabLong(v15); *v16++ = *v15++; } } TIFFfree(v11); if ( v13 ) { TIFFfree(v14); return v13; } else { *a3 = v14; return 0; } } else { TIFFfree(v11); return 7; } } } else { *a3 = 0; return v13; } }
GD Web Decomp Icon

GD Web Decomp

Raw Source