0.9.4+: separated two lag reduction options and changed the category name in INI
0.9.4+: disabled frameskip during avi recording
This commit is contained in:
parent
a7ac71efee
commit
276735a606
|
@ -1675,7 +1675,12 @@ void NDS_Sleep() { nds.sleeping = TRUE; }
|
|||
bool SkipCur2DFrame = false, SkipNext2DFrame = false;
|
||||
bool SkipCur3DFrame = false;
|
||||
|
||||
void NDS_SkipNextFrame() { SkipNext2DFrame = true; SkipCur3DFrame = true; }
|
||||
void NDS_SkipNextFrame() {
|
||||
if (!driver->AVI_IsRecording()) {
|
||||
SkipNext2DFrame = true;
|
||||
SkipCur3DFrame = true;
|
||||
}
|
||||
}
|
||||
|
||||
#define INDEX(i) ((((i)>>16)&0xFF0)|(((i)>>4)&0xF))
|
||||
|
||||
|
|
|
@ -383,6 +383,8 @@ extern struct TCommonSettings {
|
|||
, spuAdpcmCache(false)
|
||||
, gfx3d_flushMode(0)
|
||||
, manualBackupType(0)
|
||||
, armFixCycleCount(false)
|
||||
, armFastFetchExecute(false)
|
||||
{
|
||||
strcpy(ARM9BIOS, "biosnds9.bin");
|
||||
strcpy(ARM7BIOS, "biosnds7.bin");
|
||||
|
@ -414,6 +416,9 @@ extern struct TCommonSettings {
|
|||
//this is the user's choice of manual backup type, for cases when the autodetection can't be trusted
|
||||
int manualBackupType;
|
||||
|
||||
bool armFixCycleCount;
|
||||
bool armFastFetchExecute;
|
||||
|
||||
bool spu_muteChannels[16];
|
||||
|
||||
struct _ShowGpu {
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
#include "bios.h"
|
||||
#include "debug.h"
|
||||
#include "Disassembler.h"
|
||||
|
||||
#include "NDSSystem.h"
|
||||
|
||||
template<u32> static u32 armcpu_prefetch();
|
||||
|
||||
|
@ -494,12 +494,10 @@ armcpu_flagIrq( armcpu_t *armcpu) {
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
bool fixCycleCount = false;
|
||||
|
||||
template<int PROCNUM>
|
||||
u32 armcpu_exec()
|
||||
{
|
||||
u32 cFetch = fixCycleCount ? 0 : 1;
|
||||
u32 cFetch = CommonSettings.armFixCycleCount ? 0 : 1;
|
||||
u32 cExecute = 0;
|
||||
|
||||
//this assert is annoying. but sometimes it is handy.
|
||||
|
@ -536,7 +534,7 @@ u32 armcpu_exec()
|
|||
else
|
||||
cExecute += arm_instructions_set_1[INSTRUCTION_INDEX(ARMPROC.instruction)]();
|
||||
}
|
||||
else if (fixCycleCount)
|
||||
else if (CommonSettings.armFixCycleCount)
|
||||
cExecute++; // If condition=false: 1S cycle
|
||||
#ifdef GDB_STUB
|
||||
if ( ARMPROC.post_ex_fn != NULL) {
|
||||
|
@ -546,7 +544,7 @@ u32 armcpu_exec()
|
|||
#else
|
||||
cFetch += armcpu_prefetch<PROCNUM>();
|
||||
#endif
|
||||
return fixCycleCount ? std::max(cFetch, cExecute) : (cFetch + cExecute);
|
||||
return CommonSettings.armFastFetchExecute ? std::max(cFetch, cExecute) : (cFetch + cExecute);
|
||||
}
|
||||
|
||||
if(PROCNUM==0)
|
||||
|
@ -562,7 +560,7 @@ u32 armcpu_exec()
|
|||
#else
|
||||
cFetch += armcpu_prefetch<PROCNUM>();
|
||||
#endif
|
||||
return fixCycleCount ? std::max(cFetch, cExecute) : (cFetch + cExecute);
|
||||
return CommonSettings.armFastFetchExecute ? std::max(cFetch, cExecute) : (cFetch + cExecute);
|
||||
}
|
||||
|
||||
//these templates needed to be instantiated manually
|
||||
|
|
|
@ -140,8 +140,6 @@ void wxTest() {
|
|||
|
||||
#endif
|
||||
|
||||
extern bool fixCycleCount;
|
||||
|
||||
const int kGapNone = 0;
|
||||
const int kGapBorder = 5;
|
||||
const int kGapNDS = 64; // extremely tilted (but some games seem to use this value)
|
||||
|
@ -1511,7 +1509,8 @@ int _main()
|
|||
GetPrivateProfileString("Watches", str, "", &rw_recent_files[i][0], 1024, IniName);
|
||||
}
|
||||
|
||||
fixCycleCount = (bool)GetPrivateProfileInt("Timings", "LagReduction", 0, IniName) != 0;
|
||||
CommonSettings.armFixCycleCount = (bool)GetPrivateProfileInt("0.9.4+", "armFixCycleCount", 0, IniName) != 0;
|
||||
CommonSettings.armFastFetchExecute = (bool)GetPrivateProfileInt("0.9.4+", "armFastFetchExecute", 0, IniName) != 0;
|
||||
|
||||
//i think we should override the ini file with anything from the commandline
|
||||
CommandLine cmdline;
|
||||
|
@ -2561,7 +2560,7 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM
|
|||
//Gray the recent ROM menu item if there are no recent ROMs
|
||||
DesEnableMenuItem(mainMenu, ID_FILE_RECENTROM, RecentRoms.size()>0);
|
||||
|
||||
DesEnableMenuItem(mainMenu, IDC_LAGREDUCTION, (movieMode == MOVIEMODE_INACTIVE));
|
||||
DesEnableMenuItem(mainMenu, IDC_ARMFIXCYCLECOUNT, (movieMode == MOVIEMODE_INACTIVE));
|
||||
|
||||
//Updated Checked menu items
|
||||
|
||||
|
@ -2630,7 +2629,8 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM
|
|||
MainWindow->checkMenu(IDC_STATEREWINDING, staterewindingenabled == 1 );
|
||||
|
||||
MainWindow->checkMenu(IDC_BACKGROUNDPAUSE, lostFocusPause);
|
||||
MainWindow->checkMenu(IDC_LAGREDUCTION, fixCycleCount);
|
||||
MainWindow->checkMenu(IDC_ARMFIXCYCLECOUNT, CommonSettings.armFixCycleCount);
|
||||
MainWindow->checkMenu(IDC_ARMFASTFETCHEXECUTE, CommonSettings.armFastFetchExecute);
|
||||
|
||||
//Save type
|
||||
const int savelist[] = {IDC_SAVETYPE1,IDC_SAVETYPE2,IDC_SAVETYPE3,IDC_SAVETYPE4,IDC_SAVETYPE5,IDC_SAVETYPE6,IDC_SAVETYPE7};
|
||||
|
@ -2692,7 +2692,8 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM
|
|||
WritePrivateProfileString("Watches", str, &rw_recent_files[i][0], IniName);
|
||||
}
|
||||
|
||||
WritePrivateProfileInt("Timings", "LagReduction", (int)fixCycleCount, IniName);
|
||||
WritePrivateProfileInt("0.9.4+", "armFixCycleCount", (int)CommonSettings.armFixCycleCount, IniName);
|
||||
WritePrivateProfileInt("0.9.4+", "armFastFetchExecute", (int)CommonSettings.armFastFetchExecute, IniName);
|
||||
|
||||
ExitRunLoop();
|
||||
}
|
||||
|
@ -3536,9 +3537,14 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM
|
|||
WritePrivateProfileInt("Focus", "BackgroundPause", (int)lostFocusPause, IniName);
|
||||
return 0;
|
||||
|
||||
case IDC_LAGREDUCTION:
|
||||
fixCycleCount = !fixCycleCount;
|
||||
WritePrivateProfileInt("Timings", "LagReduction", (int)fixCycleCount, IniName);
|
||||
case IDC_ARMFIXCYCLECOUNT:
|
||||
CommonSettings.armFixCycleCount = !CommonSettings.armFixCycleCount;
|
||||
WritePrivateProfileInt("0.9.4+", "armFixCycleCount", (int)CommonSettings.armFixCycleCount, IniName);
|
||||
return 0;
|
||||
|
||||
case IDC_ARMFASTFETCHEXECUTE:
|
||||
CommonSettings.armFastFetchExecute = !CommonSettings.armFastFetchExecute;
|
||||
WritePrivateProfileInt("0.9.4+", "armFastFetchExecute", (int)CommonSettings.armFastFetchExecute, IniName);
|
||||
return 0;
|
||||
|
||||
case IDC_SAVETYPE1: backup_setManualBackupType(0); return 0;
|
||||
|
|
|
@ -794,7 +794,8 @@
|
|||
#define IDC_HKCOMBO 60077
|
||||
#define IDD_KEYCUSTOM 60078
|
||||
#define IDM_HOTKEY_CONFIG 60079
|
||||
#define IDC_LAGREDUCTION 65432
|
||||
#define IDC_ARMFIXCYCLECOUNT 65432
|
||||
#define IDC_ARMFASTFETCHEXECUTE 65433
|
||||
|
||||
// Next default values for new objects
|
||||
//
|
||||
|
|
Binary file not shown.
Loading…
Reference in New Issue