Skip to content

Commit

Permalink
Use g_want_determinism more
Browse files Browse the repository at this point in the history
  • Loading branch information
JosJuice committed Jul 5, 2016
1 parent 69bf05b commit caa6f75
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 11 deletions.
3 changes: 1 addition & 2 deletions Source/Core/Core/Core.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -976,8 +976,7 @@ void UpdateWantDeterminism(bool initial)
// For now, this value is not itself configurable. Instead, individual
// settings that depend on it, such as GPU determinism mode. should have
// override options for testing,
bool new_want_determinism =
Movie::IsPlayingInput() || Movie::IsRecordingInput() || NetPlay::IsNetPlayRunning();
bool new_want_determinism = Movie::IsMovieActive() || NetPlay::IsNetPlayRunning();
if (new_want_determinism != g_want_determinism || initial)
{
WARN_LOG(COMMON, "Want determinism <- %s", new_want_determinism ? "true" : "false");
Expand Down
9 changes: 3 additions & 6 deletions Source/Core/Core/HW/DSPLLE/DSPLLE.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -166,11 +166,9 @@ bool DSPLLE::Initialize(bool bWii, bool bDSPThread)
return false;

// needs to be after DSPCore_Init for the dspjit ptr
if (NetPlay::IsNetPlayRunning() || Movie::IsMovieActive() || Core::g_want_determinism ||
!g_dsp_jit)
{
if (Core::g_want_determinism || !g_dsp_jit)
bDSPThread = false;
}

m_bWii = bWii;
m_bDSPThread = bDSPThread;

Expand Down Expand Up @@ -310,8 +308,7 @@ void DSPLLE::DSP_Update(int cycles)
*/
if (m_bDSPThread)
{
if (requestDisableThread || NetPlay::IsNetPlayRunning() || Movie::IsMovieActive() ||
Core::g_want_determinism)
if (requestDisableThread || Core::g_want_determinism)
{
DSP_StopSoundStream();
m_bDSPThread = false;
Expand Down
2 changes: 2 additions & 0 deletions Source/Core/Core/HW/EXI_DeviceIPL.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

#include <cstring>

#include "Common/Assert.h"
#include "Common/ChunkFile.h"
#include "Common/CommonPaths.h"
#include "Common/CommonTypes.h"
Expand Down Expand Up @@ -421,6 +422,7 @@ u32 CEXIIPL::GetGCTime()
}
else
{
_assert_(!Core::g_want_determinism);
ltime = Common::Timer::GetLocalTimeSinceJan1970();
}

Expand Down
2 changes: 1 addition & 1 deletion Source/Core/DolphinWX/Config/ConfigMain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ void CConfigMain::CreateGUIControls()
Notebook->AddPage(wii_pane, _("Wii"));
Notebook->AddPage(path_pane, _("Paths"));
Notebook->AddPage(advanced_pane, _("Advanced"));
if (Movie::IsMovieActive() || NetPlay::IsNetPlayRunning())
if (Core::g_want_determinism)
advanced_pane->Disable();

wxBoxSizer* const main_sizer = new wxBoxSizer(wxVERTICAL);
Expand Down
4 changes: 2 additions & 2 deletions Source/Core/DolphinWX/ControllerConfigDiag.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ wxStaticBoxSizer* ControllerConfigDiag::CreateGamecubeSizer()
pad_type_choices[i]->Bind(wxEVT_CHOICE, &ControllerConfigDiag::OnGameCubePortChanged, this);

// Disable controller type selection for certain circumstances.
if (NetPlay::IsNetPlayRunning() || Movie::IsMovieActive())
if (Core::g_want_determinism)
pad_type_choices[i]->Disable();

// Set the saved pad type as the default choice.
Expand Down Expand Up @@ -179,7 +179,7 @@ wxStaticBoxSizer* ControllerConfigDiag::CreateWiimoteConfigSizer()
// Disable controller type selection for certain circumstances.
bool wii_game_started =
SConfig::GetInstance().bWii || Core::GetState() == Core::CORE_UNINITIALIZED;
if (NetPlay::IsNetPlayRunning() || Movie::IsMovieActive() || !wii_game_started)
if (Core::g_want_determinism || !wii_game_started)
wiimote_source_ch[i]->Disable();

m_orig_wiimote_sources[i] = g_wiimote_sources[i];
Expand Down

0 comments on commit caa6f75

Please sign in to comment.