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

Disassembly:
mov eax, 0x3080
call fcn.00560f10
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x3094]
test edi, edi
jne 0x51f970
push 0xd55a
push str.C:PureBasicSvn_v6.10LibrariesSoundMiniAudiominiaudiominiaudio.h
push str.pConverter_____void__0_
call fcn.00587dd0
add esp, 0xc
mov eax, dword [edi + 0x5c]
cmp eax, dword [edi + 0x20]
je 0x51f98f
push 0xd55b
push str.C:PureBasicSvn_v6.10LibrariesSoundMiniAudiominiaudiominiaudio.h
push str.pConverter__resampler.format__pConverter__channelConverter.format
call fcn.00587dd0
add esp, 0xc
mov eax, dword [edi + 0x60]
cmp eax, dword [edi + 0x24]
je 0x51f9ae
push 0xd55c
push str.C:PureBasicSvn_v6.10LibrariesSoundMiniAudiominiaudiominiaudio.h
push str.pConverter__resampler.channels__pConverter__channelConverter.channelsIn
call fcn.00587dd0
add esp, 0xc
mov ebx, dword [edi + 0x60]
mov ebp, dword [edi + 0x28]
cmp ebx, ebp
jb 0x51f9d5
push 0xd55d
push str.C:PureBasicSvn_v6.10LibrariesSoundMiniAudiominiaudiominiaudio.h
push str.pConverter__resampler.channels___pConverter__channelConverter.channelsOut
call fcn.00587dd0
mov ebx, dword [edi + 0x60]
add esp, 0xc
mov ebp, dword [edi + 0x28]
mov eax, dword [esp + 0x309c]
xorps xmm0, xmm0
movlpd qword [esp + 0x20], xmm0
test eax, eax
je 0x51f9f8
mov edx, dword [eax]
mov dword [esp + 0x68], edx
mov edx, dword [eax + 4]
mov dword [esp + 0x64], edx
jmp 0x51fa08
mov eax, dword [esp + 0x24]
mov dword [esp + 0x64], eax
mov eax, dword [esp + 0x20]
mov dword [esp + 0x68], eax
mov ecx, dword [esp + 0x30a4]
movlpd qword [esp + 0x20], xmm0
test ecx, ecx
je 0x51fa28
mov eax, dword [ecx]
mov dword [esp + 0x1c], eax
mov eax, dword [ecx + 4]
mov dword [esp + 0x30], eax
jmp 0x51fa38
mov eax, dword [esp + 0x24]
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x20]
mov dword [esp + 0x1c], eax
mov esi, dword [edi + 0x5c]
xor edx, edx
mov dword [esp + 0x34], 0
mov eax, 0x1000
mov dword [esp + 0x38], 1
mov dword [esp + 0x3c], 2
mov dword [esp + 0x40], 3
mov dword [esp + 0x44], 4
mov dword [esp + 0x48], 4
mov ecx, dword [esp + esi*4 + 0x34]
imul ecx, ebx
mov dword [esp + 0x34], 0
mov dword [esp + 0x38], 1
mov dword [esp + 0x3c], 2
mov dword [esp + 0x40], 3
div ecx
mov dword [esp + 0x44], 4
xor edx, edx
mov dword [esp + 0x48], 4
mov ecx, dword [esp + esi*4 + 0x34]
imul ecx, ebx
mov dword [esp + 0x78], eax
mov eax, 0x1000
mov dword [esp + 0x34], 0
mov dword [esp + 0x38], 1
mov dword [esp + 0x3c], 2
div ecx
mov ecx, dword [edi + 0x20]
xor edx, edx
mov dword [esp + 0x40], 3
mov dword [esp + 0x44], 4
mov dword [esp + 0x48], 4
mov ecx, dword [esp + ecx*4 + 0x34]
imul ecx, ebp
mov dword [esp + 0x7c], eax
mov eax, 0x1000
movlpd qword [esp + 0x20], xmm0
movlpd qword [esp + 0x70], xmm0
div ecx
cmp dword [esp + 0x30], 0
mov dword [esp + 0x80], eax
jb 0x51ff41
ja 0x51fb31
cmp dword [esp + 0x1c], 0
jbe 0x51ff41
mov ebp, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
mov ecx, dword [esp + 0x74]
mov esi, dword [esp + 0x70]
mov dword [esp + 0x6c], edx
mov dword [esp + 0x84], ebp
mov dword [esp + 0x58], ecx
mov dword [esp + 0x20], esi
cmp dword [esp + 0x3098], 0
mov ebx, dword [esp + 0x30a0]
mov dword [esp + 0x60], 0
mov dword [esp + 0x70], 0
je 0x51fbbd
mov eax, dword [edi]
mov dword [esp + 0x34], 0
mov dword [esp + 0x38], 1
mov dword [esp + 0x3c], 2
mov dword [esp + 0x40], 3
mov dword [esp + 0x44], 4
mov dword [esp + 0x48], 4
mov eax, dword [esp + eax*4 + 0x34]
imul eax, dword [edi + 8]
imul eax, ebp
add eax, dword [esp + 0x3098]
mov dword [esp + 0x60], eax
test ebx, ebx
je 0x51fc05
mov eax, dword [edi + 4]
mov dword [esp + 0x34], 0
mov dword [esp + 0x38], 1
mov dword [esp + 0x3c], 2
mov dword [esp + 0x40], 3
mov dword [esp + 0x44], 4
mov dword [esp + 0x48], 4
mov eax, dword [esp + eax*4 + 0x34]
imul eax, dword [edi + 0xc]
imul eax, esi
add eax, ebx
mov dword [esp + 0x70], eax
mov ebx, dword [esp + 0x68]
mov al, byte [edi + 0xe0]
sub ebx, ebp
mov ebp, dword [esp + 0x64]
sbb ebp, edx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebp
mov byte [esp + 0x13], al
test al, al
je 0x51fc41
test ebp, ebp
jb 0x51fc41
mov eax, dword [esp + 0x78]
ja 0x51fc35
cmp ebx, eax
jbe 0x51fc41
mov ebx, eax
xor ebp, ebp
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebp
mov eax, dword [esp + 0x1c]
mov edx, dword [esp + 0x30]
sub eax, esi
mov dword [esp + 0x54], eax
sbb edx, ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], edx
mov ecx, eax
mov esi, edx
test edx, edx
jb 0x51fc7f
ja 0x51fc69
cmp eax, dword [esp + 0x7c]
jbe 0x51fc7f
mov ecx, dword [esp + 0x7c]
xor edx, edx
mov eax, ecx
mov dword [esp + 0x18], edx
mov dword [esp + 0x54], eax
xor esi, esi
mov dword [esp + 0x14], eax
cmp byte [edi + 0xe1], 0
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x50], esi
je 0x51fcc2
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x50], esi
test esi, esi
jb 0x51fcc2
ja 0x51fca7
cmp ecx, dword [esp + 0x80]
jbe 0x51fcc2
mov ecx, dword [esp + 0x80]
xor edx, edx
mov eax, ecx
mov dword [esp + 0x18], edx
mov dword [esp + 0x54], eax
xor esi, esi
mov dword [esp + 0x14], eax
jmp 0x51fcca
mov ecx, dword [esp + 0x4c]
mov esi, dword [esp + 0x50]
lea eax, [edi + 0x50]
xorps xmm0, xmm0
movlpd qword [esp + 0x88], xmm0
test eax, eax
je 0x51fd3c
mov eax, dword [eax + 4]
test eax, eax
je 0x51fd34
mov eax, dword [eax + 0x1c]
test eax, eax
je 0x51fd34
lea edx, [esp + 0x88]
push edx
push esi
push ecx
push dword [edi + 0x50]
push dword [edi + 0x58]
call eax
mov cl, byte [edi + 0xe0]
add esp, 0x14
mov ebp, dword [esp + 0x2c]
mov ebx, dword [esp + 0x28]
mov byte [esp + 0x13], cl
test eax, eax
je 0x51fd24
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
mov dword [esp + 0x54], eax
jmp 0x51fd3c
mov edx, dword [esp + 0x8c]
mov eax, dword [esp + 0x88]
jmp 0x51fd5c
mov al, byte [esp + 0x13]
mov byte [esp + 0x13], al
mov eax, edx
mul dword [edi + 0x64]
push 0
push dword [edi + 0x68]
mov esi, eax
mov eax, dword [esp + 0x5c]
mul dword [edi + 0x64]
add esi, edx
push esi
push eax
call fcn.00560de0
mov cl, byte [esp + 0x13]
cmp ebp, edx
jb 0x51fd72
ja 0x51fd66
cmp ebx, eax
jbe 0x51fd72
mov ebx, eax
mov ebp, edx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebp
test cl, cl
je 0x51fdb9
cmp dword [esp + 0x3098], 0
je 0x51fdb5
push dword [edi + 0x18]
mov eax, ebp
mul dword [edi + 8]
mov ecx, eax
mov eax, ebx
mul dword [edi + 8]
add ecx, edx
push ecx
push eax
push dword [edi]
lea eax, [esp + 0xa0]
push dword [esp + 0x70]
push dword [edi + 0x5c]
push eax
call fcn.00537d50
add esp, 0x1c
lea ecx, [esp + 0x90]
jmp 0x51fdbd
xor ecx, ecx
jmp 0x51fdbd
mov ecx, dword [esp + 0x60]
lea ebx, [edi + 0x50]
test ebx, ebx
je 0x51ff31
mov eax, dword [ebx + 4]
test eax, eax
je 0x51ff21
mov eax, dword [eax + 0xc]
test eax, eax
je 0x51ff21
lea edx, [esp + 0x14]
push edx
lea edx, [esp + 0x1094]
push edx
lea edx, [esp + 0x30]
push edx
push ecx
push dword [ebx]
push dword [ebx + 8]
call eax
add esp, 0x18
test eax, eax
jne 0x51ff73
cmp dword [esp + 0x30a0], eax
je 0x51fe74
push dword [esp + 0x18]
cmp byte [edi + 0xe1], al
lea ebx, [esp + 0x2094]
push dword [esp + 0x18]
mov ebp, dword [esp + 0x78]
lea eax, [esp + 0x1098]
push eax
cmove ebx, ebp
lea eax, [edi + 0x20]
push ebx
push eax
call fcn.00513450
add esp, 0x14
test eax, eax
jne 0x51ff73
cmp byte [edi + 0xe1], al
je 0x51fe74
mov eax, dword [esp + 0x18]
mul dword [edi + 0x28]
push dword [edi + 0x18]
mov ecx, eax
mov eax, dword [esp + 0x18]
mul dword [edi + 0x28]
add ecx, edx
push ecx
push eax
push dword [edi + 0x20]
push ebx
push dword [edi + 4]
push ebp
call fcn.00537d50
add esp, 0x1c
mov ebp, dword [esp + 0x84]
add ebp, dword [esp + 0x28]
mov ebx, dword [esp + 0x6c]
adc ebx, dword [esp + 0x2c]
mov esi, dword [esp + 0x20]
add esi, dword [esp + 0x14]
mov ecx, dword [esp + 0x58]
adc ecx, dword [esp + 0x18]
mov dword [esp + 0x84], ebp
mov dword [esp + 0x6c], ebx
mov dword [esp + 0x20], esi
mov dword [esp + 0x58], ecx
cmp ebx, dword [esp + 0x64]
jb 0x51fed3
ja 0x51feb8
cmp ebp, dword [esp + 0x68]
jbe 0x51fed3
push 0xd5d6
push str.C:PureBasicSvn_v6.10LibrariesSoundMiniAudiominiaudiominiaudio.h
push str.framesProcessedIn___frameCountIn
call fcn.00587dd0
mov ecx, dword [esp + 0x64]
add esp, 0xc
cmp ecx, dword [esp + 0x30]
jb 0x51fefe
ja 0x51fee3
mov edx, dword [esp + 0x1c]
cmp esi, edx
jbe 0x51ff02
push 0xd5d7
push str.C:PureBasicSvn_v6.10LibrariesSoundMiniAudiominiaudiominiaudio.h
push str.framesProcessedOut___frameCountOut
call fcn.00587dd0
mov ecx, dword [esp + 0x64]
add esp, 0xc
mov edx, dword [esp + 0x1c]
mov eax, dword [esp + 0x14]
or eax, dword [esp + 0x18]
je 0x51ff51
cmp ecx, dword [esp + 0x30]
ja 0x51ff51
jb 0x51ff18
cmp esi, edx
jae 0x51ff51
mov edx, dword [esp + 0x6c]
jmp 0x51fb54
pop edi
pop esi
pop ebp
mov eax, 0xffffffe3
pop ebx
add esp, 0x3080
ret
pop edi
pop esi
pop ebp
mov eax, 0xfffffffe
pop ebx
add esp, 0x3080
ret
mov ebx, dword [esp + 0x24]
mov ebp, dword [esp + 0x20]
mov ecx, dword [esp + 0x74]
mov esi, dword [esp + 0x70]
mov eax, dword [esp + 0x309c]
test eax, eax
je 0x51ff61
mov dword [eax], ebp
mov dword [eax + 4], ebx
mov eax, dword [esp + 0x30a4]
test eax, eax
je 0x51ff71
mov dword [eax], esi
mov dword [eax + 4], ecx
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x3080
ret