mirror of
https://git.triforceproject.com/triforce/source
synced 2026-11-29 04:18:49 -04:00
Triforce v0.8.5
A Randomizer page in the launcher, a new title screen with Mods and Save Select tabs, scaling changes applied in game, the Jabu-Jabu bars fixed, renderer frame-time work and the brightness-flash fix, and fixes from the 0.8.4 reports.
This commit is contained in:
@@ -147,15 +147,25 @@ std::string nv_own_folder_mark_path() {
|
||||
/// reads them; a path or size the player set wins. Windows' driver honours both (a probe at 100 MB stayed there); Linux's
|
||||
/// main sets the size for every player already (host/hos_main.c driver_cache_room)
|
||||
static void nv_own_folder() {
|
||||
FILE* m = fopen(nv_own_folder_mark_path().c_str(), "rb");
|
||||
if (!m) return;
|
||||
fclose(m);
|
||||
const std::string mark = nv_own_folder_mark_path();
|
||||
const std::string dir = mark.substr(0, mark.find_last_of("\\/") + 1) + "triforce_nvidia_cache";
|
||||
if (getenv("__GL_SHADER_DISK_CACHE_PATH")) {
|
||||
logf("vk: NVIDIA's shader cache: __GL_SHADER_DISK_CACHE_PATH is set already, kept (%s)", getenv("__GL_SHADER_DISK_CACHE_PATH"));
|
||||
FILE* m = fopen(mark.c_str(), "rb");
|
||||
if (m) fclose(m);
|
||||
if (const char* set = getenv("__GL_SHADER_DISK_CACHE_PATH")) {
|
||||
// ((Triforce, 11-27) host/hos_main.c nv_own_cache_folder sets it at the start, before the driver loads (on Linux for
|
||||
// every PC, on Windows with the marker): said here
|
||||
if (dir == set)
|
||||
logf("vk: NVIDIA's shader cache: a folder of the game's own, %s, %s bytes (set at the start%s; HOS_NV_OWN_CACHE=0: "
|
||||
"the driver's folder)", dir.c_str(),
|
||||
getenv("__GL_SHADER_DISK_CACHE_SIZE") ? getenv("__GL_SHADER_DISK_CACHE_SIZE") : "the driver's",
|
||||
m ? ": this PC's driver did not keep the game's in its own folder" : "");
|
||||
else // ((Triforce, 11-28) said with or without the marker: a player saw the game build its shaders again when started
|
||||
// from a Steam shortcut, as if that start's driver cache were another; this line names the folder it used)
|
||||
logf("vk: NVIDIA's shader cache: __GL_SHADER_DISK_CACHE_PATH is set already, before the game (a launcher, Steam or the "
|
||||
"player), kept: %s%s", set, m ? "" : " (a start without it uses the driver's own folder: two caches)");
|
||||
return;
|
||||
}
|
||||
if (!m) return;
|
||||
std::error_code ec;
|
||||
std::filesystem::create_directories(dir, ec);
|
||||
#ifdef _WIN32
|
||||
|
||||
Reference in New Issue
Block a user