Skip to content

Commit

Permalink
Merge pull request #8046 from AlwinEsch/dsp-fixes
Browse files Browse the repository at this point in the history
[adsp] Several small fixes
  • Loading branch information
AlwinEsch committed Sep 14, 2015
2 parents b3f0fd1 + 56798ff commit 4ef6894
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 6 deletions.
4 changes: 2 additions & 2 deletions xbmc/Application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1209,7 +1209,7 @@ bool CApplication::Initialize()
uiInitializationFinished = firstWindow != WINDOW_STARTUP_ANIM;

CStereoscopicsManager::GetInstance().Initialize();
CApplicationMessenger::GetInstance().SendMsg(TMSG_SETAUDIODSPSTATE, ACTIVE_AE_DSP_STATE_ON); // send a blocking message to active AudioDSP engine
CApplicationMessenger::GetInstance().SendMsg(TMSG_SETAUDIODSPSTATE, ACTIVE_AE_DSP_STATE_ON, ACTIVE_AE_DSP_SYNC_ACTIVATE); // send a blocking message to active AudioDSP engine
}

}
Expand Down Expand Up @@ -1434,7 +1434,7 @@ void CApplication::OnSettingChanged(const CSetting *setting)
{
if (((CSettingBool *) setting)->GetValue())
{
CApplicationMessenger::GetInstance().PostMsg(TMSG_SETAUDIODSPSTATE, ACTIVE_AE_DSP_STATE_ON);
CApplicationMessenger::GetInstance().PostMsg(TMSG_SETAUDIODSPSTATE, ACTIVE_AE_DSP_STATE_ON, ACTIVE_AE_DSP_SYNC_ACTIVATE);
CApplicationMessenger::GetInstance().PostMsg(TMSG_MEDIA_RESTART); // send non blocking media restart message
}
else
Expand Down
2 changes: 1 addition & 1 deletion xbmc/cores/AudioEngine/DSPAddons/ActiveAEDSP.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ void CActiveAEDSP::OnApplicationMessage(KODI::MESSAGING::ThreadMessage* pMsg)
case TMSG_SETAUDIODSPSTATE:
if(pMsg->param1 == ACTIVE_AE_DSP_STATE_ON)
{
if(pMsg->param1 == ACTIVE_AE_DSP_ASYNC_ACTIVATE)
if(pMsg->param2 == ACTIVE_AE_DSP_ASYNC_ACTIVATE)
{
Activate(true);
}
Expand Down
3 changes: 2 additions & 1 deletion xbmc/cores/AudioEngine/DSPAddons/ActiveAEDSP.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@

#define ACTIVE_AE_DSP_STATE_ON 0
#define ACTIVE_AE_DSP_STATE_OFF 1
#define ACTIVE_AE_DSP_SYNC_ACTIVATE 0
#define ACTIVE_AE_DSP_ASYNC_ACTIVATE 1

extern "C" {
Expand Down Expand Up @@ -76,7 +77,7 @@ namespace ActiveAE
* @brief Stop the ActiveAEDSP and destroy all objects it created.
*/
virtual ~CActiveAEDSP();
//@{

/*!
* @brief Get the instance of the ActiveAEDSP.
* @return The ActiveAEDSP instance.
Expand Down
2 changes: 1 addition & 1 deletion xbmc/messaging/ApplicationMessenger.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@
#define TMSG_LOADPROFILE TMSG_MASK_APPLICATION + 27
#define TMSG_VIDEORESIZE TMSG_MASK_APPLICATION + 28

#define TMSG_SETAUDIODSPSTATE TMSG_MASK_AUDIO_DSP + 30
#define TMSG_SETAUDIODSPSTATE TMSG_MASK_AUDIO_DSP + 0

#define TMSG_GUI_INFOLABEL TMSG_MASK_GUIINFOMANAGER + 0
#define TMSG_GUI_INFOBOOL TMSG_MASK_GUIINFOMANAGER + 1
Expand Down
2 changes: 1 addition & 1 deletion xbmc/windows/GUIWindowLoginScreen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ void CGUIWindowLoginScreen::LoadProfile(unsigned int profile)
CStereoscopicsManager::GetInstance().Initialize();

// start audio DSP related services with a blocking message
CApplicationMessenger::GetInstance().SendMsg(TMSG_SETAUDIODSPSTATE, ACTIVE_AE_DSP_STATE_ON);
CApplicationMessenger::GetInstance().SendMsg(TMSG_SETAUDIODSPSTATE, ACTIVE_AE_DSP_STATE_ON, ACTIVE_AE_DSP_SYNC_ACTIVATE);

// if the user interfaces has been fully initialized let everyone know
if (uiInitializationFinished)
Expand Down

0 comments on commit 4ef6894

Please sign in to comment.