Function at 0x45fe60
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x30
push ebx
push ebp
push esi
xor ebp, ebp
push edi
push ebp
lea eax, [esp + 0x34]
push ebp
lea ecx, [esp + 0x1c]
mov edi, dword [esp + 0x50]
push eax
lea edx, [esp + 0x24]
push ecx
lea eax, [esp + 0x38]
push edx
lea ecx, [esp + 0x38]
push eax
lea edx, [esp + 0x28]
push ecx
lea eax, [esp + 0x38]
push edx
lea ecx, [esp + 0x54]
push eax
lea edx, [esp + 0x70]
push ecx
push edx
push edi
mov dword [esp + 0x48], ebp
mov dword [esp + 0x44], ebp
mov dword [esp + 0x60], ebp
call fcn.0045f960
add esp, 0x30
test al, al
jne 0x45febf
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x30
ret
mov eax, dword [esp + 0x18]
push ebp
push eax
push edi
call fcn.00459064
mov ecx, dword [esp + 0x30]
add esp, 0xc
cmp dword [ecx + 0x4874], ebp
jne 0x45feef
mov edx, dword [esp + 0x14]
push ebp
push edx
push edi
call fcn.0045f820
add esp, 0xc
mov dword [esp + 0x10], eax
jmp 0x45fef3
mov eax, dword [esp + 0x10]
cmp eax, ebp
jne 0x45ff0b
pop edi
pop esi
pop ebp
mov dword [0x4c0638], 0xa
xor eax, eax
pop ebx
add esp, 0x30
ret
mov ecx, dword [esp + 0x4c]
test cl, 0x10
je 0x45ff16
sar eax, 1
mov edx, ecx
and edx, 0x40
je 0x45ff1f
sar eax, 1
test ch, 0x10
je 0x45ff32
cmp edx, ebp
je 0x45ff32
or ecx, 0x40000
mov dword [esp + 0x4c], ecx
test ecx, 0x40000
je 0x45ff46
test cl, 0x40
je 0x45ff46
and ch, 0xef
mov dword [esp + 0x4c], ecx
mov edx, ecx
push 0xff
and dl, 0x40
neg dl
sbb edx, edx
and dl, 0x7f
add edx, 0x80
push edx
mov edx, dword [esp + 0x3c]
push 0xff
push edx
push ecx
push eax
mov eax, dword [esp + 0x5c]
push eax
call fcn.0045535a
mov esi, eax
cmp esi, ebp
jne 0x45ff84
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x30
ret
mov ecx, dword [esi + 0x10c]
dec ecx
push ecx
push ebp
push esi
call fcn.004559d8
mov edx, dword [esp + 0x24]
push 0x242
mov dword [esi + 0x155], edx
mov eax, dword [esp + 0x20]
add eax, 0x3e8
push str.E:devcgames_fmod351_src_format_mpeg.c
push eax
push ebp
call fcn.00458b43
mov ebx, eax
add esp, 0x10
cmp ebx, ebp
mov dword [esp + 0x2c], ebx
jne 0x45ffde
push esi
mov dword [0x4c0638], 0xc
call fcn.0045541b
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x30
ret
mov ecx, dword [esp + 0x18]
push ebp
push ecx
push edi
call fcn.00459064
add esp, 0xc
lea edx, [esp + 0x38]
lea eax, [esp + 0x44]
lea ecx, [esp + 0x3c]
push edx
push eax
mov eax, dword [esp + 0x18]
lea edx, [esp + 0x28]
push ecx
push edx
push eax
push ebp
push esi
xor edi, edi
call fcn.0045589d
mov ecx, dword [esp + 0x48]
mov edx, dword [esp + 0x1c]
push ecx
push edx
push ebx
call fcn.00458f11
add esp, 0xc
jmp 0x460028
mov ebx, dword [esp + 0x2c]
mov ecx, dword [esi + 0x155]
lea eax, [esp + 0x28]
push eax
add ebx, ebp
push 0
push 0
push ebx
push ecx
mov byte [esp + 0x5c], 0
call fcn.0045bde0
add esp, 0x14
test eax, eax
je 0x46007a
mov eax, dword [esp + 0x20]
mov ecx, dword [esi + 0x155]
lea edx, [esp + 0x14]
add eax, edi
push edx
push eax
push ebx
push ecx
call fcn.0045bfe0
mov eax, dword [esp + 0x24]
mov edx, dword [esp + 0x38]
add esp, 0x10
add edi, eax
lea ebp, [edx + ebp + 4]
mov al, 1
jmp 0x46007e
mov al, byte [esp + 0x48]
mov ecx, dword [esp + 0x10]
add ecx, 0xfffff000
cmp edi, ecx
jge 0x460096
cmp ebp, dword [esp + 0x1c]
jge 0x460096
test al, al
jne 0x460024
test byte [esp + 0x4c], 8
je 0x4600bc
mov edx, dword [esp + 0x44]
mov eax, dword [esp + 0x20]
xor ecx, ecx
test edx, edx
jle 0x4600bc
mov dl, byte [eax]
xor dl, 0x80
mov byte [eax], dl
mov edx, dword [esp + 0x44]
inc eax
inc ecx
cmp ecx, edx
jl 0x4600ab
mov edx, dword [esp + 0x38]
mov eax, dword [esp + 0x44]
mov ecx, dword [esp + 0x3c]
push edx
mov edx, dword [esp + 0x24]
push eax
push ecx
push edx
push esi
call fcn.00455927
mov cl, byte [esp + 0x4c]
mov eax, dword [esp + 0x10]
test cl, 0x10
je 0x4600e5
sar eax, 1
test cl, 0x40
je 0x4600ec
sar eax, 1
dec eax
push eax
push 0
push esi
call fcn.004559d8
mov eax, dword [esp + 0x2c]
push 0x285
push str.E:devcgames_fmod351_src_format_mpeg.c
push eax
push 0
call fcn.00458ae9
push esi
call fcn.0045fe30
add esp, 0x14
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x30
ret