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

Disassembly:
sub esp, 0x138
push ebx
push ebp
mov ebp, dword [esp + 0x150]
push esi
push edi
mov ecx, 0x12
xor eax, eax
lea edi, [esp + 0x14]
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x154]
lea ecx, [esp + 0x14]
push 1
and eax, 0xffff
push ecx
push ebp
mov dword [esp + 0x20], 0x48
mov dword [esp + 0x28], eax
call sub.MSACM32.dll_acmFormatTagDetailsA
test eax, eax
je 0x4013a7
lea edx, [esp + 0x2c]
push str._Unavailable_
push edx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov eax, dword [esp + 0x20]
cmp eax, 0x12
jae 0x4013b5
mov eax, 0x12
mov esi, dword [esp + 0x150]
mov ebx, dword [sym.imp.KERNEL32.dll_VirtualAlloc]
push 4
push 0x1000
push eax
push 0
mov dword [esi + 0x18], eax
call ebx
mov edi, eax
test edi, edi
mov dword [esi + 0xc], edi
jne 0x4013f4
push eax
push str.Enable_To_Allocate_Memory_For_Format_Details
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov ecx, dword [esi + 0x18]
xor eax, eax
mov edx, ecx
push 0x10000
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov eax, dword [esi + 0xc]
mov cx, word [esp + 0x158]
mov word [eax], cx
mov edx, dword [esp + 0x24]
mov eax, dword [esi + 0xc]
mov ecx, dword [esi + 8]
push edx
push eax
push ecx
push ebp
call sub.MSACM32.dll_acmFormatSuggest
test eax, eax
je 0x40144c
push 0
push str.Unable_To_Suggest_Format..._Aborting_Conversion
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov edx, dword [esp + 0x1c]
mov ecx, 0x26
xor eax, eax
lea edi, [esp + 0xb0]
rep stosd dword es:[edi], eax
mov eax, dword [esi + 0xc]
mov ecx, dword [esi + 0x18]
mov dword [esp + 0xb8], edx
lea edx, [esp + 0xb0]
push 1
push edx
push ebp
mov dword [esp + 0xbc], 0x98
mov dword [esp + 0xcc], eax
mov dword [esp + 0xd0], ecx
call sub.MSACM32.dll_acmFormatDetailsA
test eax, eax
je 0x4014ad
lea eax, [esp + 0xc8]
push str._Unavailable_
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov edx, dword [0x408b60]
lea ecx, [esp + 0xc8]
push ecx
push 0x3f3
push edx
call dword [sym.imp.USER32.dll_SetDlgItemTextA]
mov eax, dword [0x408b60]
push eax
call dword [sym.imp.USER32.dll_UpdateWindow]
mov ecx, dword [esi + 0xc]
mov edx, dword [esi + 8]
push 4
push 0
push 0
push 0
push ecx
lea edi, [esi + 0x28]
push edx
push ebp
push edi
call sub.MSACM32.dll_acmStreamOpen
test eax, eax
je 0x40150c
push 0
push str.Unable_To_Open_Conversion_Stream
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
xor eax, eax
push 0x10
mov dword [0x408be0], eax
mov dword [0x408be0], 0x61746164
mov dword [0x408be4], eax
push 0x408c28
mov dword [0x408be8], eax
push 0x408be0
mov dword [0x408bec], eax
mov dword [0x408bf0], eax
mov ecx, dword [esi]
push ecx
call dword [sym.imp.WINMM.dll_mmioDescend]
test eax, eax
je 0x401565
push 0
push str.Unable_To_Find_WAV_DATA_Chunk
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov ecx, dword [edi]
mov edx, dword [0x408be4]
xor ebp, ebp
lea eax, [esi + 0x44]
push ebp
push eax
mov eax, dword [esi + 0x3c]
mov dword [esi + 0x48], edx
push eax
push ecx
call sub.MSACM32.dll_acmStreamSize
test eax, eax
je 0x40159f
push ebp
push str.Unable_To_Get_Output_Buffer_Size
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov edx, dword [esi + 0x3c]
push 4
push 0x1000
push edx
push ebp
call ebx
cmp eax, ebp
mov dword [esi + 0x30], eax
jne 0x4015ce
push ebp
push str.Unable_To_Alloc_Source_Buffer_Memory
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov eax, dword [esi + 0x44]
push 4
push 0x1000
push eax
push ebp
call ebx
cmp eax, ebp
mov dword [esi + 0x34], eax
jne 0x4015fd
push ebp
push str.Unable_To_Alloc_Destination_Buffer_Memory
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov ecx, dword [esp + 0x14c]
push 0x11011
push ebp
push ecx
mov dword [esp + 0x1c], ebp
call dword [sym.imp.WINMM.dll_mmioOpenA]
cmp eax, ebp
mov dword [esi + 4], eax
je 0x401794
xor edx, edx
mov edi, dword [sym.imp.WINMM.dll_mmioCreateChunk]
mov dword [0x408b78], edx
push 0x20
mov dword [0x408b7c], edx
mov dword [0x408b7c], ebp
mov dword [0x408b80], edx
mov dword [0x408b80], 0x45564157
mov dword [0x408b84], edx
push 0x408b78
mov dword [0x408b88], edx
mov eax, dword [esi + 4]
push eax
call edi
test eax, eax
push ebp
je 0x401681
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov ecx, dword [esi + 4]
mov ebx, dword [sym.imp.WINMM.dll_mmioAscend]
push 0x408b78
push ecx
call ebx
test eax, eax
je 0x4016b0
push ebp
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov edx, dword [esp + 0x20]
mov dword [0x408c10], 0x20746d66
mov dword [0x408c14], edx
mov eax, dword [esi + 4]
push ebp
push 0x408c10
push eax
call edi
test eax, eax
je 0x4016ee
push ebp
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov ecx, dword [esp + 0x20]
mov edx, dword [esi + 0xc]
mov eax, dword [esi + 4]
push ecx
push edx
push eax
call dword [sym.imp.WINMM.dll_mmioWrite]
mov ecx, dword [esp + 0x20]
push ebp
cmp eax, ecx
je 0x401723
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov ecx, dword [esi + 4]
push 0x408c10
push ecx
call ebx
test eax, eax
je 0x40174c
push ebp
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov edx, dword [esp + 0x20]
mov dword [0x408c10], 0x61746164
mov dword [0x408c14], ebp
mov eax, dword [esi + 4]
push ebp
push 0x408c10
push eax
lea ebx, [edx + 4]
call edi
test eax, eax
je 0x40178d
push ebp
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
add ebx, 4
mov dword [esp + 0x10], ebx
mov ecx, dword [0x408b60]
mov edi, dword [sym.imp.USER32.dll_SendDlgItemMessageA]
push 0x640000
push ebp
push 0x401
push 0x3ed
push ecx
call edi
mov edx, dword [0x408b60]
push 0
push 1
push 0x404
push 0x3ed
push edx
call edi
mov edx, dword [esi + 0x44]
mov ecx, 0x15
xor eax, eax
lea edi, [esp + 0x5c]
rep stosd dword es:[edi], eax
mov ecx, dword [esi + 0x30]
mov eax, dword [esi + 0x3c]
mov dword [esp + 0x68], ecx
xor ebp, ebp
mov dword [esp + 0x7c], edx
mov edx, dword [esi + 0x28]
lea ecx, [esp + 0x5c]
mov dword [esp + 0x6c], eax
mov eax, dword [esi + 0x34]
push ebp
push ecx
push edx
mov dword [esp + 0x68], 0x54
mov dword [esp + 0x84], eax
call sub.MSACM32.dll_acmStreamPrepareHeader
test eax, eax
jne 0x401a6f
mov eax, dword [esi + 0x48]
xor ebx, ebx
test eax, eax
jbe 0x4018b8
mov edi, dword [esi + 0x3c]
sub eax, ebx
cmp edi, eax
jb 0x40182f
mov edi, eax
mov eax, dword [esi + 0x30]
mov ecx, dword [esi]
push edi
push eax
push ecx
call dword [sym.imp.WINMM.dll_mmioRead]
cmp eax, edi
jne 0x40193f
mov eax, dword [esi + 0x28]
lea edx, [esp + 0x5c]
push 4
push edx
push eax
mov dword [esp + 0x78], edi
mov dword [esp + 0x8c], 0
call sub.MSACM32.dll_acmStreamConvert
test eax, eax
jne 0x40195a
sub edi, dword [esp + 0x70]
je 0x401880
mov ecx, dword [esi]
push 1
neg edi
push edi
push ecx
call dword [sym.imp.WINMM.dll_mmioSeek]
mov eax, dword [esp + 0x70]
mov edx, dword [esp + 0x80]
mov ecx, dword [esi + 4]
add ebx, eax
mov eax, dword [esi + 0x34]
push edx
push eax
push ecx
call dword [sym.imp.WINMM.dll_mmioWrite]
mov ecx, dword [esp + 0x80]
cmp eax, ecx
jne 0x401975
mov eax, dword [esi + 0x48]
add ebp, ecx
cmp ebx, eax
jb 0x401824
mov eax, dword [esi + 0x28]
lea edx, [esp + 0x5c]
push 0
push edx
push eax
call sub.MSACM32.dll_acmStreamUnprepareHeader
mov ecx, dword [esi + 4]
push 0
push 0
push ecx
call dword [sym.imp.WINMM.dll_mmioSeek]
mov eax, dword [esp + 0x10]
xor edx, edx
mov dword [0x408b78], edx
mov edi, dword [sym.imp.WINMM.dll_mmioCreateChunk]
mov dword [0x408b7c], edx
lea ecx, [eax + ebp]
mov dword [0x408b80], edx
mov dword [0x408b80], 0x45564157
mov dword [0x408b84], edx
mov dword [0x408b7c], ecx
mov dword [0x408b88], edx
mov edx, dword [esi + 4]
push 0x20
push 0x408b78
push edx
call edi
test eax, eax
je 0x401990
push 0
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
push 0
push str.Unable_To_Read_In_DATA_For_Conversion
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
push 0
push str.Unable_To_Convert_Stream_At_Position
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
push 0
push str.Unable_To_Save_Out_MP3_Data
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov eax, dword [esp + 0x20]
mov dword [0x408c10], 0x20746d66
mov dword [0x408c14], eax
mov ecx, dword [esi + 4]
push 0
push 0x408c10
push ecx
call edi
test eax, eax
je 0x4019cf
push 0
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov edx, dword [esp + 0x20]
mov eax, dword [esi + 0xc]
mov ecx, dword [esi + 4]
push edx
push eax
push ecx
call dword [sym.imp.WINMM.dll_mmioWrite]
mov ecx, dword [esp + 0x20]
push 0
cmp eax, ecx
je 0x401a05
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov edx, dword [esi + 4]
push 0x408c10
push edx
call dword [sym.imp.WINMM.dll_mmioAscend]
test eax, eax
je 0x401a33
push 0
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
mov dword [0x408c10], 0x61746164
mov dword [0x408c14], ebp
mov eax, dword [esi + 4]
push 0
push 0x408c10
push eax
call edi
test eax, eax
je 0x401a6f
push 0
push str.Unable_To_Create_Destination_File
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret
push 1
push str.Conversion_Complete
push esi
call fcn.004012f0
add esp, 0xc
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x138
ret