Calling setReverbProperties on default master channel group with non-zero wet level causes stack overflow in update method. Tested on version 1.05.02.
Code sample:
#include <cassert>
#include <fmod.hpp>
#include <thread>
int main()
{
FMOD_RESULT fmod_result = FMOD_OK;
FMOD::System* system = nullptr;
fmod_result = FMOD::System_Create(&system);
assert(fmod_result == FMOD_OK);
unsigned int version = 0;
fmod_result = system->getVersion(&version);
assert(fmod_result == FMOD_OK);
assert(version >= FMOD_VERSION);
fmod_result = system->init(32, FMOD_INIT_NORMAL, nullptr);
assert(fmod_result == FMOD_OK);
FMOD::ChannelGroup* master_channel_group = nullptr;
fmod_result = system->getMasterChannelGroup(&master_channel_group);
assert(fmod_result == FMOD_OK);
FMOD::Sound* sound = nullptr;
fmod_result = system->createSound(
"some_sound.wav",
FMOD_2D | FMOD_LOOP_NORMAL,
nullptr,
&sound);
assert(fmod_result == FMOD_OK);
FMOD_REVERB_PROPERTIES reverb = FMOD_PRESET_SEWERPIPE;
fmod_result = system->setReverbProperties(0, &reverb);
assert(fmod_result == FMOD_OK);
fmod_result = master_channel_group->setReverbProperties(0, 0.5F);
assert(fmod_result == FMOD_OK);
FMOD::Channel* channel = nullptr;
fmod_result = system->playSound(
sound, master_channel_group, false, &channel);
std::chrono::milliseconds delay(100);
while (true) {
fmod_result = system->update();
assert(fmod_result == FMOD_OK);
std::this_thread::sleep_for(delay);
}
return 0;
}