mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-01 03:57:17 +01:00
Implement support for setting two common driver flags for Turnip (custom Adreno driver)
enable_tp_ubwc_flag_hint and storage_8bit are now available as check boxes on the driver setup screen. Fixes #22808
This commit is contained in:
1 parent
57161a245e
commit
176f56da8d
10 files changed
+82
-2
No files matched your search
@@ -754,6 +754,8 @@ bool Config::IsBackendEnabled(GPUBackend backend) {
|
||||
if (backend == GPUBackend::OPENGL)
|
||||
return false;
|
||||
#endif
|
||||
// On normal boots, this is where the Vulkan driver gets loaded the first time, in this check.
|
||||
// That's a bit weird actually. But at least the config is loaded.
|
||||
if (backend == GPUBackend::VULKAN && !VulkanMayBeAvailable())
|
||||
return false;
|
||||
return true;
|
||||
@@ -920,6 +922,7 @@ static constexpr ConfigSetting graphicsSettings[] = {
|
||||
.Label(I18NCat::GRAPHICS, "External display").Choices(externalDisplayNames),
|
||||
#if PPSSPP_PLATFORM(ANDROID) && PPSSPP_ARCH(ARM64)
|
||||
ConfigSetting("CustomDriver", SETTING(g_Config, sCustomDriver), "", CfgFlag::DEFAULT),
|
||||
ConfigSetting("AdrenoDriverVars", SETTING(g_Config, iAdrenoEnvVars), 0, CfgFlag::DEFAULT),
|
||||
#endif
|
||||
ConfigSetting("DisabledGraphicsBackends", SETTING(g_Config, sDisabledGPUBackends), "", CfgFlag::DEFAULT),
|
||||
ConfigSetting("VulkanDevice", SETTING(g_Config, sVulkanDevice), "", CfgFlag::DEFAULT)
|
||||
@@ -2050,6 +2053,12 @@ void Config::PostLoadCleanup() {
|
||||
iGPUBackend = (int)GPUBackend::DIRECT3D11;
|
||||
#endif
|
||||
|
||||
// IsBackendEnabled below triggers a Vulkan driver load. So we must first apply the environment vars for custom drivers,
|
||||
// so the environment variables are set on load. Not super pretty.
|
||||
if (!g_Config.sCustomDriver.empty()) {
|
||||
VulkanApplyCustomDriverEnvVars((AdrenoEnvVar)g_Config.iAdrenoEnvVars);
|
||||
}
|
||||
|
||||
if (!IsBackendEnabled((GPUBackend)iGPUBackend)) {
|
||||
ERROR_LOG(Log::G3D, "Backend %d not enabled - switching to platform default", iGPUBackend);
|
||||
iGPUBackend = (int)DefaultGPUBackend();
|
||||
|
||||
Reference in new issue
Block a user