//
// WebPPictureCopy from 0x72b598 to 0x72b662 (202 bytes)
//
// 0 xrefs:
//
// 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 WebPPictureCopy(_DWORD *a1, _DWORD *a2)
{
bool v2; // zf
void *v6; // r2
v2 = a2 == nullptr;
if ( a2 )
v2 = a1 == nullptr;
if ( v2 )
return 0;
if ( a1 == a2 )
return 1;
memcpy(a2, a1, 0xACu);
sub_7276E0(a2);
if ( !WebPPictureAlloc((int)a2) )
return 0;
if ( *a1 )
{
WebPCopyPlane((void *)a1[13], 4 * a1[14], (void *)a2[13], 4 * a2[14], 4 * a2[2], a2[3]);
return 1;
}
WebPCopyPlane((void *)a1[4], a1[7], (void *)a2[4], a2[7], a2[2], a2[3]);
WebPCopyPlane((void *)a1[5], a1[8], (void *)a2[5], a2[8], (a2[2] + 1) >> 1, (a2[3] + 1) >> 1);
WebPCopyPlane((void *)a1[6], a1[8], (void *)a2[6], a2[8], (a2[2] + 1) >> 1, (a2[3] + 1) >> 1);
v6 = (void *)a2[9];
if ( !v6 )
return 1;
WebPCopyPlane((void *)a1[9], a1[10], v6, a2[10], a2[2], a2[3]);
return 1;
}