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

Disassembly:
sub esp, 0x60
mov eax, dword [0x58005c]
xor eax, esp
mov dword [esp + 0x5c], eax
push ebx
push ebp
push esi
mov esi, edx
mov eax, dword [esi + 0x68]
push edi
mov edi, dword [esp + 0x74]
mov ebx, ecx
mov dword [esp + 0x44], edi
test al, 1
jne 0x40eb55
push esi
mov ecx, str.Missing_IHDR_before_cHRM
call fcn.0040d330
add esp, 4
jmp 0x40eb8f
test al, 4
je 0x40eb81
mov edx, str.Invalid_cHRM_after_IDAT
call fcn.0040d3f0
push ebx
mov ecx, esi
call fcn.0040dde0
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x5c]
xor ecx, esp
call fcn.004130a1
add esp, 0x60
ret
test al, 2
je 0x40eb8f
mov edx, str.Missing_PLTE_before_cHRM
call fcn.0040d3f0
test edi, edi
je 0x40eba8
mov eax, dword [edi + 8]
test al, 4
je 0x40eba8
test eax, 0x800
jne 0x40eba8
mov edx, str.Duplicate_cHRM_chunk
jmp 0x40eb5e
cmp ebx, 0x20
je 0x40ebb4
mov edx, str.Incorrect_cHRM_chunk_length
jmp 0x40eb5e
mov edi, 0x20
lea ebx, [esp + 0x4c]
call fcn.0040dd80
push 0
mov ecx, esi
call fcn.0040dde0
add esp, 4
test eax, eax
jne 0x40eefa
movzx eax, byte [esp + 0x4c]
movzx ecx, byte [esp + 0x4d]
movzx edx, byte [esp + 0x4e]
shl eax, 8
add eax, ecx
movzx ecx, byte [esp + 0x4f]
shl eax, 8
add eax, edx
movzx edx, byte [esp + 0x51]
shl eax, 8
add eax, ecx
movzx ecx, byte [esp + 0x50]
shl ecx, 8
add ecx, edx
movzx edx, byte [esp + 0x52]
shl ecx, 8
add ecx, edx
movzx edx, byte [esp + 0x53]
shl ecx, 8
add ecx, edx
cmp eax, 0x13880
ja 0x40eef0
cmp ecx, 0x13880
ja 0x40eef0
lea edx, [ecx + eax]
cmp edx, 0x186a0
ja 0x40eef0
mov dword [esp + 0x18], ecx
lea ecx, [esp + 0x54]
mov dword [esp + 0x1c], eax
call fcn.0040dc80
lea ecx, [esp + 0x58]
mov edi, eax
call fcn.0040dc80
lea ecx, [eax + edi]
cmp ecx, 0x186a0
jbe 0x40ec73
mov edx, str.Invalid_cHRM_red_point
jmp 0x40eef5
lea ecx, [esp + 0x5c]
mov dword [esp + 0x28], edi
mov dword [esp + 0x20], eax
call fcn.0040dc80
lea ecx, [esp + 0x60]
mov edi, eax
call fcn.0040dc80
lea edx, [eax + edi]
cmp edx, 0x186a0
jbe 0x40eca4
mov edx, str.Invalid_cHRM_green_point
jmp 0x40eef5
lea ecx, [esp + 0x64]
mov dword [esp + 0x3c], edi
mov dword [esp + 0x24], eax
call fcn.0040dc80
mov ebx, eax
lea ecx, [esp + 0x68]
mov dword [esp + 0x10], ebx
call fcn.0040dc80
mov ebp, eax
lea eax, [ebx + ebp]
mov dword [esp + 0x14], ebp
cmp eax, 0x186a0
jbe 0x40ecde
mov edx, str.Invalid_cHRM_blue_point
jmp 0x40eef5
fild dword [esp + 0x1c]
mov eax, dword [esp + 0x44]
fld qword [0x575bf8]
fdiv st(1), st(0)
fxch st(1)
fstp dword [esp + 0x34]
fild dword [esp + 0x18]
fdiv st(1)
fstp dword [esp + 0x30]
fild dword [esp + 0x28]
fdiv st(1)
fstp dword [esp + 0x48]
fild dword [esp + 0x20]
fdiv st(1)
fstp dword [esp + 0x38]
fild dword [esp + 0x3c]
fdiv st(1)
fstp dword [esp + 0x40]
fild dword [esp + 0x24]
fdiv st(1)
fstp dword [esp + 0x2c]
fild dword [esp + 0x10]
fdiv st(1)
fstp dword [esp + 0x10]
fidivr dword [esp + 0x14]
fstp dword [esp + 0x14]
test eax, eax
je 0x40ee61
test dword [eax + 8], 0x800
je 0x40ee61
mov ecx, dword [esp + 0x1c]
add ecx, 0xffff89c2
cmp ecx, 0x7d0
ja 0x40edd7
mov edx, dword [esp + 0x18]
add edx, 0xffff8364
cmp edx, 0x7d0
ja 0x40edd7
mov eax, dword [esp + 0x28]
add eax, 0xffff09e8
cmp eax, 0x7d0
ja 0x40edd7
mov ecx, dword [esp + 0x20]
add ecx, 0xffff8300
cmp ecx, 0x7d0
ja 0x40edd7
add edi, 0xffff8eb8
cmp edi, 0x7d0
ja 0x40edd7
mov edx, dword [esp + 0x24]
add edx, 0xffff1988
cmp edx, 0x7d0
ja 0x40edd7
cmp ebx, 0x36b0
jl 0x40edd7
cmp ebx, 0x3e80
jg 0x40edd7
cmp ebp, 0x1388
jl 0x40edd7
cmp ebp, 0x1b58
jle 0x40eefa
mov edx, str.Ignoring_incorrect_cHRM_value_when_sRGB_is_also_present
call fcn.0040d3f0
fld dword [esp + 0x38]
sub esp, 0x20
fstp qword [esp + 0x18]
fld dword [esp + 0x68]
fstp qword [esp + 0x10]
fld dword [esp + 0x50]
fstp qword [esp + 8]
fld dword [esp + 0x54]
fstp qword [esp]
push str.wx_f__wy_f__rx_f__ry_f_n
call fcn.0041369c
add eax, 0x40
push eax
call fcn.0047ff45
fld dword [esp + 0x3c]
fstp qword [esp + 0x20]
add esp, 8
fld dword [esp + 0x30]
fstp qword [esp + 0x10]
fld dword [esp + 0x4c]
fstp qword [esp + 8]
fld dword [esp + 0x60]
fstp qword [esp]
push str.gx_f__gy_f__bx_f__by_f_n
call fcn.0041369c
add eax, 0x40
push eax
call fcn.0047ff45
add esp, 0x28
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x5c]
xor ecx, esp
call fcn.004130a1
add esp, 0x60
ret
fld dword [esp + 0x14]
sub esp, 0x40
fstp qword [esp + 0x38]
mov edi, eax
fld dword [esp + 0x50]
mov eax, esi
fstp qword [esp + 0x30]
fld dword [esp + 0x6c]
fstp qword [esp + 0x28]
fld dword [esp + 0x80]
fstp qword [esp + 0x20]
fld dword [esp + 0x78]
fstp qword [esp + 0x18]
fld dword [esp + 0x88]
fstp qword [esp + 0x10]
fld dword [esp + 0x70]
fstp qword [esp + 8]
fld dword [esp + 0x74]
fstp qword [esp]
call fcn.00411df0
mov eax, dword [esp + 0x64]
mov ecx, dword [esp + 0x7c]
mov edx, dword [esp + 0x60]
push ebp
push ebx
push eax
mov eax, dword [esp + 0x74]
push ecx
mov ecx, dword [esp + 0x68]
push edx
mov edx, dword [esp + 0x70]
push eax
push ecx
push edx
push esi
mov eax, edi
call fcn.00412100
add esp, 0x64
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x5c]
xor ecx, esp
call fcn.004130a1
add esp, 0x60
ret
mov edx, str.Invalid_cHRM_white_point
call fcn.0040d3f0
mov ecx, dword [esp + 0x6c]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.004130a1
add esp, 0x60
ret