Function at 0x408120
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x432058
mov eax, dword fs:[0]
push eax
sub esp, 0x84
push ebx
push ebp
push esi
push edi
mov eax, dword [0x43fcd4]
xor eax, esp
push eax
lea eax, [esp + 0x98]
mov dword fs:[0], eax
mov edi, ecx
mov esi, edx
lea ecx, [esp + 0x5c]
mov byte [esp + 0x17], 0
call fcn.00415700
xor ebx, ebx
mov dword [esp + 0xa0], ebx
cmp esi, ebx
jne 0x408170
xor esi, esi
jmp 0x408173
mov esi, dword [esi + 4]
push esi
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push eax
lea ecx, [esp + 0x60]
call fcn.00415aff
mov eax, dword [esp + 0xa8]
cmp eax, ebx
jne 0x408193
xor eax, eax
jmp 0x408196
mov eax, dword [eax + 4]
push eax
mov eax, dword [esp + 0x64]
push eax
call fcn.00415dd1
mov ebp, dword [edi + 4]
mov esi, dword [edi]
mov edi, ebp
imul edi, esi
mov dword [esp + 0x50], eax
lea eax, [edi*4]
mov ecx, 1
mov edx, 0x20
push eax
mov dword [esp + 0x58], esi
mov dword [esp + 0x50], ebp
mov dword [esp + 0x70], 0x28
mov dword [esp + 0x74], esi
mov dword [esp + 0x78], ebp
mov word [esp + 0x7c], cx
mov word [esp + 0x7e], dx
mov dword [esp + 0x80], ebx
mov dword [esp + 0x5c], edi
mov dword [esp + 0x84], eax
mov dword [esp + 0x90], ebx
mov dword [esp + 0x94], ebx
call fcn.0040a389
mov ebx, eax
mov eax, dword [esp + 0x84]
push eax
push 0
push ebx
mov dword [esp + 0x4c], ebx
call fcn.0041d620
mov eax, dword [esp + 0xb8]
add esp, 0x10
test eax, eax
je 0x40822f
mov eax, dword [eax + 4]
mov edx, dword [esp + 0x60]
push 0
lea ecx, [esp + 0x70]
push ecx
push ebx
push ebp
push 0
push eax
push edx
call dword [sym.imp.GDI32.dll_GetDIBits]
xor ecx, ecx
cmp eax, ecx
jne 0x40825e
push ebx
call fcn.0040a394
mov bl, byte [esp + 0x1b]
add esp, 4
jmp 0x4083bd
xor ebx, ebx
xor edx, edx
xor eax, eax
cmp esi, edx
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x18], ecx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], eax
jle 0x40837f
mov ecx, dword [esp + 0x3c]
lea edi, [ecx + 2]
lea ecx, [ecx + esi*4 + 2]
mov dword [esp + 0x20], edi
mov dword [esp + 0x48], ecx
jmp 0x408293
xor edx, edx
xor edi, edi
cmp ebp, 2
mov dword [esp + 0x28], edx
mov dword [esp + 0x34], edx
mov dword [esp + 0x38], edx
mov dword [esp + 0x30], edx
mov dword [esp + 0x24], edx
mov dword [esp + 0x2c], edx
jl 0x40830c
mov eax, dword [esp + 0x20]
add esi, esi
add esi, esi
lea edx, [ebp - 2]
shr edx, 1
add esi, esi
inc edx
lea edi, [edx + edx]
movzx ebx, byte [eax - 2]
add dword [esp + 0x28], ebx
movzx ebx, byte [eax - 1]
add dword [esp + 0x38], ebx
movzx ebx, byte [eax]
add dword [esp + 0x24], ebx
movzx ebx, byte [ecx - 2]
add dword [esp + 0x34], ebx
movzx ebx, byte [ecx - 1]
add dword [esp + 0x30], ebx
movzx ebx, byte [ecx]
add dword [esp + 0x2c], ebx
add eax, esi
add ecx, esi
sub edx, 1
jne 0x4082c5
mov esi, dword [esp + 0x54]
mov ebp, dword [esp + 0x4c]
mov ebx, dword [esp + 0x40]
mov eax, dword [esp + 0x44]
cmp edi, ebp
jge 0x408332
mov ecx, dword [esp + 0x3c]
imul edi, esi
add edi, eax
movzx edx, byte [ecx + edi*4]
lea edi, [ecx + edi*4]
movzx ecx, byte [edi + 1]
add dword [esp + 0x18], ecx
add ebx, edx
movzx edx, byte [edi + 2]
add dword [esp + 0x1c], edx
mov edx, dword [esp + 0x28]
mov ecx, dword [esp + 0x34]
add dword [esp + 0x20], 4
add ecx, edx
mov edx, dword [esp + 0x30]
add ebx, ecx
mov ecx, dword [esp + 0x38]
add ecx, edx
add dword [esp + 0x18], ecx
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x2c]
add ecx, edx
add dword [esp + 0x1c], ecx
mov ecx, dword [esp + 0x48]
inc eax
add ecx, 4
cmp eax, esi
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], ecx
jl 0x408291
mov edi, dword [esp + 0x58]
mov eax, dword [esp + 0x3c]
push eax
call fcn.0040a394
mov eax, ebx
cdq
idiv edi
add esp, 4
mov bl, 1
movzx ecx, al
mov eax, dword [esp + 0x18]
cdq
idiv edi
shl ecx, 8
movzx edx, al
mov eax, dword [esp + 0x1c]
or ecx, edx
cdq
idiv edi
mov edx, dword [esp + 0xac]
shl ecx, 8
movzx eax, al
or ecx, eax
mov dword [edx], ecx
mov eax, dword [esp + 0x50]
test eax, eax
je 0x4083c8
mov eax, dword [eax + 4]
push eax
mov eax, dword [esp + 0x64]
push eax
call fcn.00415dd1
lea ecx, [esp + 0x5c]
call fcn.00415b68
lea ecx, [esp + 0x5c]
mov dword [esp + 0xa0], 0xffffffff
call fcn.00415b7e
mov al, bl
mov ecx, dword [esp + 0x98]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x90
ret