Add an option to enable performance queries in gameini files, disable it by default
This commit is contained in:
parent
ffdd79df36
commit
26f58e1ba5
|
@ -1,3 +1,9 @@
|
|||
#include "PerfQueryBase.h"
|
||||
#include "VideoConfig.h"
|
||||
|
||||
PerfQueryBase* g_perf_query = 0;
|
||||
|
||||
bool PerfQueryBase::ShouldEmulate() const
|
||||
{
|
||||
return g_ActiveConfig.bPerfQueriesEnable;
|
||||
}
|
||||
|
|
|
@ -25,9 +25,12 @@ enum PerfQueryGroup
|
|||
class PerfQueryBase
|
||||
{
|
||||
public:
|
||||
PerfQueryBase() {};
|
||||
PerfQueryBase() {}
|
||||
virtual ~PerfQueryBase() {}
|
||||
|
||||
// Checks if performance queries are enabled in the gameini configuration.
|
||||
bool ShouldEmulate() const;
|
||||
|
||||
// Begin querying the specified value for the following host GPU commands
|
||||
virtual void EnableQuery(PerfQueryGroup type) {}
|
||||
|
||||
|
|
|
@ -181,6 +181,7 @@ void VideoConfig::GameIniLoad(const char *ini_file)
|
|||
iniFile.GetIfExists("Video", "PH_ZFar", &sPhackvalue[1]);
|
||||
iniFile.GetIfExists("Video", "ZTPSpeedupHack", &bZTPSpeedHack);
|
||||
iniFile.GetIfExists("Video", "UseBBox", &bUseBBox);
|
||||
iniFile.GetIfExists("Video", "PerfQueriesEnable", &bPerfQueriesEnable);
|
||||
}
|
||||
|
||||
void VideoConfig::VerifyValidity()
|
||||
|
|
|
@ -108,6 +108,7 @@ struct VideoConfig
|
|||
// Hacks
|
||||
bool bEFBAccessEnable;
|
||||
bool bDlistCachingEnable;
|
||||
bool bPerfQueriesEnable;
|
||||
|
||||
bool bEFBCopyEnable;
|
||||
bool bEFBCopyCacheEnable;
|
||||
|
|
Loading…
Reference in New Issue