Edit: It doesn’t start because the openstate keeps “LOADING” and doesn’t change
Edit2: You can manually start it after a certain time!
Now I think that there is an error in the timer-code!
here it is:
[code:tvtm22u9] Dim result As FMOD_RESULT
Dim starving As Long
If sound Then Dim openstate As FMOD_OPENSTATE result = FMOD_Sound_GetOpenState(sound, openstate, Percent, starving) ERRCHECK (result) If (openstate = FMOD_OPENSTATE_READY) And channel = 0 Then sPlay Label1.Caption = "spielen" ElseIf openstate = FMOD_OPENSTATE_LOADING Then Label1.Caption = "laden" ElseIf openstate = FMOD_OPENSTATE_BUFFERING Then Label1.Caption = "buffern" End If End If If system Then Call FMOD_System_Update(system) End If
whats wrong there?
I’m playing an audio-file with:
result=FMOD_System_CreateSound(system, sFile, (FMOD_HARDWARE Or FMOD_2D Or FMOD_CREATESTREAM Or FMOD_NONBLOCKING), sound)
And in a Timer if Openstate=Ready
[code:tvtm22u9]result=FMOD_System_PlaySound(system, FMOD_CHANNEL_FREE, sound, 0, channel)[/code:tvtm22u9]
On the first time of playing with using this function the Sound starts, but if I stop it like this:
result = FMOD_Sound_Release(sound)
and then play it again(or another audio-file) with the function on top, it doesn’t start playing!
I hope you can help me and understand my bad English!
- Tominator asked 11 years ago
- You must login to post comments