Function at 0x513940
Capabilities:
Capture screenshot

Disassembly:
push 0xffffffffffffffff
push 0x595f2e
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x84
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0xa4]
mov ebx, ecx
mov ecx, edi
call fcn.0058a4dc
mov ecx, dword [esp + 0xa8]
call fcn.0058b00b
mov ecx, dword [ebx + 0x1c]
lea eax, [esp + 0x58]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
mov esi, dword [esp + 0x64]
mov ecx, dword [esp + 0x5c]
mov ebp, dword [esp + 0x60]
mov eax, dword [esp + 0x58]
sub esi, ecx
sub ebp, eax
mov dword [esp + 0x20], esi
je 0x513d18
test esi, esi
je 0x513d18
push 0
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push eax
mov ecx, edi
call fcn.0058a474
mov edx, esi
xor eax, eax
neg edx
cmp edi, eax
mov dword [esp + 0x68], 0x28
mov dword [esp + 0x6c], ebp
mov dword [esp + 0x70], edx
mov word [esp + 0x74], 1
mov word [esp + 0x76], 0x20
mov dword [esp + 0x78], eax
mov dword [esp + 0x7c], eax
mov dword [esp + 0x80], eax
mov dword [esp + 0x84], eax
mov dword [esp + 0x88], eax
mov dword [esp + 0x8c], eax
jne 0x513a10
xor ecx, ecx
jmp 0x513a13
mov ecx, dword [edi + 4]
push eax
lea edx, [esp + 0x94]
push eax
push edx
push eax
lea eax, [esp + 0x78]
push eax
push ecx
call dword [sym.imp.GDI32.dll_CreateDIBSection]
mov ecx, dword [esp + 0xa8]
push eax
call fcn.0058afb4
mov eax, dword [esp + 0xa8]
test eax, eax
je 0x513a45
mov eax, dword [eax + 4]
mov ecx, dword [edi + 4]
push eax
push ecx
call fcn.0058a5b5
mov eax, dword [ebx + 0x58]
xor ecx, ecx
cmp eax, ecx
mov dword [esp + 0x10], ecx
jle 0x513a75
mov edx, eax
cmp edx, ecx
je 0x513a65
mov ecx, dword [ebx + 0x50]
push eax
push ecx
push 0x3eb
call fcn.0050eef0
mov dword [esp + 0x10], eax
mov edx, dword [ebx + 0x44]
push edx
call fcn.0048b580
mov ecx, dword [esp + 0x14]
add esp, 4
test ecx, ecx
mov dword [esp + 0x1c], eax
jne 0x513ae9
push eax
lea ecx, [esp + 0x24]
call fcn.0058b071
lea eax, [esp + 0x20]
mov ecx, edi
push eax
mov dword [esp + 0xa0], 0
call fcn.0058a608
mov ecx, dword [edi + 4]
push 0xf00021
push esi
push ebp
push 0
push 0
push ecx
mov ebx, eax
call dword [sym.imp.GDI32.dll_PatBlt]
push ebx
mov ecx, edi
call fcn.0058a608
mov dword [esp + 0x20], 0x963f54
mov dword [esp + 0x9c], 1
lea ecx, [esp + 0x20]
jmp 0x513d13
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x963f70
push ecx
lea ecx, [esp + 0x18]
mov dword [esp + 0xa0], 2
call fcn.0058afb4
mov eax, dword [esp + 0x18]
lea edx, [esp + 0x40]
push edx
push 0x18
push eax
call dword [sym.imp.GDI32.dll_GetObjectA]
lea ecx, [esp + 0x28]
call fcn.0058a3bd
test edi, edi
mov byte [esp + 0x9c], 3
jne 0x513b39
xor eax, eax
jmp 0x513b3c
mov eax, dword [edi + 4]
push eax
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push eax
lea ecx, [esp + 0x2c]
call fcn.0058a474
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x2c]
lea eax, [esp + 0x14]
neg eax
sbb eax, eax
and eax, edx
push eax
push ecx
call fcn.0058a5b5
mov dword [esp + 0x10], eax
mov eax, dword [ebx + 0x5c]
dec eax
je 0x513c96
sub eax, 2
je 0x513c3e
mov edx, dword [esp + 0x1c]
lea ecx, [esp + 0x38]
push edx
call fcn.0058b071
lea eax, [esp + 0x38]
mov ecx, edi
push eax
mov byte [esp + 0xa0], 4
call fcn.0058a608
mov ecx, dword [edi + 4]
push 0xf00021
push esi
push ebp
push 0
push 0
push ecx
mov dword [esp + 0x34], eax
call dword [sym.imp.GDI32.dll_PatBlt]
mov edx, dword [esp + 0x1c]
mov ecx, edi
push edx
call fcn.0058a608
mov eax, dword [ebx + 0x5c]
mov ebx, dword [esp + 0x44]
cmp eax, 2
jne 0x513bea
mov eax, ebp
mov ecx, dword [esp + 0x48]
sub eax, ebx
cdq
sub eax, edx
mov ebp, eax
mov eax, esi
sub eax, ecx
cdq
sub eax, edx
sar ebp, 1
sar eax, 1
jmp 0x513bee
xor eax, eax
xor ebp, ebp
mov esi, dword [esp + 0x2c]
lea ecx, [esp + 0x28]
neg ecx
sbb ecx, ecx
push 0xcc0020
mov edx, dword [edi + 4]
and ecx, esi
push 0
push 0
push ecx
mov ecx, dword [esp + 0x58]
push ecx
push ebx
push eax
push ebp
push edx
call dword [sym.imp.GDI32.dll_BitBlt]
mov dword [esp + 0x38], 0x963f54
lea ecx, [esp + 0x38]
mov byte [esp + 0x9c], 5
call fcn.0058b00b
mov byte [esp + 0x9c], 3
jmp 0x513cd5
xor ebx, ebx
test esi, esi
jle 0x513cd5
mov ecx, dword [esp + 0x44]
xor esi, esi
test ebp, ebp
jle 0x513c86
mov edx, dword [esp + 0x2c]
lea eax, [esp + 0x28]
neg eax
sbb eax, eax
push 0xcc0020
and eax, edx
push 0
push 0
push eax
mov eax, dword [esp + 0x58]
push eax
push ecx
mov ecx, dword [edi + 4]
push ebx
push esi
push ecx
call dword [sym.imp.GDI32.dll_BitBlt]
mov ecx, dword [esp + 0x44]
add esi, ecx
cmp esi, ebp
jl 0x513c52
mov edx, dword [esp + 0x48]
mov eax, dword [esp + 0x20]
add ebx, edx
cmp ebx, eax
jl 0x513c4c
jmp 0x513cd5
call fcn.005123d0
push eax
mov ecx, edi
call fcn.0058a76e
mov edx, dword [esp + 0x2c]
lea eax, [esp + 0x28]
mov ecx, dword [esp + 0x44]
push 0xcc0020
neg eax
sbb eax, eax
and eax, edx
mov edx, dword [esp + 0x4c]
push edx
mov edx, dword [edi + 4]
push ecx
push 0
push 0
push eax
push esi
push ebp
push 0
push 0
push edx
call dword [sym.imp.GDI32.dll_StretchBlt]
mov eax, dword [esp + 0x10]
test eax, eax
je 0x513ce0
mov eax, dword [eax + 4]
push eax
mov eax, dword [esp + 0x30]
push eax
call fcn.0058a5b5
lea ecx, [esp + 0x28]
mov byte [esp + 0x9c], 2
call fcn.0058a4f2
mov dword [esp + 0x14], 0x963f54
mov dword [esp + 0x9c], 6
lea ecx, [esp + 0x14]
call fcn.0058b00b
mov ecx, dword [esp + 0x94]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x90
ret 8