0
0

First of all it compliments for the product, I am studying it from little days but he is indeed excellent, also for your support.
Sorry for my bad enghish,im italian:
I have create a addon plugin for a simulation game third part and release it, that it play voices (.wav), one to the time(in pooling) , I determine moments to you, but now I would want to use of the advance characteristics for the fmod sounds.
My plugin work in loop( i have no control here) ,received a list of values.. I am within a while cycle and receive informations, in the previous version I used to put all events names into a stack that i will play. After I used a method that once that a file.wav, was reproduced removes list and attends that is free the channel in order to reproduce other messages in tail, if there is a another file in playng play function return -1 for dont remove this file from stack … I would to understand as to be able to implement this with fmod,i think that i do not use NON_BLOCKING… the files do not large of 500k at 44000 Khz.
I try using the example ,check if my channel isplaying but i dont know if now i ply the new file or the next file in pool.
Thanks for any help…

do{ //do while of third part game

if (//)
Stack.s.put("msg1.wav");
if (//)
Stack.s.put("msg2.wav");

stack.listen();
}

void listen(){

if ( play(s.top()) == 0){
s.pop();
}//else do nothing and wait that not play for create a new sound

fmod:

int play(string filename){

result = system->createSound(filename.c:str(), FMOD_DEFAULT, 0, &sound);
result = system->playSound(FMOD_CHANNEL_FREE, sound, false, &channel);
}

  • You must to post comments
Showing 0 results
Your Answer

Please first to submit.