Function at 0x4a6f40
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x576bd0
mov eax, dword fs:[0]
push eax
sub esp, 0x70
push ebx
push esi
push edi
mov eax, dword [0x5c5678]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, edx
mov edx, dword [ebp + 8]
lea eax, [ebp - 0x2c]
push eax
push ecx
push edx
mov dword [ebp - 0x2c], 0x60
call fcn.004a6340
mov edi, eax
xor ebx, ebx
add esp, 0xc
mov dword [ebp - 0x30], edi
cmp edi, ebx
jne 0x4a6fa1
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [esi + 4]
mov eax, dword [esi]
mov edx, dword [esi + 8]
push 0x60
mov dword [ebp - 0x64], ecx
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 0x68], eax
mov eax, dword [esi + 0xc]
push 0x64
push ecx
mov dword [ebp - 0x60], edx
mov dword [ebp - 0x5c], eax
call dword [sym.imp.KERNEL32.dll_MulDiv]
push eax
push ebx
call fcn.0046daa0
lea esi, [ebp - 0x68]
call fcn.00486740
mov eax, dword [edi + 4]
lea edx, [ebp - 0x28]
push edx
push eax
mov dword [ebp - 0x28], ebx
call sub.gdiplus.dll_GdipGetImageWidth
cmp eax, ebx
je 0x4a6fec
mov dword [edi + 8], eax
mov edx, dword [edi + 4]
lea ecx, [ebp - 0x14]
push ecx
push edx
mov dword [ebp - 0x14], ebx
call sub.gdiplus.dll_GdipGetImageHeight
cmp eax, ebx
je 0x4a7003
mov dword [edi + 8], eax
mov ebx, dword [ebp - 0x28]
mov esi, dword [ebp + 0x10]
mov ecx, dword [ebp - 0x14]
mov eax, ebx
cdq
sub eax, edx
sar eax, 1
mov edi, ebx
mov dword [ebp - 0x48], eax
imul edi, esi
mov eax, ecx
cdq
sub eax, edx
sar eax, 1
mov dword [ebp - 0x50], esi
mov dword [ebp - 0x58], edi
fild dword [ebp - 0x50]
mov dword [ebp - 0x54], ecx
mov dword [ebp - 0x44], eax
test esi, esi
jge 0x4a703b
fadd dword [0x59a3f8]
fdivr qword [0x59a448]
sub ecx, dword [ebp - 0x5c]
mov eax, dword [ebp - 0x68]
mov edx, dword [ebp - 0x64]
xor esi, esi
push esi
push esi
mov dword [ebp - 0x78], eax
mov dword [ebp - 0x6c], ecx
push esi
lea ecx, [ebp - 0x78]
mov dword [ebp - 0x74], edx
mov eax, ebx
sub eax, dword [ebp - 0x60]
push ecx
lea edx, [ebp - 0x18]
push edx
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x34], esi
mov dword [ebp - 0x70], eax
fstp dword [ebp - 0x38]
call fcn.0049f3d0
add esp, 0x14
mov dword [ebp - 4], esi
mov esi, dword [ebp - 0x18]
test esi, esi
jne 0x4a708f
mov dword [ebp - 4], 0xffffffff
jmp 0x4a73f5
mov ax, word [ebp + 0xc]
xor ecx, ecx
mov word [ebp - 0x20], ax
lea eax, [ebp - 0x20]
mov word [ebp - 0x1e], cx
lea ecx, [eax + 2]
lea edx, [esi + 0x4c]
mov dword [ebp - 0x28], ecx
lea esp, [esp]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4a70b0
sub eax, dword [ebp - 0x28]
sar eax, 1
push eax
lea eax, [ebp - 0x20]
push eax
push edx
call fcn.004253c0
or eax, 0xffffffff
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], eax
mov dword [esi + 0x14], eax
push 0x10
mov dword [esi + 0x18], eax
call sub.gdiplus.dll_GdipAlloc
mov esi, eax
xor eax, eax
mov dword [ebp - 0x28], eax
cmp esi, eax
je 0x4a7117
mov edx, dword [ebp - 0x14]
lea ecx, [ebp - 0x28]
push ecx
push eax
push 0x26200a
push eax
push edx
push edi
mov dword [esi], vtable.Gdiplus::Bitmap.0
call sub.gdiplus.dll_GdipCreateBitmapFromScan0
mov dword [esi + 8], eax
mov eax, dword [ebp - 0x28]
mov edi, esi
mov dword [esi + 4], eax
mov dword [ebp - 0x28], edi
jmp 0x4a711a
mov edi, dword [ebp - 0x28]
mov dword [ebp - 0x20], edi
test edi, edi
je 0x4a73e3
push 8
call sub.gdiplus.dll_GdipAlloc
mov esi, eax
test esi, esi
je 0x4a72c4
mov ecx, dword [edi + 4]
lea eax, [ebp - 0x24]
push eax
push ecx
mov dword [ebp - 0x24], 0
call sub.gdiplus.dll_GdipGetImageGraphicsContext
mov edx, dword [ebp - 0x24]
mov dword [esi + 4], eax
push 2
mov eax, edx
push eax
mov dword [esi], edx
call sub.gdiplus.dll_GdipSetPixelOffsetMode
test eax, eax
je 0x4a7163
mov dword [esi + 4], eax
mov ecx, dword [esi]
push 4
push ecx
call sub.gdiplus.dll_GdipSetSmoothingMode
xor ecx, ecx
cmp eax, ecx
je 0x4a7176
mov dword [esi + 4], eax
mov eax, ebx
cdq
sub eax, edx
sar eax, 1
neg eax
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0x14]
cdq
sub eax, edx
sar eax, 1
neg eax
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x24], ecx
cmp dword [ebp + 0x10], ecx
jbe 0x4a72b6
fild dword [ebp - 0x44]
mov edx, dword [ebp + 8]
mov dword [ebp - 0x5c], edx
mov dword [ebp - 0x1c], ecx
fstp dword [ebp - 0x3c]
fild dword [ebp - 0x48]
fstp dword [ebp - 0x40]
mov eax, dword [ebp - 0x24]
fild dword [ebp - 0x24]
test eax, eax
jge 0x4a71c0
fadd dword [0x59a3f8]
mov ecx, dword [ebp - 0x14]
fmul dword [ebp - 0x38]
mov edx, dword [ebp - 0x1c]
mov eax, dword [esi]
push 0
fstp dword [ebp - 0x44]
push ecx
push ebx
push 0
push edx
push eax
call sub.gdiplus.dll_GdipSetClipRectI
test eax, eax
je 0x4a71e2
mov dword [esi + 4], eax
fldz
mov ecx, dword [esi]
push 0
sub esp, 8
fstp dword [esp + 4]
fild dword [ebp - 0x1c]
fstp dword [esp]
push ecx
call sub.gdiplus.dll_GdipTranslateWorldTransform
test eax, eax
je 0x4a7202
mov dword [esi + 4], eax
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.USER32.dll_GetWindowDC]
mov edi, eax
mov dword [ebp - 0x60], edi
push edi
mov byte [ebp - 4], 1
mov ecx, dword [ebp - 0x18]
push esi
call fcn.004a0aa0
mov eax, dword [ebp + 8]
push edi
mov byte [ebp - 4], 0
push eax
mov dword [ebp - 0x60], 0
call dword [sym.imp.USER32.dll_ReleaseDC]
fld dword [ebp - 0x3c]
mov ecx, dword [esi]
push 0
sub esp, 8
fstp dword [esp + 4]
fld dword [ebp - 0x40]
fstp dword [esp]
push ecx
call sub.gdiplus.dll_GdipTranslateWorldTransform
test eax, eax
je 0x4a7256
mov dword [esi + 4], eax
fld dword [ebp - 0x44]
mov edx, dword [esi]
push 0
push ecx
fstp dword [esp]
push edx
call sub.gdiplus.dll_GdipRotateWorldTransform
test eax, eax
je 0x4a726e
mov dword [esi + 4], eax
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x4c]
mov edx, dword [ebp - 0x50]
push eax
mov eax, dword [ebp - 0x30]
push ebx
push ecx
mov ecx, dword [eax + 4]
push edx
mov edx, dword [esi]
push ecx
push edx
call sub.gdiplus.dll_GdipDrawImageRectI
test eax, eax
je 0x4a7291
mov dword [esi + 4], eax
mov eax, dword [esi]
push eax
call sub.gdiplus.dll_GdipResetWorldTransform
test eax, eax
je 0x4a72a0
mov dword [esi + 4], eax
mov eax, dword [ebp - 0x24]
add dword [ebp - 0x1c], ebx
inc eax
mov dword [ebp - 0x24], eax
cmp eax, dword [ebp + 0x10]
jb 0x4a71b0
mov edi, dword [ebp - 0x28]
mov ecx, dword [esi]
push ecx
call sub.gdiplus.dll_GdipDeleteGraphics
push esi
call sub.gdiplus.dll_GdipFree
test byte [0x5d3248], 1
jne 0x4a7302
or dword [0x5d3248], 1
mov eax, 0x60
mov dword [0x5d324c], 0x64
mov dword [0x5d3250], eax
mov dword [0x5d3254], eax
mov byte [0x5d3258], 0
call fcn.00403ed0
test al, al
jne 0x4a7302
call fcn.0046da40
mov edx, dword [ebp + 0x10]
mov eax, dword [ebp - 0x2c]
push edx
push eax
lea esi, [ebp - 0x58]
mov eax, 0x5d324c
call fcn.004a6110
test al, al
je 0x4a7345
mov ecx, dword [ebp - 0x54]
mov edx, dword [ebp - 0x58]
push 0
push 0
push 0
push ecx
push edx
push edi
call fcn.004d3370
mov esi, eax
add esp, 0x18
test esi, esi
je 0x4a7345
mov eax, dword [edi]
mov edx, dword [eax]
push 1
mov ecx, edi
call edx
mov dword [ebp - 0x20], esi
mov ecx, dword [ebp - 0x20]
push 0x64
lea eax, [ebp - 0x50]
push 0x58f384
push eax
call fcn.004d3a00
add esp, 0xc
mov ebx, dword [ebp - 0x50]
cmp dword [ebx - 0xc], 0
je 0x4a73c3
lea esi, [ebp - 0x4c]
call fcn.00478360
mov byte [ebp - 4], 3
mov esi, dword [ebp - 0x4c]
test esi, esi
je 0x4a73ac
push ecx
mov eax, esp
mov dword [ebp - 0x44], esp
push eax
mov edi, str.disable_resize
call fcn.00422950
push ecx
mov byte [ebp - 4], 4
mov ecx, esp
mov dword [ebp - 0x40], esp
push ecx
mov edi, ebx
call fcn.00422950
mov byte [ebp - 4], 5
mov ecx, esi
mov byte [ebp - 4], 3
call fcn.00478260
mov dword [ebp - 0x34], eax
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov byte [ebp - 4], 2
test esi, esi
je 0x4a73c3
mov edx, dword [esi]
mov eax, dword [edx + 8]
push esi
call eax
add ebx, 0xfffffff0
or edx, 0xffffffff
lea ecx, [ebx + 0xc]
mov byte [ebp - 4], 0
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4a73e3
mov ecx, dword [ebx]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push ebx
call edx
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
mov ecx, dword [ebp - 0x30]
mov eax, dword [ecx]
mov edx, dword [eax]
push 1
call edx
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x4a740f
mov eax, dword [ecx]
mov edx, dword [eax]
push 1
call edx
mov eax, dword [ebp - 0x34]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret