Skip to content

Commit

Permalink
FMODAudioEngine fixed (not for VideoPlayer)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jouca committed Jun 4, 2024
1 parent 774ae6d commit 05c5eb9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/Notifications/EventsPush.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -710,8 +710,8 @@ bool EventsPush::init(sio::message::ptr const& data) {
nullptr
));

/*if (Mod::get()->getSettingValue<bool>("sfx") && type != 3 && type != 4) FMODAudioEngine::sharedEngine()->playEffect("crystal01.ogg");
if (Mod::get()->getSettingValue<bool>("sfx") && (type == 3 || type == 4)) FMODAudioEngine::sharedEngine()->playEffect("reward01.ogg");*/
if (Mod::get()->getSettingValue<bool>("sfx") && type != 3 && type != 4) FMODAudioEngine::sharedEngine()->playEffect("crystal01.ogg");
if (Mod::get()->getSettingValue<bool>("sfx") && (type == 3 || type == 4)) FMODAudioEngine::sharedEngine()->playEffect("reward01.ogg");

return true;
}
Expand Down
4 changes: 2 additions & 2 deletions src/Secret/VideoPlayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ namespace videoplayer {
};

void VideoPlayer::initAudio() {
/*FMODAudioEngine* engine = FMODAudioEngine::sharedEngine();
FMODAudioEngine* engine = FMODAudioEngine::sharedEngine();

int sampleRate = plm_get_samplerate(m_stream);

Expand All @@ -142,7 +142,7 @@ namespace videoplayer {
m_channel->setVolume(m_volume);

m_channel->setUserData(this);
if (m_loop) m_channel->setCallback(&VideoPlayer::audioCallback);*/
if (m_loop) m_channel->setCallback(&VideoPlayer::audioCallback);
}

FMOD_RESULT F_CALLBACK videoplayer::VideoPlayer::audioCallback(FMOD_CHANNELCONTROL *chanControl, FMOD_CHANNELCONTROL_TYPE controlType, FMOD_CHANNELCONTROL_CALLBACK_TYPE callbackType, void *commandData1, void *commandData2) {
Expand Down

0 comments on commit 05c5eb9

Please sign in to comment.