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

Disassembly:
sub esp, 0x7c
push ebx
push ebp
mov ebp, dword [esp + 0x8c]
xor ebx, ebx
cmp ebp, ebx
push esi
push edi
jne 0x4f1c80
xor al, al
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x7c
ret 8
mov eax, dword [ebp]
mov edx, dword [eax + 0x14]
mov ecx, ebp
call edx
push 1
mov esi, eax
mov eax, dword [ebp]
mov edx, dword [eax + 8]
push 0xe
lea ecx, [esp + 0x30]
push ecx
mov ecx, ebp
mov dword [esp + 0x28], esi
mov byte [esp + 0x25], bl
call edx
test eax, eax
jne 0x4f1ceb
mov edi, 0x5bce10
mov esi, str.Not_a_BMP
mov ecx, 0xa
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
mov byte [esp + 0x19], 1
je 0x4f27ac
mov ecx, dword [esp + 0x90]
push 0xff
add ecx, 0x44
push str.Not_a_BMP
push ecx
call fcn.0057cac0
add esp, 0xc
jmp 0x4f27ac
mov edx, dword [esp + 0x90]
mov dl, byte [edx + 0x1b6]
cmp dl, bl
je 0x4f1d02
mov eax, dword [esp + 0x2a]
jmp 0x4f1d24
mov ecx, dword [esp + 0x2a]
mov eax, ecx
shl ecx, 0x10
and eax, 0xff00
or eax, ecx
xor ecx, ecx
mov ch, byte [esp + 0x2c]
shl eax, 8
or eax, ecx
movzx ecx, byte [esp + 0x2d]
or eax, ecx
cmp dl, bl
mov dword [esp + 0x2a], eax
je 0x4f1d32
mov eax, dword [esp + 0x32]
jmp 0x4f1d54
mov ecx, dword [esp + 0x32]
xor edx, edx
mov dh, byte [esp + 0x34]
mov eax, ecx
and eax, 0xff00
shl ecx, 0x10
or eax, ecx
movzx ecx, byte [esp + 0x35]
shl eax, 8
or eax, edx
or eax, ecx
cmp word [esp + 0x28], 0x4d42
mov dword [esp + 0x32], eax
je 0x4f1d71
mov edx, dword [ebp]
mov eax, dword [edx + 0x10]
push ebx
push esi
mov ecx, ebp
mov dword [esp + 0x3a], ebx
call eax
mov edi, dword [esp + 0x90]
lea esi, [esp + 0x60]
mov ebx, ebp
call fcn.004f2840
test al, al
jne 0x4f1dc7
mov edi, 0x5bce10
mov esi, str.Error_reading_BMP_info
mov ecx, 0x17
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
mov byte [esp + 0x19], 1
je 0x4f27ac
mov eax, dword [esp + 0x90]
push 0xff
add eax, 0x44
push str.Error_reading_BMP_info
push eax
call fcn.0057cac0
add esp, 0xc
jmp 0x4f27ac
cmp dword [esp + 0x60], 0xc
mov ecx, dword [esp + 0x70]
mov eax, dword [esp + 0x68]
movzx edx, word [esp + 0x6e]
sete byte [esp + 0x17]
test eax, eax
mov dword [esp + 0x20], ecx
setl cl
test cl, cl
mov dword [esp + 0x5c], edx
mov byte [esp + 0x27], cl
je 0x4f1df9
neg eax
mov dword [esp + 0x68], eax
mov ecx, edi
cmp dword [ecx + 0x148], 0xffffffff
jne 0x4f1e55
mov edx, dword [esp + 0x64]
mov dword [ecx + 0x10], eax
mov eax, 1
mov dword [ecx + 0x40], eax
mov dword [ecx + 0xc], edx
mov byte [esp + 0x19], al
mov edi, 0x5bce10
mov esi, str.output_dimensions_returned
mov ecx, 0x1b
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
je 0x4f27ac
mov ecx, dword [esp + 0x90]
push 0xff
add ecx, 0x44
push str.output_dimensions_returned
push ecx
call fcn.0057cac0
add esp, 0xc
jmp 0x4f27ac
push 1
push eax
mov eax, dword [esp + 0x6c]
mov edi, ecx
push eax
mov eax, edx
mov ebx, edi
call fcn.004e4d10
test eax, eax
jne 0x4f1ea3
mov edi, 0x5bce10
mov ecx, 1
mov esi, edi
xor edx, edx
mov byte [esp + 0x19], cl
repe cmpsb byte [esi], byte es:[edi]
je 0x4f27ac
push 0xff
mov eax, ebx
add eax, 0x44
push 0x5bce10
push eax
call fcn.0057cac0
add esp, 0xc
jmp 0x4f27ac
fild dword [esp + 0x78]
sub esp, 8
fmul qword [0x5d1330]
fdiv qword [0x5d1338]
fadd qword [0x5d1220]
fstp qword [esp]
call fcn.0059a010
add esp, 8
call fcn.005999a0
push eax
mov ecx, edi
call fcn.004e3970
fild dword [esp + 0x7c]
sub esp, 8
fmul qword [0x5d1330]
fdiv qword [0x5d1338]
fadd qword [0x5d1220]
fstp qword [esp]
call fcn.0059a010
add esp, 8
call fcn.005999a0
push eax
mov ecx, edi
call fcn.004e39d0
cmp dword [edi + 0x148], 0
je 0x4f1f49
mov edi, 0x5bce10
mov esi, str.Cancelled
mov ecx, 0xa
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
mov byte [esp + 0x19], 1
je 0x4f27ac
push 0xff
mov eax, ebx
add eax, 0x44
push str.Cancelled
push eax
call fcn.0057cac0
add esp, 0xc
jmp 0x4f27ac
mov ecx, edi
call fcn.004e3e90
mov ebx, eax
test ebx, ebx
je 0x4f2025
cmp byte [esp + 0x17], 0
mov eax, dword [esp + 0x80]
je 0x4f1fe6
test eax, eax
jne 0x4f1f7d
mov ecx, dword [esp + 0x6e]
cmp cx, 8
ja 0x4f1f7d
mov eax, 1
shl eax, cl
mov edx, dword [ebp]
mov edx, dword [edx + 8]
push 1
lea eax, [eax + eax*2]
push eax
push ebx
mov ecx, ebp
call edx
mov eax, dword [edi + 0x28]
test eax, eax
jne 0x4f1fa6
movzx ecx, word [edi + 0x16]
cmp cx, 8
ja 0x4f1fa6
mov eax, 1
shl eax, cl
lea esi, [eax - 1]
test esi, esi
jl 0x4f2025
lea ecx, [ebx + esi*2]
lea eax, [ebx + esi*4 + 1]
lea ecx, [esi + ecx + 1]
jmp 0x4f1fc0
movzx edx, byte [ecx + 1]
mov byte [eax + 1], dl
movzx edx, byte [ecx - 1]
mov byte [eax - 1], dl
movzx edx, byte [ecx]
mov byte [eax], dl
mov byte [eax + 2], 0
sub esi, 1
sub ecx, 3
sub eax, 4
test esi, esi
jge 0x4f1fc0
jmp 0x4f2025
test eax, eax
jne 0x4f1ffb
mov ecx, dword [esp + 0x6e]
cmp cx, 8
ja 0x4f1ffb
mov eax, 1
shl eax, cl
mov edx, dword [ebp]
mov edx, dword [edx + 8]
add eax, eax
push 1
add eax, eax
push eax
push ebx
mov ecx, ebp
call edx
xor eax, eax
cmp dword [edi + 0x28], eax
jbe 0x4f2025
lea ecx, [ebx + 3]
mov byte [ecx], 0
add eax, 1
add ecx, 4
cmp eax, dword [edi + 0x28]
jb 0x4f2017
cmp dword [edi + 0x148], 0
je 0x4f206e
mov edi, 0x5bce10
mov esi, str.Cancelled
mov ecx, 0xa
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
mov byte [esp + 0x19], 1
je 0x4f27ac
mov ecx, dword [esp + 0x90]
push 0xff
add ecx, 0x44
push str.Cancelled
push ecx
call fcn.0057cac0
add esp, 0xc
jmp 0x4f27ac
mov eax, dword [esp + 0x5c]
add eax, 0xffffffff
cmp eax, 0x1f
ja case.0x4f2085.1
movzx edx, byte [eax + 0x4f2820]
jmp dword [edx*4 + 0x4f280c]
mov esi, dword [esp + 0x20]
cmp esi, 3
jne 0x4f20aa
mov eax, dword [ebp]
mov edx, dword [eax + 8]
push 1
push 0xc
lea ecx, [esp + 0x40]
push ecx
mov ecx, ebp
call edx
jmp 0x4f20c2
mov dword [esp + 0x38], 0xff0000
mov dword [esp + 0x3c], 0xff00
mov dword [esp + 0x40], 0xff
mov eax, dword [esp + 0x32]
test eax, eax
je 0x4f20dd
mov ecx, dword [esp + 0x1c]
mov edx, dword [ebp]
mov edx, dword [edx + 0x10]
add eax, ecx
push 0
push eax
mov ecx, ebp
call edx
cmp esi, 3
je 0x4f2126
test esi, esi
je 0x4f2126
mov edi, 0x5bce10
mov esi, str.unknown_compression
mov ecx, 0x14
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
mov byte [esp + 0x19], 1
je 0x4f27ac
mov ecx, dword [esp + 0x90]
push 0xff
add ecx, 0x44
push str.unknown_compression
push ecx
call fcn.0057cac0
add esp, 0xc
jmp 0x4f27ac
mov esi, dword [edi + 0xc]
imul esi, dword [edi + 0x10]
add esi, esi
add esi, esi
push esi
call fcn.005786ac
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x4f221f
mov edx, dword [ebp]
mov eax, dword [edx + 8]
push 1
push esi
push ebx
mov ecx, ebp
call eax
cmp dword [esp + 0x20], 0
jne 0x4f21f2
mov esi, edi
call fcn.004e7690
cmp dword [esi + 0x1bc], 0
je 0x4f21f2
xor esi, esi
mov ecx, edi
cmp dword [ecx + 0x10], esi
mov byte [esp + 0x17], 0
jle 0x4f21c1
mov ebp, ecx
mov eax, dword [ebp + 0xc]
mov edx, eax
imul edx, esi
lea edi, [ebx + edx*4 + 3]
xor edx, edx
test eax, eax
jle 0x4f21b2
movzx eax, byte [edi]
test al, al
je 0x4f219f
mov byte [esp + 0x17], 1
push eax
mov eax, ebp
call fcn.004e7770
add edx, 1
add edi, 4
cmp edx, dword [ebp + 0xc]
jl 0x4f2193
add esi, 1
cmp esi, dword [ebp + 0x10]
jl 0x4f2181
cmp byte [esp + 0x17], 0
jne 0x4f21f2
mov eax, dword [esp + 0x90]
mov eax, dword [eax + 0x1bc]
test eax, eax
je 0x4f21f2
mov edx, dword [esp + 0x90]
mov ecx, dword [edx + 0xc]
imul ecx, dword [edx + 0x10]
test ecx, ecx
jle 0x4f21f2
mov dl, byte [eax]
not dl
mov byte [eax], dl
add eax, 1
sub ecx, 1
jne 0x4f21e4
mov eax, dword [esp + 0x40]
mov ecx, dword [esp + 0x3c]
mov edx, dword [esp + 0x38]
push eax
mov eax, dword [esp + 0x94]
push ecx
push edx
push ebx
push eax
mov al, 0x20
call fcn.004e5080
push ebx
call fcn.0057876f
add esp, 4
jmp case.0x4f2085.1
mov edi, 0x5bce10
mov esi, str.cant_allocate_memory
mov ecx, 0x16
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
mov byte [esp + 0x19], 1
je 0x4f27ac
mov eax, dword [esp + 0x90]
push 0xff
add eax, 0x44
push str.cant_allocate_memory
push eax
call fcn.0057cac0
add esp, 0xc
jmp 0x4f27ac
mov eax, dword [esp + 0x32]
test eax, eax
je 0x4f227a
mov ecx, dword [esp + 0x1c]
mov edx, dword [ebp]
mov edx, dword [edx + 0x10]
add eax, ecx
push 0
push eax
mov ecx, ebp
call edx
cmp dword [esp + 0x20], 0
jne 0x4f229a
mov ecx, dword [edi + 0x1c]
mov eax, dword [ebp]
mov edx, dword [edi + 0x34]
mov eax, dword [eax + 8]
push 1
push ecx
push edx
mov ecx, ebp
call eax
jmp case.0x4f2085.1
mov edi, 0x5bce10
mov esi, str.unknown_compression
mov ecx, 0x14
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
mov byte [esp + 0x19], 1
je 0x4f27ac
mov eax, dword [esp + 0x90]
push 0xff
add eax, 0x44
push str.unknown_compression
push eax
call fcn.0057cac0
add esp, 0xc
jmp 0x4f27ac
cmp dword [esp + 0x20], 3
jne 0x4f22f6
mov edx, dword [ebp]
mov edx, dword [edx + 8]
push 1
push 0xc
lea eax, [esp + 0x4c]
push eax
mov ecx, ebp
call edx
jmp 0x4f230e
mov dword [esp + 0x44], 0x7c00
mov dword [esp + 0x48], 0x3e0
mov dword [esp + 0x4c], 0x1f
mov eax, dword [esp + 0x32]
test eax, eax
je 0x4f2329
mov ecx, dword [esp + 0x1c]
mov edx, dword [ebp]
mov edx, dword [edx + 0x10]
add eax, ecx
push 0
push eax
mov ecx, ebp
call edx
mov eax, dword [edi + 0xc]
mov esi, dword [ebp]
add eax, 1
cdq
sub eax, edx
mov edx, dword [esi + 8]
sar eax, 1
imul eax, dword [edi + 0x10]
add eax, eax
push 1
add eax, eax
push eax
mov eax, dword [edi + 0x34]
push eax
mov ecx, ebp
call edx
mov eax, dword [esp + 0x4c]
mov ecx, dword [esp + 0x48]
mov edx, dword [esp + 0x44]
push eax
mov eax, dword [edi + 0x34]
push ecx
push edx
push eax
push edi
mov al, 0x10
call fcn.004e5080
jmp case.0x4f2085.1
mov eax, dword [esp + 0x32]
test eax, eax
je 0x4f2388
mov ecx, dword [esp + 0x1c]
mov edx, dword [ebp]
mov edx, dword [edx + 0x10]
add eax, ecx
push 0
push eax
mov ecx, ebp
call edx
mov eax, dword [esp + 0x20]
sub eax, 0
je 0x4f2785
sub eax, 1
je 0x4f264a
sub eax, 1
je 0x4f23e3
mov edi, 0x5bce10
mov esi, str.compression_type_not_supported
mov ecx, 0x1f
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
mov byte [esp + 0x19], 1
je 0x4f27ac
mov ecx, dword [esp + 0x90]
push 0xff
add ecx, 0x44
push str.compression_type_not_supported
push ecx
call fcn.0057cac0
add esp, 0xc
jmp 0x4f27ac
mov ecx, dword [esp + 0x90]
xor edi, edi
xor ebx, ebx
lea eax, [esp + 0x44]
mov byte [esp + 0x17], 0
mov byte [esp + 0x18], 0
mov dword [esp + 0x20], edi
mov dword [esp + 0x1c], ebx
call fcn.004e5330
jmp 0x4f2414
mov ebx, dword [esp + 0x1c]
mov edx, dword [ebp]
mov edx, dword [edx + 8]
push 1
push 1
lea eax, [esp + 0x1f]
push eax
mov ecx, ebp
call edx
test eax, eax
je case.0x4f2085.1
cmp byte [esp + 0x17], 0
je 0x4f24d5
mov esi, dword [esp + 0x20]
lea edx, [esp + 0x44]
call fcn.004e53b0
push 1
mov esi, eax
mov eax, dword [ebp]
mov edx, dword [eax + 8]
push 1
lea ecx, [esp + 0x20]
push ecx
mov ecx, ebp
call edx
xor ecx, ecx
cmp byte [esp + 0x17], cl
jbe 0x4f2414
lea eax, [esi + ebx]
jmp 0x4f2470
mov edx, dword [esp + 0x90]
mov esi, dword [edx + 0x1c]
add esi, dword [edx + 0x34]
cmp eax, esi
jae 0x4f24b7
test edi, edi
mov dl, byte [esp + 0x18]
je 0x4f24a8
test cl, 1
je 0x4f249b
and dl, 0xf
or byte [eax], dl
add ebx, 1
add eax, 1
jmp 0x4f24b7
shr dl, 4
or byte [eax], dl
add ebx, 1
add eax, 1
jmp 0x4f24b7
test cl, 1
je 0x4f24b2
shl dl, 4
jmp 0x4f24b5
and dl, 0xf0
mov byte [eax], dl
xor edx, edx
test edi, edi
sete dl
add ecx, 1
mov edi, edx
movzx edx, byte [esp + 0x17]
cmp ecx, edx
jb 0x4f2470
mov dword [esp + 0x1c], ebx
jmp 0x4f2414
mov eax, dword [ebp]
mov edx, dword [eax + 8]
push 1
push 1
lea ecx, [esp + 0x1f]
push ecx
mov ecx, ebp
call edx
movzx eax, byte [esp + 0x17]
sub eax, 0
je 0x4f2638
sub eax, 1
je case.0x4f2085.1
sub eax, 1
mov eax, dword [ebp]
mov edx, dword [eax + 8]
push 1
push 1
je 0x4f2601
lea ecx, [esp + 0x20]
push ecx
mov ecx, ebp
call edx
mov esi, dword [esp + 0x20]
lea edx, [esp + 0x44]
call fcn.004e53b0
mov cl, byte [esp + 0x17]
xor ebx, ebx
test cl, cl
jbe 0x4f25dd
mov ecx, dword [esp + 0x1c]
lea esi, [eax + ecx]
mov eax, dword [esp + 0x90]
mov edx, dword [eax + 0x1c]
add edx, dword [eax + 0x34]
cmp esi, edx
jae 0x4f2596
test edi, edi
je 0x4f257d
test bl, 1
je 0x4f256a
mov cl, byte [esp + 0x18]
add dword [esp + 0x1c], 1
and cl, 0xf
or byte [esi], cl
add esi, 1
jmp 0x4f2596
mov dl, byte [esp + 0x18]
add dword [esp + 0x1c], 1
shr dl, 4
or byte [esi], dl
add esi, 1
jmp 0x4f2596
test bl, 1
je 0x4f258d
mov cl, byte [esp + 0x18]
shl cl, 4
mov byte [esi], cl
jmp 0x4f2596
mov dl, byte [esp + 0x18]
and dl, 0xf0
mov byte [esi], dl
test bl, 1
je 0x4f25c1
movzx ecx, byte [esp + 0x17]
sub ecx, 1
cmp ebx, ecx
je 0x4f25c1
mov edx, dword [ebp]
mov edx, dword [edx + 8]
push 1
push 1
lea eax, [esp + 0x20]
push eax
mov ecx, ebp
call edx
mov eax, dword [esp + 0x90]
xor ecx, ecx
test edi, edi
sete cl
add ebx, 1
mov edi, ecx
movzx ecx, byte [esp + 0x17]
movzx edx, cl
cmp ebx, edx
jl 0x4f2544
add ecx, 1
test cl, 2
je 0x4f2410
mov eax, dword [ebp]
mov edx, dword [eax + 8]
push 1
push 1
lea ecx, [esp + 0x20]
push ecx
mov ecx, ebp
call edx
jmp 0x4f2410
lea ecx, [esp + 0x23]
push ecx
mov ecx, ebp
call edx
mov eax, dword [ebp]
mov edx, dword [eax + 8]
push 1
push 1
lea ecx, [esp + 0x22]
push ecx
mov ecx, ebp
call edx
movzx eax, byte [esp + 0x1b]
movzx ecx, byte [esp + 0x1a]
shr eax, 1
add ebx, eax
add dword [esp + 0x20], ecx
mov dword [esp + 0x1c], ebx
jmp 0x4f2414
add dword [esp + 0x20], 1
xor ebx, ebx
mov dword [esp + 0x1c], ebx
xor edi, edi
jmp 0x4f2414
mov ecx, dword [esp + 0x90]
lea eax, [esp + 0x44]
mov byte [esp + 0x17], 0
mov byte [esp + 0x18], 0
xor esi, esi
xor edi, edi
call fcn.004e5330
mov edx, dword [ebp]
mov edx, dword [edx + 8]
push 1
push 1
lea eax, [esp + 0x1f]
push eax
mov ecx, ebp
call edx
test eax, eax
je case.0x4f2085.1
cmp byte [esp + 0x17], 0
je 0x4f26d4
lea edx, [esp + 0x44]
call fcn.004e53b0
push 1
mov ebx, eax
mov eax, dword [ebp]
mov edx, dword [eax + 8]
push 1
lea ecx, [esp + 0x20]
push ecx
mov ecx, ebp
call edx
xor eax, eax
cmp byte [esp + 0x17], al
jbe 0x4f2668
mov ecx, dword [esp + 0x90]
cmp edi, dword [ecx + 0x30]
jae 0x4f2668
mov dl, byte [esp + 0x18]
mov byte [ebx + edi], dl
movzx edx, byte [esp + 0x17]
add eax, 1
add edi, 1
cmp eax, edx
jb 0x4f26b7
jmp 0x4f2668
mov eax, dword [ebp]
mov edx, dword [eax + 8]
push 1
push 1
lea ecx, [esp + 0x1f]
push ecx
mov ecx, ebp
call edx
movzx ecx, byte [esp + 0x17]
mov eax, ecx
sub eax, 0
je 0x4f277b
sub eax, 1
je case.0x4f2085.1
sub eax, 1
push 1
je 0x4f2744
mov ebx, dword [ebp]
push ecx
lea edx, [esp + 0x4c]
call fcn.004e53b0
add eax, edi
push eax
mov eax, dword [ebx + 8]
mov ecx, ebp
call eax
test byte [esp + 0x17], 1
je 0x4f2738
mov edx, dword [ebp]
mov edx, dword [edx + 8]
push 1
push 1
lea eax, [esp + 0x20]
push eax
mov ecx, ebp
call edx
movzx eax, byte [esp + 0x17]
add edi, eax
jmp 0x4f2668
mov edx, dword [ebp]
mov edx, dword [edx + 8]
push 1
lea eax, [esp + 0x22]
push eax
mov ecx, ebp
call edx
mov eax, dword [ebp]
mov edx, dword [eax + 8]
push 1
push 1
lea ecx, [esp + 0x23]
push ecx
mov ecx, ebp
call edx
movzx eax, byte [esp + 0x1a]
movzx ecx, byte [esp + 0x1b]
add edi, eax
add esi, ecx
jmp 0x4f2668
xor edi, edi
add esi, 1
jmp 0x4f2668
mov eax, dword [edi + 0x1c]
mov ecx, dword [edi + 0x34]
mov edx, dword [ebp]
mov edx, dword [edx + 8]
push 1
push eax
push ecx
mov ecx, ebp
call edx
cmp byte [esp + 0x27], 0
je 0x4f27ac
mov eax, dword [esp + 0x90]
call fcn.004e6640
cmp byte [esp + 0x19], 0
mov byte [esp + 0x26], 0
je 0x4f2800
mov edi, 0x5bce10
lea esi, [esp + 0x26]
mov ecx, 1
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
mov esi, dword [esp + 0x90]
je 0x4f27e9
push 0xff
lea ecx, [esp + 0x2a]
push ecx
lea edx, [esi + 0x44]
push edx
call fcn.0057cac0
add esp, 0xc
cmp dword [esi + 0x148], 0xffffffff
jne 0x4f1c74
cmp dword [esi + 0x40], 1
jne 0x4f1c74
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
add esp, 0x7c
ret 8