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

Disassembly:
sub esp, 0x16c
push ebx
mov ebx, dword [esp + 0x174]
push ebp
push esi
push edi
mov eax, dword [ebx + 0x6c]
test al, 1
je 0x46d4d0
test al, 4
je 0x46cf06
push str.Invalid_cHRM_after_IDAT
push ebx
call fcn.00466a60
push dword [esp + 0x190]
push ebx
call fcn.0046c210
add esp, 0x10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x16c
ret
test al, 2
je 0x46cf18
push str.Out_of_place_cHRM_chunk
push ebx
call fcn.00466a60
add esp, 8
mov eax, dword [esp + 0x184]
test eax, eax
je 0x46cf38
mov eax, dword [eax + 8]
test al, 4
je 0x46cf38
test eax, 0x800
jne 0x46cf38
push str.Duplicate_cHRM_chunk
jmp 0x46cee5
mov esi, dword [esp + 0x188]
cmp esi, 0x20
je 0x46cf64
push str.Incorrect_cHRM_chunk_length
push ebx
call fcn.00466a60
push esi
push ebx
call fcn.0046c210
add esp, 0x10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x16c
ret
push 0x20
lea eax, [esp + 0x28]
push eax
push ebx
call fcn.00466ba0
push 0x20
lea eax, [esp + 0x34]
push eax
push ebx
call fcn.00463ea0
push 0
push ebx
call fcn.0046c210
add esp, 0x20
test eax, eax
jne 0x46d4c5
movzx ebp, byte [esp + 0x24]
movzx eax, byte [esp + 0x25]
shl ebp, 8
add ebp, eax
movzx eax, byte [esp + 0x26]
shl ebp, 8
add ebp, eax
movzx eax, byte [esp + 0x27]
shl ebp, 8
add ebp, eax
cmp ebp, 0x7fffffff
jbe 0x46cfbf
or ebp, 0xffffffff
movzx esi, byte [esp + 0x28]
movzx eax, byte [esp + 0x29]
shl esi, 8
add esi, eax
movzx eax, byte [esp + 0x2a]
shl esi, 8
add esi, eax
movzx eax, byte [esp + 0x2b]
shl esi, 8
add esi, eax
mov dword [esp + 0x50], esi
cmp esi, 0x7fffffff
jbe 0x46cff5
or esi, 0xffffffff
mov dword [esp + 0x50], esi
movzx edi, byte [esp + 0x2c]
movzx eax, byte [esp + 0x2d]
shl edi, 8
add edi, eax
movzx eax, byte [esp + 0x2e]
shl edi, 8
add edi, eax
movzx eax, byte [esp + 0x2f]
shl edi, 8
add edi, eax
mov dword [esp + 0x48], edi
cmp edi, 0x7fffffff
jbe 0x46d02b
or edi, 0xffffffff
mov dword [esp + 0x48], edi
movzx ecx, byte [esp + 0x30]
movzx eax, byte [esp + 0x31]
shl ecx, 8
add ecx, eax
movzx eax, byte [esp + 0x32]
shl ecx, 8
add ecx, eax
movzx eax, byte [esp + 0x33]
shl ecx, 8
add ecx, eax
mov dword [esp + 0x1c], ecx
cmp ecx, 0x7fffffff
jbe 0x46d061
or ecx, 0xffffffff
mov dword [esp + 0x1c], ecx
movzx edx, byte [esp + 0x34]
movzx eax, byte [esp + 0x35]
shl edx, 8
add edx, eax
movzx eax, byte [esp + 0x36]
shl edx, 8
add edx, eax
movzx eax, byte [esp + 0x37]
shl edx, 8
add edx, eax
mov dword [esp + 0x20], edx
cmp edx, 0x7fffffff
jbe 0x46d097
or edx, 0xffffffff
mov dword [esp + 0x20], edx
movzx eax, byte [esp + 0x38]
shl eax, 8
mov dword [esp + 0x14], eax
movzx eax, byte [esp + 0x39]
add dword [esp + 0x14], eax
shl dword [esp + 0x14], 8
movzx eax, byte [esp + 0x3a]
add dword [esp + 0x14], eax
shl dword [esp + 0x14], 8
movzx eax, byte [esp + 0x3b]
add dword [esp + 0x14], eax
cmp dword [esp + 0x14], 0x7fffffff
jbe 0x46d0da
mov dword [esp + 0x14], 0xffffffff
movzx eax, byte [esp + 0x3c]
shl eax, 8
mov dword [esp + 0x10], eax
movzx eax, byte [esp + 0x3d]
add dword [esp + 0x10], eax
shl dword [esp + 0x10], 8
movzx eax, byte [esp + 0x3e]
add dword [esp + 0x10], eax
shl dword [esp + 0x10], 8
movzx eax, byte [esp + 0x3f]
add dword [esp + 0x10], eax
cmp dword [esp + 0x10], 0x7fffffff
jbe 0x46d11d
mov dword [esp + 0x10], 0xffffffff
movzx eax, byte [esp + 0x40]
shl eax, 8
mov dword [esp + 0x18], eax
movzx eax, byte [esp + 0x41]
add dword [esp + 0x18], eax
shl dword [esp + 0x18], 8
movzx eax, byte [esp + 0x42]
add dword [esp + 0x18], eax
shl dword [esp + 0x18], 8
movzx eax, byte [esp + 0x43]
add dword [esp + 0x18], eax
cmp dword [esp + 0x18], 0x7fffffff
jbe 0x46d160
mov dword [esp + 0x18], 0xffffffff
cmp ebp, 0xffffffff
je 0x46d4b7
cmp esi, 0xffffffff
je 0x46d4b7
cmp edi, 0xffffffff
je 0x46d4b7
cmp ecx, 0xffffffff
je 0x46d4b7
cmp edx, 0xffffffff
je 0x46d4b7
mov eax, dword [esp + 0x14]
cmp eax, 0xffffffff
je 0x46d4b7
cmp dword [esp + 0x10], 0xffffffff
je 0x46d4b7
cmp dword [esp + 0x18], 0xffffffff
je 0x46d4b7
cmp dword [esp + 0x184], 0
je 0x46d310
mov ebx, dword [esp + 0x184]
test dword [ebx + 8], 0x800
mov ebx, dword [esp + 0x180]
je 0x46d310
lea eax, [ebp - 0x763e]
cmp eax, 0x7d0
ja 0x46d250
lea eax, [esi - 0x7c9c]
cmp eax, 0x7d0
ja 0x46d250
lea eax, [edi - 0xf618]
cmp eax, 0x7d0
ja 0x46d250
lea eax, [ecx - 0x7d00]
cmp eax, 0x7d0
ja 0x46d250
lea eax, [edx - 0x7148]
cmp eax, 0x7d0
ja 0x46d250
mov eax, dword [esp + 0x14]
add eax, 0xffff1988
cmp eax, 0x7d0
ja 0x46d250
mov eax, dword [esp + 0x10]
add eax, 0xffffc950
cmp eax, 0x7d0
ja 0x46d250
mov eax, dword [esp + 0x18]
cmp eax, 0x1388
jl 0x46d250
cmp eax, 0x1b58
jle 0x46d4c5
push ebp
push 5
lea eax, [esp + 0x84]
push 1
push eax
call fcn.00466ab0
push esi
push 5
lea eax, [esp + 0x94]
push 2
push eax
call fcn.00466ab0
push edi
push 5
lea eax, [esp + 0xa4]
push 3
push eax
call fcn.00466ab0
push dword [esp + 0x4c]
lea eax, [esp + 0xb0]
push 5
push 4
push eax
call fcn.00466ab0
add esp, 0x40
lea eax, [esp + 0x7c]
push dword [esp + 0x20]
push 5
push 5
push eax
call fcn.00466ab0
push dword [esp + 0x24]
lea eax, [esp + 0x90]
push 5
push 6
push eax
call fcn.00466ab0
push dword [esp + 0x30]
lea eax, [esp + 0xa0]
push 5
push 7
push eax
call fcn.00466ab0
push dword [esp + 0x48]
lea eax, [esp + 0xb0]
push 5
push 8
push eax
call fcn.00466ab0
add esp, 0x40
lea eax, [esp + 0x7c]
push str.Ignoring_incorrect_cHRM_white__1__2__r__3__4_g__5__6_b__7__8__when_sRGB_is_also_present
push eax
push ebx
call fcn.004668b0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x16c
ret
cmp byte [ebx + 0x252], 0
jne 0x46d48e
mov dword [esp + 0x64], eax
sub esp, 0x20
mov eax, dword [esp + 0x30]
mov dword [esp + 0x88], eax
mov eax, dword [esp + 0x38]
mov dword [esp + 0x8c], eax
lea eax, [esp + 0x78]
mov dword [esp + 0x78], edi
mov edi, esp
mov dword [esp + 0x7c], ecx
mov ecx, 8
mov dword [esp + 0x94], esi
lea esi, [esp + 0x78]
push eax
mov dword [esp + 0x84], edx
mov dword [esp + 0x94], ebp
rep movsd dword es:[edi], dword [esi]
push ebx
call fcn.004632d0
add esp, 0x28
test eax, eax
je 0x46d47a
push 0x186a0
push 0x8000
push dword [esp + 0x64]
lea eax, [esp + 0x50]
push eax
call fcn.00464d50
add esp, 0x10
test eax, eax
je 0x46d4d0
cmp dword [esp + 0x44], 0x8000
ja 0x46d4d0
push 0x186a0
push 0x8000
push dword [esp + 0x70]
lea eax, [esp + 0x58]
push eax
call fcn.00464d50
add esp, 0x10
test eax, eax
je 0x46d4d0
cmp dword [esp + 0x4c], 0x8000
ja 0x46d4d0
push 0x186a0
push 0x8000
push dword [esp + 0x7c]
lea eax, [esp + 0x60]
push eax
call fcn.00464d50
add esp, 0x10
test eax, eax
je 0x46d4d0
mov esi, dword [esp + 0x54]
cmp esi, 0x8000
ja 0x46d4d0
mov ecx, dword [esp + 0x4c]
mov edx, dword [esp + 0x44]
lea eax, [esi + ecx]
add eax, edx
cmp eax, 0x8001
jg 0x46d4d0
cmp eax, 0x8000
jle 0x46d433
or eax, 0xffffffff
jmp 0x46d43a
jge 0x46d460
mov eax, 1
cmp edx, ecx
jg 0x46d44e
cmp ecx, esi
jl 0x46d44a
add ecx, eax
mov dword [esp + 0x4c], ecx
jmp 0x46d460
cmp edx, ecx
jl 0x46d45a
cmp edx, esi
jl 0x46d45a
add edx, eax
mov dword [esp + 0x44], edx
jmp 0x46d460
add esi, eax
mov dword [esp + 0x54], esi
lea eax, [esi + ecx]
add eax, edx
cmp eax, 0x8000
jne 0x46d4d6
mov word [ebx + 0x254], dx
mov word [ebx + 0x256], cx
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0x20]
mov ecx, dword [esp + 0x1c]
mov edi, dword [esp + 0x48]
mov esi, dword [esp + 0x50]
push dword [esp + 0x18]
push dword [esp + 0x14]
push eax
push edx
push ecx
push edi
push esi
push ebp
push dword [esp + 0x1a4]
push ebx
call fcn.0046ffb0
add esp, 0x28
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x16c
ret
push str.Ignoring_cHRM_chunk_with_negative_chromaticities
push ebx
call fcn.00466a60
add esp, 8
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x16c
ret
push ebx
call fcn.00466650
push ebx
call fcn.00466650
int3