Add configuration system for core renderdoc module

* This allows persistent config storage and registering tweak variables that
  works independent of the UI's configuration.
* Config vars can be debug only, which means they will be compiled out in stable
  version releases. This allows for debug-logging tweaks that are available in
  all builds (including nightly builds) for diagnostic purposes, but have zero
  overhead in stable releases.
* Variables have a loose hierarchy defined with _ or . to separate nodes.
This commit is contained in:
baldurk
2020-03-18 17:34:59 +00:00
parent c0e84875f3
commit d408f77241
41 changed files with 2123 additions and 322 deletions
+11 -2
View File
@@ -24,9 +24,18 @@
#include "common/formatting.h"
#include "core/core.h"
#include "core/settings.h"
#include "strings/string_utils.h"
#include "android_utils.h"
RDOC_CONFIG(rdcstr, Android_SDKDirPath, "",
"The location of the root of the Android SDK. This path "
"should contain folders such as build-tools and platform-tools.");
RDOC_CONFIG(rdcstr, Android_JDKDirPath, "",
"The location of the root of the Java JDK. This path "
"should contain folders such as bin and lib.");
namespace Android
{
static bool adbKillServer = false;
@@ -178,8 +187,8 @@ rdcstr getToolPath(ToolDir subdir, const rdcstr &toolname, bool checkExist)
// its client-server setup, so if we run our bundled adb that might be newer than the user's, they
// will then get fighting back and forth when trying to run their own.
rdcstr sdk = RenderDoc::Inst().GetConfigSetting("androidSDKPath");
rdcstr jdk = RenderDoc::Inst().GetConfigSetting("androidJDKPath");
rdcstr sdk = Android_SDKDirPath;
rdcstr jdk = Android_JDKDirPath;
ToolPathCache &cache = getCache();