Function at 0x489800
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x480
mov eax, dword [0x641a90]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 0x18]
lea eax, [ebp - 0x46c]
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, dword [ebp + 0xc]
push eax
mov dword [ebp - 0x480], esi
mov dword [ebp - 0x47c], edi
mov dword [ebp - 0x478], ebx
call fcn.00457d90
mov eax, dword [str.TIM_PS2]
add esp, 4
movzx edx, word [edi + 0x14]
mov dword [ebp - 0x386], eax
mov eax, dword [0x5d9b14]
mov dword [ebp - 0x382], eax
movzx eax, word [edi + 0x16]
mov dword [ebp - 0x458], eax
movzx eax, byte [edi + 0x13]
dec eax
mov dword [ebp - 0x45c], edx
cmp eax, 4
ja case.default.0x489878
jmp dword [eax*4 + 0x489c3c]
mov eax, 0xf
mov dword [ebp - 0x46c], 0x200
mov word [ebp - 0x452], ax
lea eax, [edx + edx]
jmp 0x4898f8
mov eax, 0x18
mov dword [ebp - 0x46c], 0
mov word [ebp - 0x452], ax
cwde
imul eax, edx
jmp 0x4898ef
mov eax, 0x20
mov dword [ebp - 0x46c], 0
mov word [ebp - 0x452], ax
cwde
imul eax, edx
jmp 0x4898ef
mov ecx, 4
jmp 0x4898de
mov ecx, 8
mov word [ebp - 0x452], cx
lea eax, [edx + 1]
movsx ecx, cx
imul eax, ecx
dec eax
cdq
and edx, 7
add eax, edx
sar eax, 3
mov ecx, dword [ebp + 0x10]
mov dword [ebp - 0x44c], eax
mov eax, 1
mov word [ebp - 0x454], ax
movzx eax, word [edi + 0xc]
add ecx, eax
cmp word [ebp + 0x14], 1
mov dword [ebp + 0x10], ecx
push 0
jne 0x489927
lea eax, [ecx + 0x7f]
and eax, 0xffffff80
jmp 0x48992d
lea eax, [ecx + 0xf]
and eax, 0xfffffff0
push eax
push dword [esi]
call fcn.00595cb4
add esp, 0xc
lea eax, [ebp - 0x46c]
push eax
push ebx
call fcn.00456000
movzx ebx, ax
add esp, 8
mov dword [ebp - 0x474], ebx
test bx, bx
jne 0x489be1
xor edi, edi
cmp dword [ebp - 0x458], edi
jle 0x4899ef
jmp 0x489970
push dword [esi]
push 1
push dword [ebp - 0x44c]
push dword [ebp - 0x460]
call fcn.00595b79
add esp, 0x10
test eax, eax
je 0x4899e5
cmp word [ebp - 0x452], 4
jne 0x4899b8
xor eax, eax
cmp dword [ebp - 0x44c], eax
jle 0x4899b8
mov edx, dword [ebp - 0x460]
mov cl, byte [edx + eax]
ror cl, 4
mov byte [edx + eax], cl
inc eax
cmp eax, dword [ebp - 0x44c]
jl 0x4899a0
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp - 0x478]
call fcn.004585b0
movzx ebx, ax
add esp, 0x10
mov dword [ebp - 0x474], ebx
test bx, bx
jne 0x4899ef
inc edi
cmp edi, dword [ebp - 0x458]
jl 0x489970
jmp 0x4899ef
mov dword [ebp - 0x474], 4
mov eax, dword [ebp - 0x47c]
mov ebx, dword [ebp + 0x10]
push 1
push dword [esi]
add ebx, dword [eax + 8]
call fcn.005960c7
add esp, 4
sub ebx, eax
push ebx
push dword [esi]
call fcn.00595cb4
mov edx, dword [ebp - 0x47c]
add esp, 0xc
test byte [edx + 0x12], 3
je 0x489bcd
cmp dword [edx + 4], 0
je 0x489bcd
mov cl, byte [ebp - 0x452]
mov eax, 1
shl eax, cl
xor edi, edi
xor ebx, ebx
test eax, eax
jle 0x489b99
jmp 0x489a50
mov al, byte [edx + 0x12]
mov byte [ebp - 0x46d], al
test al, al
js 0x489aa3
mov ecx, ebx
and ecx, 0x8000001f
jns 0x489a6c
dec ecx
or ecx, 0xffffffe0
inc ecx
cmp ecx, 8
jl 0x489a8d
cmp ecx, 0x10
jge 0x489a85
cmp word [ebp - 0x452], 4
je 0x489a8d
add ecx, 8
jmp 0x489a8d
cmp ecx, 0x18
jge 0x489a8d
add ecx, 0xfffffff8
mov eax, ebx
cdq
and edx, 0x1f
add eax, edx
and eax, 0xffffffe0
add eax, ecx
lea edi, [eax + eax*2]
mov al, byte [ebp - 0x46d]
movzx eax, al
and eax, 3
dec eax
je 0x489af5
dec eax
je 0x489ad9
dec eax
jne 0x489b7a
push dword [esi]
lea eax, [ebp - 0x304]
push 1
add eax, edi
push 3
push eax
call fcn.00595b79
push dword [esi]
call fcn.00597fff
add esp, 0x14
jmp 0x489b7a
push dword [esi]
lea eax, [ebp - 0x304]
push 1
add eax, edi
push 3
push eax
call fcn.00595b79
add esp, 0x10
jmp 0x489b7a
push esi
call fcn.0045d210
movzx esi, ax
add esp, 4
mov eax, esi
shr eax, 0xa
and eax, 0x1f
imul ecx, eax, 0xff
mov eax, 0x84210843
imul ecx
add edx, ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
mov byte [ebp + edi - 0x302], al
mov eax, esi
shr eax, 5
and esi, 0x1f
and eax, 0x1f
imul ecx, eax, 0xff
mov eax, 0x84210843
imul ecx
add edx, ecx
imul ecx, esi, 0xff
sar edx, 4
mov esi, dword [ebp - 0x480]
mov eax, edx
shr eax, 0x1f
add eax, edx
mov byte [ebp + edi - 0x303], al
mov eax, 0x84210843
imul ecx
add edx, ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
mov byte [ebp + edi - 0x304], al
mov cl, byte [ebp - 0x452]
mov eax, 1
mov edx, dword [ebp - 0x47c]
inc ebx
shl eax, cl
add edi, 3
cmp ebx, eax
jl 0x489a50
lea eax, [ebp - 0x304]
push eax
push 8
push 0x100
push dword [ebp - 0x478]
call fcn.00453f80
mov ax, word [ebp - 0x474]
add esp, 0x10
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
push 0
push 0
push 0
push dword [ebp - 0x478]
call fcn.00453f80
add esp, 0x10
mov ax, word [ebp - 0x474]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005920c1
mov esp, ebp
pop ebp
ret
movdqu xmm0, xmmword [str.TIM_:_Bad_pictures_format__]
mov ecx, dword [ebp - 4]
pop edi
movdqu xmmword [ebx + 0x44], xmm0
xor ecx, ebp
movq xmm0, qword [0x5d9b28]
movq qword [ebx + 0x54], xmm0
mov eax, dword [0x5d9b30]
mov dword [ebx + 0x5c], eax
mov al, byte [0x5d9b34]
mov byte [ebx + 0x60], al
mov eax, 9
pop esi
pop ebx
call fcn.005920c1
mov esp, ebp
pop ebp
ret