Skip to content

Commit

Permalink
Core: Add flag to prevent graphics cycling.
Browse files Browse the repository at this point in the history
For debugging graphics crashes.
  • Loading branch information
unknownbrackets committed Sep 2, 2018
1 parent f906fbe commit e246a94
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions UI/NativeApp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -353,6 +353,10 @@ static void CheckFailedGPUBackends() {
g_Config.sFailedGPUBackends = data;
}

// Use this if you want to debug a graphics crash...
if (g_Config.sFailedGPUBackends == "IGNORE")
return;

// Okay, let's not try a backend in the failed list.
g_Config.iGPUBackend = g_Config.NextValidBackend();
// And then let's - for now - add the current to the failed list.
Expand All @@ -374,6 +378,9 @@ static void CheckFailedGPUBackends() {
}

static void ClearFailedGPUBackends() {
if (g_Config.sFailedGPUBackends == "IGNORE")
return;

// We've successfully started graphics without crashing, hurray.
// In case they update drivers and have totally different problems much later, clear the failed list.
g_Config.sFailedGPUBackends.clear();
Expand Down

0 comments on commit e246a94

Please sign in to comment.