mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-12 04:50:35 +00:00
Expose function to query git commit hash version info
This commit is contained in:
@@ -2165,6 +2165,15 @@ This will be in the form "MAJOR.MINOR"
|
||||
)");
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC RENDERDOC_GetVersionString();
|
||||
|
||||
DOCUMENT(R"(Retrieves the commit hash used to build.
|
||||
|
||||
This will be in the form "0123456789abcdef0123456789abcdef01234567"
|
||||
|
||||
:return: The commit hash.
|
||||
:rtype: ``str``
|
||||
)");
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC RENDERDOC_GetCommitHash();
|
||||
|
||||
DOCUMENT("Internal function for retrieving a config setting.");
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC RENDERDOC_GetConfigSetting(const char *name);
|
||||
|
||||
|
||||
@@ -175,6 +175,11 @@ extern "C" RENDERDOC_API const char *RENDERDOC_CC RENDERDOC_GetVersionString()
|
||||
return MAJOR_MINOR_VERSION_STRING;
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC RENDERDOC_GetCommitHash()
|
||||
{
|
||||
return GitVersionHash;
|
||||
}
|
||||
|
||||
extern "C" RENDERDOC_API const char *RENDERDOC_CC RENDERDOC_GetConfigSetting(const char *name)
|
||||
{
|
||||
return RenderDoc::Inst().GetConfigSetting(name).c_str();
|
||||
|
||||
Reference in New Issue
Block a user