mirror of
https://github.com/ayufan/steam-deck-tools.git
synced 2026-04-05 22:35:38 +00:00
GPU detection will log errors to Sentry.io
This commit is contained in:
parent
4398177722
commit
9d4828fdf1
3 changed files with 32 additions and 19 deletions
|
|
@ -8,6 +8,8 @@ namespace PowerControl
|
|||
{
|
||||
internal static class Program
|
||||
{
|
||||
const int MAX_GPU_RETRIES = 3;
|
||||
|
||||
/// <summary>
|
||||
/// The main entry point for the application.
|
||||
/// </summary>
|
||||
|
|
@ -24,11 +26,13 @@ namespace PowerControl
|
|||
"You are running EXPERIMENTAL build."))
|
||||
return;
|
||||
|
||||
for (int i = 0; !VangoghGPU.IsSupported; i++)
|
||||
for (int i = 0; !VangoghGPU.IsSupported && i < MAX_GPU_RETRIES; i++)
|
||||
{
|
||||
Instance.WithGlobalMutex(1000, () => VangoghGPU.Detect());
|
||||
if (VangoghGPU.IsSupported)
|
||||
Thread.Sleep(300);
|
||||
var status = Instance.WithGlobalMutex(1000, () => VangoghGPU.Detect());
|
||||
if (status != VangoghGPU.DetectionStatus.Retryable)
|
||||
break;
|
||||
|
||||
Thread.Sleep(300);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue