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

Disassembly:
sub esp, 0x5c
push ebp
mov ebp, dword [esp + 0x70]
test ebp, ebp
push esi
mov esi, dword [esp + 0x70]
push edi
jne 0x4ad8b8
mov ebp, esi
mov dword [esp + 0x78], ebp
mov edi, dword [esi + 8]
mov ecx, dword [esi]
cmp ecx, edi
jge 0x4add1a
mov edx, dword [esi + 0xc]
mov eax, dword [esi + 4]
cmp eax, edx
jge 0x4add1a
cmp ecx, dword [ebp + 8]
jg 0x4add1a
cmp eax, dword [ebp + 0xc]
jg 0x4add1a
cmp edi, dword [ebp]
jl 0x4add1a
cmp edx, dword [ebp + 4]
jl 0x4add1a
mov edi, dword [esp + 0x6c]
cmp dword [edi], 0
push ebx
jne 0x4ad91f
mov eax, dword [0x58b2d0]
push 0xd
push eax
call fcn.004a9cd0
mov ebx, dword [esp + 0x74]
push eax
push ebx
call fcn.004ab670
test eax, eax
mov dword [edi], eax
je 0x4ad956
mov eax, dword [esi + 4]
mov ecx, dword [esi + 0xc]
mov ebx, dword [edi]
mov edx, dword [esi]
mov ebp, dword [esi + 8]
push ebx
sub ecx, eax
lea ebx, [ecx - 2]
push ebx
sub ebp, edx
lea ebx, [ebp - 2]
push ebx
lea ebx, [eax + 1]
push ebx
lea ebx, [edx + 1]
push ebx
mov ebx, dword [esp + 0x88]
push ecx
push ebp
push eax
push edx
push ebx
call fcn.004a8530
mov ebp, dword [esp + 0x7c]
mov edx, dword [esi + 4]
mov ecx, dword [esi]
mov eax, dword [esi + 8]
add ecx, 1
add edx, 1
sub eax, 1
mov dword [esp + 0x24], ecx
mov ecx, dword [esi + 0xc]
mov dword [esp + 0x28], edx
push ebp
lea edx, [esp + 0x28]
mov dword [esp + 0x30], eax
push edx
lea eax, [esp + 0x3c]
sub ecx, 1
push eax
mov dword [esp + 0x3c], ecx
call dword [sym.imp.USER32.dll_IntersectRect]
mov esi, dword [esp + 0x3c]
sub esi, dword [esp + 0x34]
mov ebp, dword [esp + 0x40]
sub ebp, dword [esp + 0x38]
test esi, esi
jle 0x4add19
test ebp, ebp
jle 0x4add19
cmp dword [edi + 4], 0
jne 0x4ad9c6
push ebx
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
test eax, eax
mov dword [edi + 4], eax
je 0x4add19
lea eax, [esi + 0xf]
cdq
and edx, 0xf
add eax, edx
mov ebx, eax
lea eax, [ebp + 0xf]
cdq
and edx, 0xf
add eax, edx
mov esi, eax
mov eax, dword [edi + 8]
sar ebx, 4
sar esi, 4
shl ebx, 4
shl esi, 4
test eax, eax
je 0x4ada1a
cmp ebx, dword [edi + 0xc]
jg 0x4ad9fd
cmp esi, dword [edi + 0x10]
jle 0x4ada95
test eax, eax
je 0x4ada1a
mov ecx, dword [edi + 0xc]
cmp ebx, ecx
jge 0x4ada0a
mov ebx, ecx
mov ecx, dword [edi + 0x10]
cmp esi, ecx
jge 0x4ada13
mov esi, ecx
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
xor eax, eax
push eax
push eax
lea edx, [edi + 0x14]
push edx
mov dword [esp + 0x5c], eax
mov dword [esp + 0x60], eax
push eax
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], eax
mov dword [esp + 0x5c], eax
mov ecx, esi
neg ecx
mov dword [esp + 0x68], eax
mov dword [esp + 0x6c], eax
mov dword [esp + 0x70], eax
mov dword [esp + 0x74], eax
mov dword [esp + 0x78], eax
mov dword [esp + 0x64], eax
lea eax, [esp + 0x54]
mov dword [esp + 0x5c], ecx
mov ecx, dword [esp + 0x84]
push eax
push ecx
mov dword [esp + 0x5c], 0x28
mov dword [esp + 0x60], ebx
mov word [esp + 0x68], 1
mov word [esp + 0x6a], 0x20
call dword [sym.imp.GDI32.dll_CreateDIBSection]
test eax, eax
mov dword [edi + 8], eax
mov dword [edi + 0xc], ebx
mov dword [edi + 0x10], esi
je 0x4add19
mov ebx, dword [esp + 0x80]
push 0
push 0
push ebx
call dword [sym.imp.GDI32.dll_GetRegionData]
mov esi, eax
test esi, esi
je 0x4add19
push esi
call fcn.004a2340
mov ebp, eax
push ebp
push esi
push ebx
mov dword [esp + 0x2c], ebp
call dword [sym.imp.GDI32.dll_GetRegionData]
cmp dword [ebp + 8], 0
mov dword [esp + 0x10], 0
jbe 0x4add13
lea edx, [ebp + 0x20]
mov dword [esp + 0x78], edx
nop
mov eax, dword [esp + 0x78]
push eax
lea ecx, [esp + 0x38]
push ecx
lea edx, [esp + 0x2c]
push edx
call dword [sym.imp.USER32.dll_IntersectRect]
mov ebx, dword [esp + 0x2c]
sub ebx, dword [esp + 0x24]
mov esi, dword [esp + 0x30]
sub esi, dword [esp + 0x28]
test ebx, ebx
mov dword [esp + 0x7c], ebx
mov dword [esp + 0x1c], esi
jle 0x4adcfa
test esi, esi
jle 0x4adcfa
mov eax, dword [edi + 8]
mov ecx, dword [edi + 4]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SelectObject]
mov edx, dword [edi + 4]
push 0
push edx
mov ebp, eax
call dword [0x581e6c]
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x74]
push 0xcc0020
mov dword [esp + 0x74], eax
mov eax, dword [esp + 0x2c]
push eax
mov eax, dword [edi + 4]
push ecx
push edx
push esi
push ebx
push 0
push 0
push eax
call dword [sym.imp.GDI32.dll_BitBlt]
mov ecx, dword [esp + 0x70]
mov edx, dword [edi + 4]
push ecx
push edx
call dword [0x581e6c]
mov eax, dword [edi + 4]
push ebp
push eax
call dword [sym.imp.GDI32.dll_SelectObject]
call fcn.004a6610
movzx ecx, ah
movzx ebp, al
shr eax, 0x10
movzx edx, al
mov dword [esp + 0x18], ecx
mov ecx, dword [edi + 0x14]
mov dword [esp + 0x14], edx
mov dword [esp + 0x80], esi
jmp 0x4adba4
mov ebx, dword [esp + 0x7c]
mov dword [esp + 0x70], ebx
jmp 0x4adbb0
mov bl, byte [ecx]
mov esi, dword [esp + 0x14]
movzx eax, bl
sub esi, eax
imul esi, dword [0x57e614]
mov eax, 0x80808081
imul esi
add edx, esi
mov esi, dword [esp + 0x18]
sar edx, 7
mov eax, edx
shr eax, 0x1f
add eax, edx
add al, bl
mov byte [ecx], al
mov bl, byte [ecx + 1]
add ecx, 1
movzx edx, bl
sub esi, edx
imul esi, dword [0x57e614]
mov eax, 0x80808081
imul esi
add edx, esi
sar edx, 7
mov eax, edx
shr eax, 0x1f
add eax, edx
add al, bl
mov byte [ecx], al
mov bl, byte [ecx + 1]
add ecx, 1
movzx edx, bl
mov esi, ebp
sub esi, edx
imul esi, dword [0x57e614]
mov eax, 0x80808081
imul esi
add edx, esi
sar edx, 7
mov eax, edx
shr eax, 0x1f
add eax, edx
add al, bl
mov byte [ecx], al
add ecx, 2
sub dword [esp + 0x70], 1
jne 0x4adbb0
mov edx, dword [edi + 0xc]
sub edx, dword [esp + 0x7c]
sub dword [esp + 0x80], 1
lea ecx, [ecx + edx*4]
jne 0x4adba0
xor eax, eax
mov dword [esp + 0x50], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x54], eax
push 0xcc0020
mov dword [esp + 0x5c], eax
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], eax
mov dword [esp + 0x68], eax
mov dword [esp + 0x6c], eax
mov eax, dword [edi + 0xc]
push 0
mov dword [esp + 0x50], eax
mov eax, dword [edi + 0x10]
mov ecx, eax
neg ecx
mov dword [esp + 0x54], ecx
mov ecx, dword [edi + 0x14]
lea edx, [esp + 0x4c]
push edx
mov edx, dword [esp + 0x88]
push ecx
mov ecx, dword [esp + 0x2c]
push ecx
push edx
sub eax, ecx
push eax
mov eax, dword [esp + 0x40]
push 0
push ecx
mov ecx, dword [esp + 0x98]
push edx
mov edx, dword [esp + 0x50]
push edx
push eax
push ecx
mov dword [esp + 0x78], 0x28
mov word [esp + 0x84], 1
mov word [esp + 0x86], 0x20
mov dword [esp + 0x88], 0
call dword [sym.imp.GDI32.dll_StretchDIBits]
mov ebp, dword [esp + 0x20]
mov eax, dword [esp + 0x10]
add dword [esp + 0x78], 0x10
add eax, 1
cmp eax, dword [ebp + 8]
mov dword [esp + 0x10], eax
jb 0x4adae0
push ebp
call fcn.004a23a0
pop ebx
pop edi
pop esi
pop ebp
add esp, 0x5c
ret 0x14