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

Disassembly:
push 0xffffffffffffffff
push 0x4d8f70
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x50
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0x24], esi
mov eax, dword [esi + 0x14]
test eax, eax
je 0x46d8be
mov eax, dword [esp + 0x74]
or edi, 0xffffffff
cmp eax, edi
je 0x46d85a
cmp dword [esp + 0x78], edi
je 0x46d8be
lea ecx, [esp + 0x28]
call fcn.004ac979
push 0
mov dword [esp + 0x6c], 0
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push eax
lea ecx, [esp + 0x2c]
call fcn.004aca30
mov ecx, dword [esi + 0x14]
lea eax, [esp + 0x48]
push eax
push 0x18
push ecx
call dword [sym.imp.GDI32.dll_GetObjectA]
test eax, eax
je 0x46d8b1
mov eax, dword [esi + 0x14]
test eax, eax
je 0x46d8b1
mov edx, dword [esp + 0x2c]
mov esi, dword [sym.imp.GDI32.dll_SelectObject]
push eax
push edx
call esi
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x18], ebx
jne 0x46d8c5
lea ecx, [esp + 0x28]
mov dword [esp + 0x68], edi
call fcn.004acaae
xor eax, eax
jmp 0x46daab
mov edx, dword [esp + 0x50]
mov ebp, dword [esp + 0x2c]
mov ecx, dword [esp + 0x4c]
lea eax, [esp + 0x28]
neg eax
sbb eax, eax
push edx
and eax, ebp
mov edi, ecx
push ecx
push eax
mov dword [esp + 0x20], edi
mov dword [esp + 0x1c], edx
call dword [sym.imp.GDI32.dll_CreateCompatibleBitmap]
mov ebp, eax
test ebp, ebp
mov dword [esp + 0x1c], ebp
jne 0x46d918
mov eax, dword [esp + 0x2c]
push ebx
push eax
call esi
lea ecx, [esp + 0x28]
mov dword [esp + 0x68], 0xffffffff
call fcn.004acaae
xor eax, eax
jmp 0x46daab
lea ecx, [esp + 0x38]
call fcn.004ac979
mov ebx, dword [esp + 0x2c]
lea eax, [esp + 0x28]
neg eax
sbb eax, eax
mov byte [esp + 0x68], 1
and eax, ebx
push eax
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push eax
lea ecx, [esp + 0x3c]
call fcn.004aca30
mov ecx, dword [esp + 0x3c]
push ebp
push ecx
call esi
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x20], ebx
jne 0x46d98f
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x2c]
push edx
push eax
call esi
push ebp
call dword [sym.imp.GDI32.dll_DeleteObject]
lea ecx, [esp + 0x38]
mov byte [esp + 0x68], bl
call fcn.004acaae
lea ecx, [esp + 0x28]
mov dword [esp + 0x68], 0xffffffff
call fcn.004acaae
xor eax, eax
jmp 0x46daab
mov ecx, dword [esp + 0x2c]
lea eax, [esp + 0x28]
neg eax
mov edx, dword [esp + 0x3c]
push 0xcc0020
sbb eax, eax
push 0
and eax, ecx
mov ecx, dword [esp + 0x18]
push 0
push eax
push ecx
push edi
push 0
push 0
push edx
call dword [sym.imp.GDI32.dll_BitBlt]
mov eax, dword [esp + 0x14]
xor edi, edi
test eax, eax
jle 0x46da62
mov ebx, dword [sym.imp.GDI32.dll_SetPixel]
mov eax, dword [esp + 0x10]
xor esi, esi
test eax, eax
jle 0x46da4b
mov edx, dword [esp + 0x3c]
lea eax, [esp + 0x38]
neg eax
sbb eax, eax
push esi
and eax, edx
push edi
push eax
call dword [sym.imp.GDI32.dll_GetPixel]
mov ebp, eax
mov eax, dword [esp + 0x74]
cmp eax, 0xffffffff
je 0x46da18
cmp ebp, eax
jne 0x46da3e
mov ecx, dword [esp + 0x78]
mov ebp, dword [esp + 0x3c]
lea eax, [esp + 0x38]
push ecx
neg eax
sbb eax, eax
push esi
and eax, ebp
push edi
push eax
jmp 0x46da3c
mov edx, dword [esp + 0x70]
push edx
push ebp
call fcn.0046cb70
add esp, 8
cmp ebp, eax
je 0x46da3e
mov ebp, dword [esp + 0x3c]
lea ecx, [esp + 0x38]
neg ecx
sbb ecx, ecx
push eax
and ecx, ebp
push esi
push edi
push ecx
call ebx
mov eax, dword [esp + 0x10]
inc esi
cmp esi, eax
jl 0x46d9da
mov ebp, dword [esp + 0x1c]
mov eax, dword [esp + 0x14]
inc edi
cmp edi, eax
jl 0x46d9d0
mov esi, dword [sym.imp.GDI32.dll_SelectObject]
mov ebx, dword [esp + 0x20]
mov eax, dword [esp + 0x3c]
push ebx
push eax
call esi
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x2c]
push ecx
push edx
call esi
mov esi, dword [esp + 0x24]
mov eax, dword [esi + 0x14]
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
lea ecx, [esp + 0x38]
mov dword [esi + 0x14], ebp
mov byte [esp + 0x68], 0
call fcn.004acaae
lea ecx, [esp + 0x28]
mov dword [esp + 0x68], 0xffffffff
call fcn.004acaae
mov eax, 1
mov ecx, dword [esp + 0x60]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x5c
ret 0xc