I updated fmodex and now my player no longer loads/plays music when using unicode. Is there anything I must consider when updating to the following (affected) versions:
I tried a bit with the examples to reproduce but end up with all kinds of errors, e.g.
FMOD error! (56) Error initializing output device, but more specifically, the output device is already in use and cannot be reused.
when using FMOD_System_PlaySound.
did the assembly application, and while testing I discovered this:
it works eg. when filename is
but failed if using the full path: Z:\Unicode\Test.ogg
anyway, the file for testing:
includes full version with some console output, and a extreme small one just playing the sound.
supports both unicode and ansi, of course (ansi on win9x, and always uses unicode on NT series)
source included (best look for PlayItNow in FModPlay_Console_Extreme.fasm – its pretty small anyway)
Ah, key piece of information "Z:\Unicode\Test.ogg" doesn’t work, my tests used the format "/Unicode/Test.ogg". I see what is going on, easy fix, sorry for the long delay on this problem.
This will be fixed for our next release, should be out by the end of the week.
k, now did a clean approach on VB6 playstream example;
log files / project:
http://www.ctuser.net/_files/playstream … _425xx.zip
Public Declare Function FMOD_System_CreateSoundEx Lib "fmodex.dll" Alias "FMOD_System_CreateSound" (ByVal system As Long, Name_or_data As Any, ByVal Mode As FMOD_MODE, ByRef exinfo As FMOD_CREATESOUNDEXINFO, ByRef Sound As Long) As FMOD_RESULT
Public Function FMOD_System_CreateStream(ByVal system As Long, ByVal Name_or_data As String, ByVal Mode As FMOD_MODE, ByRef Sound As Long, Optional ByVal UseUnicode As Boolean = False) As FMOD_RESULT
Dim exinfo As FMOD_CREATESOUNDEXINFO
Dim result As FMOD_RESULT
Dim xByteA1() As Byte
Dim xLong1 As Long
exinfo.cbsize = LenB(exinfo) If UseUnicode Then xLong1 = Len(Name_or_data) * 2& ReDim xByteA1(xLong1 + 1&) Call CopyMemory(xByteA1(0), ByVal StrPtr(Name_or_data), xLong1) Debug.Print Hex(Mode Or FMOD_CREATESTREAM Or FMOD_UNICODE) Stop result = FMOD_System_CreateSoundEx(system, xByteA1(0), Mode Or FMOD_CREATESTREAM Or FMOD_UNICODE, exinfo, Sound) Else result = FMOD_System_CreateSoundEx(system, ByVal Name_or_data, Mode Or FMOD_CREATESTREAM, exinfo, Sound) End If FMOD_System_CreateStream = result
Please login first to submit.