0
0

Hi!
Please run the code following, sometimes the sound will be broken when Channel::setPosition is called. There’s no problems in FMOD3 in same situation when FSOUND_Stream_SetPosition is called.
Thanks

include "fmod.hpp"

include "stdlib.h"

include "stdio.h"

include "conio.h"

using namespace FMOD;

void main()
{
System *system;
System_Create(&system);
system->init(10, FMOD_INIT_NORMAL, 0);
Sound *sound;
system->createSound("E:\mp3\z.mp3", FMOD_2D | FMOD_SOFTWARE | FMOD_CREATESTREAM, 0, &sound);
unsigned int len;
sound->getLength(&len, FMOD_TIMEUNIT_MS);
Channel *channel;
system->playSound(FMOD_CHANNEL_FREE, sound, false, &channel);
printf("press q to quit\n");
while(_getch()!=’q’)
{
int pos = len * rand() / RAND_MAX / 2;
channel->setPosition(pos, FMOD_TIMEUNIT_MS);
}
}

  • You must to post comments
0
0

oh, it seems that this bug is fixed in version 4.08.09

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.