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

Disassembly:
sub esp, 0x24
push ebx
push ebp
push esi
xor ebx, ebx
mov esi, ecx
mov dword [esp + 0xc], ebx
call fcn.004033c0
mov ebp, dword [esp + 0x34]
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalLock]
cmp eax, ebx
mov dword [esi + 0xb8], eax
jne 0x403813
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret 8
mov ecx, dword [esp + 0x38]
mov dword [esi + 0x74], ecx
mov edx, eax
mov dword [esi + 0xb4], eax
movzx ecx, byte [edx]
sub ecx, 0x47
jne 0x403842
movzx ecx, byte [edx + 1]
add edx, 1
sub ecx, 0x49
jne 0x403842
movzx ecx, byte [edx + 1]
add edx, 1
sub ecx, 0x46
je 0x403850
cmp ecx, ebx
mov edx, 1
jg 0x403852
or edx, 0xffffffff
jmp 0x403852
xor edx, edx
cmp edx, ebx
push edi
je 0x4039a0
lea edi, [eax + 3]
mov edx, edi
movzx ecx, byte [edx]
sub ecx, 0x38
jne 0x403880
movzx ecx, byte [edx + 1]
add edx, 1
sub ecx, 0x37
jne 0x403880
movzx ecx, byte [edx + 1]
add edx, 1
sub ecx, 0x61
je 0x40388e
cmp ecx, ebx
mov edx, 1
jg 0x403890
or edx, 0xffffffff
jmp 0x403890
xor edx, edx
cmp edx, ebx
jne 0x4038ce
mov edx, edi
movzx ecx, byte [edx]
sub ecx, 0x38
jne 0x4038b6
movzx ecx, byte [edx + 1]
add edx, 1
sub ecx, 0x39
jne 0x4038b6
movzx ecx, byte [edx + 1]
add edx, 1
sub ecx, 0x61
je 0x4038c4
cmp ecx, ebx
mov edx, 1
jg 0x4038c6
or edx, 0xffffffff
jmp 0x4038c6
xor edx, edx
cmp edx, ebx
je 0x4039a0
push ebp
mov dword [esi + 0xb8], ebx
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
lea edx, [esp + 0x10]
push edx
push ebx
push ebp
call dword [sym.imp.ole32.dll_CreateStreamOnHGlobal]
test eax, eax
jne 0x403a8c
mov eax, dword [esp + 0x3c]
mov ecx, dword [esp + 0x10]
lea edi, [esi + 0xb0]
push edi
push 0x405bd4
push ebx
push eax
push ecx
call dword [sym.imp.OLEAUT32.dll_OleCreatePictureIndirect]
test eax, eax
mov eax, dword [esp + 0x10]
push eax
je 0x403929
mov edx, dword [eax]
mov eax, dword [edx + 8]
call eax
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret 8
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
call edx
mov eax, dword [edi]
mov ecx, dword [eax]
lea edx, [esp + 0x38]
push edx
push eax
mov eax, dword [ecx + 0x18]
call eax
mov eax, dword [edi]
mov ecx, dword [eax]
lea edx, [esp + 0x14]
push edx
push eax
mov eax, dword [ecx + 0x1c]
call eax
mov ecx, dword [esi + 0x20]
push ecx
call dword [sym.imp.USER32.dll_GetDC]
mov ebx, dword [sym.imp.GDI32.dll_GetDeviceCaps]
push 0x9ec
mov edi, eax
push 0x58
push edi
call ebx
mov edx, dword [esp + 0x3c]
mov ebp, dword [sym.imp.KERNEL32.dll_MulDiv]
push eax
push edx
call ebp
push 0x9ec
push 0x5a
push edi
mov dword [esi + 0x64], eax
call ebx
push eax
mov eax, dword [esp + 0x1c]
push eax
call ebp
mov ecx, dword [esi + 0x20]
push edi
push ecx
mov dword [esi + 0x68], eax
call dword [sym.imp.USER32.dll_ReleaseDC]
jmp 0x403b8b
lea edi, [eax + 6]
mov dword [esi + 0x80], 1
mov dword [esi + 0xbc], edi
movzx ecx, byte [edi + 4]
mov edx, ecx
sar edx, 7
cmp edx, 1
jne 0x4039ee
and ecx, 7
add ecx, edx
shl edx, cl
lea edx, [edx + edx*2]
mov dword [esi + 0x7c], edx
movzx ecx, byte [edi + 5]
lea eax, [eax + ecx*2]
movzx edx, byte [ecx + eax + 0xd]
lea eax, [ecx + eax + 0xd]
xor ecx, ecx
mov ch, byte [eax + 2]
mov cl, byte [eax + 1]
shl ecx, 8
or ecx, edx
mov dword [esi + 0x6c], ecx
movzx eax, word [edi]
mov edx, dword [esi + 0x7c]
mov dword [esi + 0x64], eax
movzx ecx, word [edi + 2]
mov dword [esi + 0x68], ecx
add edx, 0xd
mov ecx, esi
xor edi, edi
mov dword [esi + 0x78], edx
call fcn.00402dd0
test eax, eax
je 0x403a23
mov ecx, esi
add edi, 1
call fcn.00402dd0
test eax, eax
jne 0x403a11
cmp edi, ebx
jne 0x403a3c
push ebp
mov dword [esi + 0xb8], ebx
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret 8
cmp edi, 1
jne 0x403a9f
push ebp
mov dword [esi + 0xb8], ebx
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
lea eax, [esp + 0x10]
push eax
push ebx
push ebp
call dword [sym.imp.ole32.dll_CreateStreamOnHGlobal]
test eax, eax
jne 0x403a8c
mov edx, dword [esp + 0x3c]
mov eax, dword [esp + 0x10]
lea ecx, [esi + 0xb0]
push ecx
push 0x405bd4
push ebx
push edx
push eax
call dword [sym.imp.OLEAUT32.dll_OleCreatePictureIndirect]
test eax, eax
mov eax, dword [esp + 0x10]
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
je 0x403a98
call edx
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret 8
call edx
jmp 0x403b8b
mov eax, dword [esi + 0x7c]
add eax, 0xd
lea ecx, [esp + 0x30]
push ecx
lea edx, [esp + 0x28]
push edx
mov dword [esi + 0x78], eax
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x38]
push ecx
lea edx, [esp + 0x24]
push edx
mov ecx, esi
call fcn.00402b00
mov edi, eax
cmp edi, ebx
je 0x403b6b
mov ebx, dword [sym.imp.ole32.dll_CreateStreamOnHGlobal]
mov ebp, dword [sym.imp.OLEAUT32.dll_OleCreatePictureIndirect]
mov edi, edi
lea eax, [esp + 0x3c]
push eax
push 1
push edi
mov dword [esp + 0x48], 0
call ebx
test eax, eax
je 0x403aff
push edi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
jmp 0x403b3b
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x3c]
lea ecx, [esp + 0x18]
push ecx
push 0x405bd4
push 0
push edx
push eax
call ebp
test eax, eax
mov eax, dword [esp + 0x3c]
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
je 0x403b29
call edx
jmp 0x403b3b
call edx
lea eax, [esp + 0x18]
push eax
lea ecx, [esi + 0xc0]
call fcn.00403710
lea ecx, [esp + 0x30]
push ecx
lea edx, [esp + 0x28]
push edx
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x38]
push ecx
lea edx, [esp + 0x24]
push edx
mov ecx, esi
call fcn.00402b00
mov edi, eax
test edi, edi
jne 0x403ae0
mov ebp, dword [esp + 0x38]
xor ebx, ebx
push ebp
mov dword [esi + 0xb8], ebx
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
lea ecx, [esi + 0xc0]
call fcn.00402930
test al, al
jne 0x403a8c
mov eax, dword [esi + 0x68]
mov ecx, dword [esi + 0x64]
push eax
push ecx
mov ecx, esi
call fcn.004027f0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret 8