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

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0x98
mov edi, dword [ebp + 0x1c]
mov esi, dword [ebp + 8]
test esi, esi
je 0x10007148
movzx ebx, word [ebp + 0xc]
mov eax, dword [esi]
push 0x50
call dword [eax + 0x68]
add esp, 4
mov dword [edi], eax
mov eax, dword [esi]
push dword [eax + 0x60]
call sym._FAudio_PlatformLockMutex
add esp, 4
mov ecx, dword [esi + 0x1c]
movzx ebx, bx
lea edx, [ebx + ebx*2]
mov eax, dword [edi]
mov dword [eax], esi
mov eax, dword [edi]
mov dword [eax + 4], 0
mov eax, dword [edi]
mov dword [esp + 0x10], ebx
mov word [eax + 8], bx
mov eax, dword [edi]
mov byte [eax + 0xa], 0
mov eax, dword [edi]
mov dword [eax + 0xc], 0
mov eax, dword [edi]
mov dword [eax + 0x10], 4
mov eax, dword [edi]
mov dword [eax + 0x14], 0x3f800000
mov eax, dword [edi]
mov word [eax + 0x18], 0
mov eax, dword [edi]
movzx ebx, byte [ebp + 0x18]
mov byte [eax + 0x1a], bl
mov dword [esp + 0x4c], 0
mov eax, dword [esi]
mov eax, dword [eax + 0x54]
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], 1
lea eax, [esp + 0x4c]
mov dword [esp + 0x58], eax
mov dword [esp + 0xc], ecx
mov dword [esp + 4], edx
mov ecx, dword [ecx + edx*8 + 4]
mov ebx, ecx
shr ebx, 2
and ebx, 7
mov word [esp + 0x16], bx
mov eax, ecx
shr eax, 5
and eax, 0x3ffff
mov dword [esp + 0x18], eax
mov edx, ecx
and edx, 3
cmp edx, 2
je 0x10007263
cmp edx, 1
je 0x10007158
test edx, edx
jne 0x10007294
mov word [esp + 0x14], 1
shr ecx, 0x1f
mov edx, 8
shl edx, cl
mov word [esp + 0x22], dx
movzx edx, bx
add cl, 3
shl edx, cl
shr edx, 3
mov word [esp + 0x20], dx
imul edx, eax
mov dword [esp + 0x1c], edx
mov word [esp + 0x24], 0
jmp 0x100072c7
mov dword [edi], 0
mov eax, 1
jmp 0x100074c8
mov eax, dword [esi + 0x24]
mov dword [esp + 8], eax
mov word [esp + 0x14], 0x166
mov dword [esp + 0x22], 0x220010
mov edx, ecx
shr edx, 0x1a
and edx, 0x1c
mov edx, dword [edx + 0x100271a4]
mov dword [esp + 0x1c], edx
shr ecx, 0x15
and ecx, 0x7c
movzx ecx, word [ecx + 0x100271c0]
mov word [esp + 0x20], cx
movzx edx, bx
inc edx
shr edx, 1
mov ecx, ebx
neg cl
mov eax, 0xffffffff
shr eax, cl
xor ecx, ecx
cmp bx, 2
cmovae ecx, eax
mov word [esp + 0x26], dx
mov dword [esp + 0x28], ecx
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 8]
mov edx, dword [ecx + eax*8]
mov dword [esp + 0x48], edx
movss xmm0, dword [ecx + eax*8]
mov eax, dword [ecx + eax*8 + 4]
mov eax, dword [eax + edx*4 - 4]
mov dword [esp + 8], eax
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 4]
movss xmm1, dword [eax + ecx*8 + 0xc]
movsd xmm2, qword [0x10027118]
orpd xmm1, xmm2
subsd xmm1, xmm2
orpd xmm0, xmm2
subsd xmm0, xmm2
divsd xmm1, xmm0
mulsd xmm1, qword [0x10027120]
sub esp, 8
movsd qword [esp], xmm1
call sym._ceil
add esp, 8
fstp qword [esp + 0x88]
cvttsd2si eax, qword [esp + 0x88]
movzx eax, ax
shl eax, 0xb
mov dword [esp + 0x30], eax
mov dword [esp + 0x3c], 0
mov dword [esp + 0x34], 0
mov eax, dword [esp + 8]
mov dword [esp + 0x40], eax
mov dword [esp + 0x38], eax
mov word [esp + 0x44], 0x400
mov eax, dword [esp + 0x48]
mov word [esp + 0x46], ax
jmp 0x100072c7
mov word [esp + 0x14], 2
shr ecx, 0x17
movzx eax, cl
lea ecx, [eax + 0x16]
movzx edx, bx
imul edx, ecx
mov word [esp + 0x20], dx
mov dword [esp + 0x22], 0x40010
lea eax, [eax*2 + 0x20]
mov word [esp + 0x26], ax
jmp 0x100072c7
mov word [esp + 0x14], 0x161
mov eax, ecx
shr eax, 0x1a
and eax, 0x1c
mov eax, dword [eax + 0x100271a4]
mov dword [esp + 0x1c], eax
shr ecx, 0x15
and ecx, 0x7c
movzx eax, word [ecx + 0x100271c0]
mov word [esp + 0x20], ax
mov dword [esp + 0x22], 0x10
xor eax, eax
cmp word [esi + 0x30], 0
mov ecx, dbg.FACT_INTERNAL_OnBufferEnd
cmove ecx, eax
mov eax, dword [edi]
mov dword [eax + 0x30], ecx
mov eax, dword [edi]
mov dword [eax + 0x34], 0
mov eax, dword [edi]
mov dword [eax + 0x38], 0
mov eax, dword [edi]
mov dword [eax + 0x3c], dbg.FACT_INTERNAL_OnStreamEnd
mov eax, dword [edi]
mov dword [eax + 0x40], 0
mov eax, dword [edi]
mov dword [eax + 0x44], 0
mov eax, dword [edi]
mov dword [eax + 0x48], 0
mov eax, dword [edi]
mov dword [eax + 0x4c], eax
mov word [eax + 0x28], bx
mov eax, dword [esi]
mov ecx, dword [edi]
lea edx, [ecx + 0x2c]
add ecx, 0x30
lea ebx, [esp + 0x54]
mov edi, esi
lea esi, [esp + 0x14]
push 0
push ebx
push ecx
push 0x40800000
push 8
push esi
mov esi, edi
push edx
push dword [eax + 0x50]
call dbg.FAudio_CreateSourceVoice
add esp, 0x20
cmp word [edi + 0x30], 0
je 0x10007380
mov edi, dword [ebp + 0x1c]
movzx eax, word [esp + 0x14]
cmp eax, 2
mov ebx, dword [esp + 0xc]
mov ecx, dword [esp + 4]
je 0x100073e9
cmp eax, 1
jne 0x10007400
movzx ecx, word [esp + 0x20]
imul ecx, dword [esp + 0x18]
jmp 0x10007404
mov ebx, dword [esp + 0xc]
mov ecx, esi
mov esi, dword [esp + 4]
lea edi, [ebx + esi*8]
mov eax, dword [ebp + 0x1c]
mov eax, dword [eax]
mov dword [eax + 0x24], 0
mov dword [esp + 0x64], 0x40
mov eax, dword [ebx + esi*8 + 0xc]
mov dword [esp + 0x68], eax
push dword [ebx + esi*8 + 8]
push dword [ecx + 0x3c]
call dbg.FAudio_memptr
add esp, 8
mov dword [esp + 0x6c], eax
mov dword [esp + 0x70], 0
mov eax, dword [edi]
shr eax, 4
mov dword [esp + 0x74], eax
movzx eax, byte [ebp + 0x18]
test al, al
mov edi, dword [ebp + 0x1c]
je 0x1000743a
movzx eax, al
mov ecx, dword [ebx + esi*8 + 0x10]
mov dword [esp + 0x78], ecx
mov ecx, dword [ebx + esi*8 + 0x14]
jmp 0x10007446
mov eax, dword [esp + 0x18]
movzx ecx, word [esp + 0x26]
xor edx, edx
div ecx
movzx ecx, word [esp + 0x20]
imul ecx, eax
jmp 0x10007404
mov ecx, dword [ebx + ecx*8 + 0xc]
mov eax, dword [edi]
mov dword [eax + 0x1c], ecx
mov eax, dword [esi]
mov ecx, dword [edi]
push dword [ecx + 0x1c]
call dword [eax + 0x68]
add esp, 4
mov ecx, dword [edi]
mov dword [ecx + 0x24], eax
mov eax, dword [esp + 4]
mov eax, dword [ebx + eax*8 + 8]
mov ecx, dword [edi]
mov dword [ecx + 0x20], eax
mov eax, dword [edi]
add eax, 0x30
push 0
push eax
call dbg.FACT_INTERNAL_OnBufferEnd
add esp, 8
jmp 0x100074a3
mov dword [esp + 0x78], 0
xor ecx, ecx
xor eax, eax
mov dword [esp + 0x7c], ecx
mov dword [esp + 0x80], eax
mov dword [esp + 0x84], 0
movzx eax, word [esp + 0x14]
cmp eax, 0x161
mov esi, dword [ebp + 8]
jne 0x1000748f
mov eax, dword [esi + 0x24]
mov edx, dword [esp + 0x10]
mov ecx, dword [eax + edx*8 + 4]
mov dword [esp + 0x5c], ecx
mov eax, dword [eax + edx*8]
mov dword [esp + 0x60], eax
mov eax, dword [edi]
lea ecx, [esp + 0x5c]
lea edx, [esp + 0x64]
push ecx
push edx
jmp 0x10007498
mov eax, dword [edi]
lea ecx, [esp + 0x64]
push 0
push ecx
push dword [eax + 0x2c]
call dbg.FAudioSourceVoice_SubmitSourceBuffer
add esp, 0xc
lea eax, [esi + 4]
mov ecx, dword [esi]
push dword [ecx + 0x68]
push dword [esi + 8]
push dword [edi]
push eax
call dbg.LinkedList_AddEntry
add esp, 0x10
mov eax, dword [esi]
push dword [eax + 0x60]
call sym._FAudio_PlatformUnlockMutex
add esp, 4
xor eax, eax
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret