Function at 0x4b91a0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x740
mov eax, dword [0x641a90]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov edi, dword [ebp + 0xc]
mov esi, 1
mov dword [ebp - 0x738], ebx
mov al, byte [edi + 0xd6]
test al, al
je 0x4b91fc
cmp al, 2
jne 0x4b91fc
mov word [ebp - 0x734], si
mov dword [ebp - 0x72c], fcn.0045d510
mov dword [ebp - 0x730], fcn.0045d590
mov dword [ebp - 0x728], fcn.0045d490
jmp 0x4b9223
xor eax, eax
mov dword [ebp - 0x728], 0x45d450
mov dword [ebp - 0x730], fcn.0045d560
mov dword [ebp - 0x72c], fcn.0045d4e0
mov word [ebp - 0x734], ax
xor eax, eax
push 0x2fc
push eax
mov word [ebp - 0x732], ax
lea eax, [ebp - 0x680]
push eax
call fcn.00595760
mov eax, dword [str.V1.0]
movq xmm0, qword [str.LIBFORMAT]
mov dword [ebp - 0x67c], eax
mov al, byte [0x5dc574]
mov byte [ebp - 0x678], al
mov ax, word [0x5dc580]
push 0x280
mov word [ebp - 0x5dc], ax
lea eax, [ebp - 0x384]
push 0
push eax
mov dword [ebp - 0x680], 0x680
mov dword [ebp - 0x674], 0
mov dword [ebp - 0x670], esi
mov dword [ebp - 0x66c], 0x680
mov dword [ebp - 0x668], 0
mov dword [ebp - 0x664], 0
mov dword [ebp - 0x3f0], 0xffffffff
movq qword [ebp - 0x5e4], xmm0
call fcn.00595760
cmp word [edi + 0x40], 3
mov edx, 0x3ff
mov eax, dword [edi + 0x2c]
mov cl, byte [edi + 0xc8]
mov dword [ebp - 0x380], eax
mov eax, dword [edi + 0x30]
mov dword [ebp - 0x37c], eax
setg al
add al, 0x32
mov dword [ebp - 0x384], 0x10000
mov byte [ebp - 0x364], al
test cl, cl
push 0x100
setne al
mov dword [ebp - 0x378], 0
mov dword [ebp - 0x374], 0
mov dword [ebp - 0x370], 0
mov dword [ebp - 0x368], 0x4003020c
lea eax, [eax*2 + 8]
mov word [ebp - 0x363], 0x202
mov byte [ebp - 0x361], al
xor eax, eax
test cl, cl
mov dword [ebp - 0x35c], 0x680
setne al
test cl, cl
mov word [ebp - 0x360], ax
mov eax, 0xff
cmovne eax, edx
mov dword [ebp - 0x36c], eax
xor eax, eax
push eax
mov word [ebp - 0x35e], ax
mov dword [ebp - 0x358], eax
mov dword [ebp - 0x354], eax
lea eax, [ebp - 0x104]
push eax
call fcn.00595760
lea eax, [ebp - 0x734]
mov dword [ebp - 0x104], 0xffffffff
push eax
lea eax, [ebp - 0x680]
mov dword [ebp - 0x100], 0xffffffff
push eax
push ebx
mov dword [ebp - 0xfc], 0xbf800000
mov dword [ebp - 0xf8], 0xbf800000
mov dword [ebp - 0xf4], 0xffffffff
mov dword [ebp - 0xf0], 0xffffffff
call fcn.004b95d0
lea eax, [ebp - 0x734]
push eax
lea eax, [ebp - 0x384]
push eax
push ebx
call fcn.004b96c0
lea eax, [ebp - 0x734]
push eax
lea eax, [ebp - 0x104]
push eax
push ebx
call fcn.004b97f0
add esp, 0x48
lea eax, [ebp - 0x724]
push eax
call fcn.00458dd0
movzx ecx, word [edi + 0x40]
add esp, 4
movsx edx, cx
imul edx, dword [edi + 0x2c]
mov dword [ebp - 0x700], 0x585044
mov word [ebp - 0x718], si
lea eax, [ecx*8]
mov word [ebp - 0x716], ax
mov dword [ebp - 0x70c], edx
cmp cx, 3
jle 0x4b945b
mov dword [ebp - 0x724], 0x20
jmp 0x4b9477
lea eax, [edx + 3]
mov dword [ebp - 0x724], 8
cdq
and edx, 3
add eax, edx
and eax, 0xfffffffc
mov dword [ebp - 0x70c], eax
lea eax, [ebp - 0x724]
push eax
push edi
call fcn.00457000
movzx esi, ax
add esp, 8
mov dword [ebp - 0x73c], esi
test si, si
jne 0x4b9596
xor eax, eax
mov dword [ebp - 0x740], eax
cmp dword [edi + 0x30], eax
jle 0x4b958d
lea ebx, [ebx]
push 1
push eax
push edi
call fcn.00459620
add esp, 0xc
cmp byte [edi + 0xc8], 0
je 0x4b9567
xor ebx, ebx
cmp dword [edi + 0x2c], ebx
jle 0x4b9549
mov esi, dword [ebp - 0x71c]
inc esi
jmp 0x4b94e0
mov edx, dword [edi + 0xdc]
test edx, edx
je 0x4b9518
movzx eax, byte [esi - 1]
movzx ecx, word [edx + eax*2]
movzx eax, byte [esi]
shl ecx, 0xa
movzx eax, word [edx + eax*2 + 0x200]
or ecx, eax
movzx eax, byte [esi + 1]
shl ecx, 0xa
movzx eax, word [edx + eax*2 + 0x400]
or ecx, eax
shl ecx, 2
jmp 0x4b9530
movzx ecx, byte [esi + 1]
movzx eax, byte [esi]
shl ecx, 0xa
or ecx, eax
movzx eax, byte [esi - 1]
shl ecx, 0xa
or ecx, eax
shl ecx, 4
push dword [ebp - 0x738]
add esi, 3
push ecx
call dword [ebp - 0x72c]
inc ebx
add esp, 8
cmp ebx, dword [edi + 0x2c]
jl 0x4b94e0
mov ebx, dword [ebp - 0x738]
mov eax, dword [ebp - 0x740]
inc eax
mov dword [ebp - 0x740], eax
cmp eax, dword [edi + 0x30]
jl 0x4b94b0
jmp 0x4b958d
push dword [ebx]
push 1
push dword [ebp - 0x70c]
push dword [ebp - 0x71c]
call fcn.0059628c
add esp, 0x10
test eax, eax
jne 0x4b954f
mov dword [ebp - 0x73c], 6
push edi
call fcn.00454fa0
add esp, 4
push dword [ebx]
call fcn.005960c7
push 0
push 0x10
push dword [ebx]
mov esi, eax
call fcn.00595cb4
push ebx
push esi
call dword [ebp - 0x72c]
mov ecx, dword [ebp - 4]
add esp, 0x18
mov ax, word [ebp - 0x73c]
xor ecx, ebp
pop edi
pop esi
pop ebx
call fcn.005920c1
mov esp, ebp
pop ebp
ret