Function at 0x5951a0
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x78
mov eax, dword [0x6d7160]
xor eax, esp
mov dword [esp + 0x74], eax
push ebx
mov ebx, ecx
mov eax, dword [ebx]
xor ecx, ecx
mov dword [esp + 0xc], ecx
cmp dword [eax + 0x14], ecx
push esi
mov dword [esp + 0x14], ecx
je 0x5951e1
cmp dword [eax + 0x18], 0xffffffff
je 0x5951f6
mov ecx, dword [esp + 0x84]
mov edx, dword [eax + 0x1c]
cmp edx, ecx
mov dword [eax + 0x18], ecx
ja 0x5951dc
mov ecx, edx
mov dword [eax + 0x18], ecx
jmp 0x5951f6
mov edx, dword [eax + 4]
push ecx
mov ecx, dword [esp + 0x88]
push ecx
push edx
call fcn.006081d8
add esp, 0xc
mov esi, ebx
call fcn.0057e000
cmp eax, 0x504b5453
jne 0x5956e2
push ebp
push edi
lea ebx, [ebx]
mov esi, ebx
call fcn.0057e000
mov esi, dword [ebx]
mov edx, dword [esi + 0x14]
test edx, edx
je 0x595255
mov eax, dword [esi + 0x1c]
mov edi, 0x28
cmp eax, edi
jb 0x595236
mov ecx, dword [esi + 0x18]
lea ebp, [ecx + 0x28]
cmp ebp, eax
jbe 0x59523f
mov ecx, dword [esi + 0x18]
sub eax, ecx
mov edi, eax
je 0x59526e
push edi
add ecx, edx
push ecx
lea eax, [esp + 0x64]
push eax
call fcn.0060d1b0
add esp, 0xc
add dword [esi + 0x18], edi
jmp 0x59526e
mov esi, dword [esi + 4]
test esi, esi
je 0x59526e
push esi
push 0x28
lea ecx, [esp + 0x64]
push 1
push ecx
call fcn.0060860a
add esp, 0x10
mov esi, ebx
call fcn.0057e000
mov ebp, eax
mov eax, dword [ebx]
cmp dword [eax + 0x14], 0
mov dword [esp + 0x24], ebp
je 0x595288
mov eax, dword [eax + 0x18]
jmp 0x595294
mov edx, dword [eax + 4]
push edx
call fcn.00609413
add esp, 4
mov edi, 0x6b6094
lea esi, [esp + 0x5c]
mov ecx, 0x12
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
mov dword [esp + 0x20], eax
jne 0x5952b8
mov dword [ebx + 0x34c], eax
mov dword [ebx + 0x358], ebp
mov edi, str.icc_camera_profile
lea esi, [esp + 0x5c]
mov ecx, 0x13
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
jne 0x5952d8
mov dword [ebx + 0x354], eax
mov dword [ebx + 0x360], ebp
mov edi, str.ShootObj_back_type
lea esi, [esp + 0x5c]
mov ecx, 0x13
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x595358
mov eax, dword [ebx]
mov ecx, dword [eax + 0x14]
test ecx, ecx
je 0x595307
lea edx, [esp + 0x10]
push edx
push 0x6a66e4
push ecx
call fcn.006094e9
jmp 0x59532f
neg ecx
sbb ecx, ecx
not ecx
test eax, ecx
je 0x595332
mov ecx, dword [eax + 0x14]
neg ecx
sbb ecx, ecx
lea edx, [esp + 0x10]
push edx
not ecx
and ecx, eax
mov edx, dword [ecx + 4]
push 0x6a66e4
push edx
call fcn.0061c8da
add esp, 0xc
mov ebp, dword [esp + 0x10]
cmp ebp, 0x15
jae 0x59535c
mov ecx, dword [ebp*4 + 0x6eb0b0]
lea edx, [ebx + 0x255]
mov al, byte [ecx]
mov byte [edx], al
add ecx, 1
add edx, 1
test al, al
jne 0x595348
jmp 0x59535c
mov ebp, dword [esp + 0x10]
mov edi, str.icc_camera_to_tone_matrix
lea esi, [esp + 0x5c]
mov ecx, 0x1a
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x5953b1
mov dword [esp + 0x10], eax
xor edi, edi
mov esi, ebx
call fcn.0057e000
mov ebp, dword [esp + 0x10]
lea ecx, [edi + ebp*2]
mov dword [esp + 0x14], eax
fld dword [esp + 0x14]
add ecx, ebp
add edi, 1
fstp dword [esp + ecx*4 + 0x38]
cmp edi, 3
jl 0x595376
add ebp, 1
cmp ebp, 3
mov dword [esp + 0x10], ebp
jl 0x595374
lea eax, [esp + 0x38]
mov ecx, ebx
call fcn.00595110
mov edi, str.CaptProf_color_matrix
lea esi, [esp + 0x5c]
mov ecx, 0x16
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
jne 0x595445
xor ebp, ebp
mov dword [esp + 0x10], ebp
nop
xor esi, esi
mov eax, dword [ebx]
mov ecx, dword [eax + 0x14]
test ecx, ecx
je 0x5953f2
lea eax, [esi + ebp*2]
add eax, ebp
lea edx, [esp + eax*4 + 0x38]
push edx
push 0x6aa608
push ecx
call fcn.006094e9
jmp 0x59541f
neg ecx
sbb ecx, ecx
not ecx
test eax, ecx
je 0x595426
lea edx, [esi + ebp*2]
add edx, ebp
lea ecx, [esp + edx*4 + 0x38]
mov edx, dword [eax + 0x14]
neg edx
sbb edx, edx
not edx
push ecx
and edx, eax
mov eax, dword [edx + 4]
push 0x6aa608
push eax
call fcn.0061c8da
mov ebp, dword [esp + 0x1c]
add esp, 0xc
add esi, 1
cmp esi, 3
jl 0x5953d2
add ebp, 1
cmp ebp, 3
mov dword [esp + 0x10], ebp
jl 0x5953d0
lea eax, [esp + 0x38]
mov ecx, ebx
call fcn.00595110
mov edi, str.CaptProf_number_of_planes
lea esi, [esp + 0x5c]
mov ecx, 0x1a
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
jne 0x5954a3
mov eax, dword [ebx]
mov ecx, dword [eax + 0x14]
test ecx, ecx
je 0x595474
lea eax, [esp + 0x18]
push eax
push 0x6a66e4
push ecx
call fcn.006094e9
jmp 0x59549c
neg ecx
sbb ecx, ecx
not ecx
test eax, ecx
je 0x5954a3
mov ecx, dword [eax + 0x14]
neg ecx
sbb ecx, ecx
lea edx, [esp + 0x18]
push edx
not ecx
and ecx, eax
mov edx, dword [ecx + 4]
push 0x6a66e4
push edx
call fcn.0061c8da
mov ebp, dword [esp + 0x1c]
add esp, 0xc
mov edi, str.CaptProf_raw_data_rotation
lea esi, [esp + 0x5c]
mov ecx, 0x1b
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x595505
mov eax, dword [ebx]
mov ecx, dword [eax + 0x14]
test ecx, ecx
je 0x5954d4
lea edx, [ebx + 0x474]
push edx
push 0x6a66e4
push ecx
call fcn.006094e9
jmp 0x5954fe
neg ecx
sbb ecx, ecx
not ecx
test eax, ecx
je 0x595505
mov ecx, dword [eax + 0x14]
neg ecx
sbb ecx, ecx
lea edx, [ebx + 0x474]
push edx
not ecx
and ecx, eax
mov edx, dword [ecx + 4]
push 0x6a66e4
push edx
call fcn.0061c8da
mov ebp, dword [esp + 0x1c]
add esp, 0xc
mov edi, str.CaptProf_mosaic_pattern
lea esi, [esp + 0x5c]
mov ecx, 0x18
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x595581
xor esi, esi
jmp 0x595520
mov eax, dword [ebx]
mov ecx, dword [eax + 0x14]
test ecx, ecx
je 0x59553b
lea edx, [esp + 0x10]
push edx
push 0x6a66e4
push ecx
call fcn.006094e9
jmp 0x595563
neg ecx
sbb ecx, ecx
not ecx
test eax, ecx
je 0x59556a
mov ecx, dword [eax + 0x14]
neg ecx
sbb ecx, ecx
lea edx, [esp + 0x10]
push edx
not ecx
and ecx, eax
mov edx, dword [ecx + 4]
push 0x6a66e4
push edx
call fcn.0061c8da
mov ebp, dword [esp + 0x1c]
add esp, 0xc
cmp ebp, 1
jne 0x595579
mov eax, esi
sar eax, 1
xor eax, esi
mov dword [esp + 0x1c], eax
add esi, 1
cmp esi, 4
jl 0x595520
mov edi, str.ImgProf_rotation_angle
lea esi, [esp + 0x5c]
mov ecx, 0x17
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x5955eb
mov eax, dword [ebx]
mov ecx, dword [eax + 0x14]
test ecx, ecx
je 0x5955b0
lea edx, [esp + 0x10]
push edx
push 0x6a66e4
push ecx
call fcn.006094e9
jmp 0x5955d8
neg ecx
sbb ecx, ecx
not ecx
test eax, ecx
je 0x5955df
mov ecx, dword [eax + 0x14]
neg ecx
sbb ecx, ecx
lea edx, [esp + 0x10]
push edx
not ecx
and ecx, eax
mov edx, dword [ecx + 4]
push 0x6a66e4
push edx
call fcn.0061c8da
mov ebp, dword [esp + 0x1c]
add esp, 0xc
sub ebp, dword [ebx + 0x474]
mov dword [ebx + 0x474], ebp
mov edi, str.NeutObj_neutrals
lea esi, [esp + 0x5c]
mov ecx, 0x11
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x59568e
fldz
lea ebp, [ebx + 0x205c8]
fcomp dword [ebp]
fnstsw ax
test ah, 0x44
jp 0x59568e
lea esi, [esp + 0x28]
mov edi, 4
mov eax, dword [ebx]
mov ecx, dword [eax + 0x14]
test ecx, ecx
je 0x595639
push esi
push 0x6a66e4
push ecx
call fcn.006094e9
jmp 0x59565d
neg ecx
sbb ecx, ecx
not ecx
test eax, ecx
je 0x595660
mov edx, dword [eax + 0x14]
neg edx
sbb edx, edx
not edx
push esi
and edx, eax
mov eax, dword [edx + 4]
push 0x6a66e4
push eax
call fcn.0061c8da
add esp, 0xc
add esi, 4
sub edi, 1
jne 0x595622
fild dword [esp + 0x28]
xor eax, eax
mov ecx, ebp
fstp dword [esp + 0x14]
fld dword [esp + 0x14]
fld st(0)
add eax, 1
fidiv dword [esp + eax*4 + 0x28]
add ecx, 4
cmp eax, 3
fstp dword [ecx - 4]
jl 0x595678
fstp st(0)
mov esi, dword [esp + 0x20]
push esi
mov ecx, ebx
call fcn.005951a0
mov ecx, dword [esp + 0x24]
mov eax, dword [ebx]
add ecx, esi
cmp dword [eax + 0x14], 0
je 0x5956bf
cmp dword [eax + 0x18], 0xffffffff
je 0x5956ce
mov edx, dword [eax + 0x1c]
cmp edx, ecx
mov dword [eax + 0x18], ecx
ja 0x5956ba
mov ecx, edx
mov dword [eax + 0x18], ecx
jmp 0x5956ce
mov edx, dword [eax + 4]
push 0
push ecx
push edx
call fcn.006081d8
add esp, 0xc
mov esi, ebx
call fcn.0057e000
cmp eax, 0x504b5453
je 0x595210
pop edi
pop ebp
mov esi, dword [esp + 0x10]
test esi, esi
je 0x595728
mov ecx, dword [ebx + 0x474]
mov eax, 0xb60b60b7
imul ecx
add edx, ecx
sar edx, 6
mov eax, edx
shr eax, 0x1f
add eax, edx
add eax, dword [esp + 0x14]
xor edx, edx
and eax, 3
movzx ecx, byte [eax + 0x6b6180]
cmp esi, 1
sete dl
imul ecx, edx
imul ecx, ecx, 0x1010101
mov dword [ebx + 0x338], ecx
mov ecx, dword [esp + 0x7c]
pop esi
pop ebx
xor ecx, esp
call fcn.00607d6d
add esp, 0x78
ret 4