mirror of
https://github.com/valentderah/totk-pc-recomp.git
synced 2026-11-24 13:45:57 +00:00
Leave the setup's AMD FSR box unticked when no display adapter could be listed
A player whose adapter query fails no longer downloads AMD's FSR libraries (about 36 MB) by default; the box starts ticked only where an AMD adapter is listed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
35d7411bab
commit
94e66ebfde
2 files changed
+7
-7
No files matched your search
@@ -131,11 +131,10 @@ def amount(cat, done, total, unit):
|
||||
# ---- the form ----------------------------------------------------------------------------------------------------
|
||||
|
||||
def fsr_default(adapters):
|
||||
"""Whether the window ticks Download AMD FSR at start: with an AMD display adapter among adapters (their names,
|
||||
screens.windows_adapter_names), and when none could be listed, as before. The step downloads on any GPU when
|
||||
ticked (steps.Fsr); unticked by default on other GPUs, their players only download it when they choose to."""
|
||||
if not adapters:
|
||||
return True
|
||||
"""Whether the window ticks Download AMD FSR at start: only with an AMD display adapter among adapters (their
|
||||
names, screens.windows_adapter_names). The step downloads on any GPU when ticked (steps.Fsr); on other GPUs, and
|
||||
when no adapter could be listed, the box starts unticked, so a player without an AMD GPU never downloads AMD's
|
||||
libraries (about 36 MB) without choosing to."""
|
||||
return any('AMD' in a.upper() or 'RADEON' in a.upper() for a in adapters)
|
||||
|
||||
|
||||
|
||||
@@ -183,7 +183,8 @@ class RunStatesTest(unittest.TestCase):
|
||||
|
||||
|
||||
class FsrDefaultTest(unittest.TestCase):
|
||||
"""Download AMD FSR is ticked at start with an AMD adapter only, and when no adapter could be listed."""
|
||||
"""Download AMD FSR is ticked at start with an AMD adapter only: not with other GPUs, nor when no adapter could be
|
||||
listed."""
|
||||
|
||||
def test_amd(self):
|
||||
self.assertTrue(fsr_default(['AMD Radeon RX 9060 XT']))
|
||||
@@ -194,7 +195,7 @@ class FsrDefaultTest(unittest.TestCase):
|
||||
self.assertFalse(fsr_default(['Intel(R) Arc(TM) A770 Graphics', 'Microsoft Basic Render Driver']))
|
||||
|
||||
def test_unknown(self):
|
||||
self.assertTrue(fsr_default([]))
|
||||
self.assertFalse(fsr_default([]))
|
||||
|
||||
|
||||
class FormTest(unittest.TestCase):
|
||||
|
||||
Reference in new issue
Block a user