mirror of
https://github.com/lutris/lutris
synced 2024-09-04 23:13:35 +00:00
Add dgvoodoo2 option
This commit is contained in:
parent
98520f2f79
commit
af6ecbcb2f
|
@ -18,6 +18,7 @@ from lutris.util.jobs import thread_safe_call
|
|||
from lutris.util.log import logger
|
||||
from lutris.util.strings import parse_version, split_arguments
|
||||
from lutris.util.wine.d3d_extras import D3DExtrasManager
|
||||
from lutris.util.wine.dgvoodoo2 import dgvoodoo2Manager
|
||||
from lutris.util.wine.dxvk import DXVKManager
|
||||
from lutris.util.wine.dxvk_nvapi import DXVKNVAPIManager
|
||||
from lutris.util.wine.prefix import DEFAULT_DLL_OVERRIDES, WinePrefixManager, find_prefix
|
||||
|
@ -269,6 +270,26 @@ class wine(Runner):
|
|||
"choices": DXVKNVAPIManager().version_choices,
|
||||
"default": DXVKNVAPIManager().version,
|
||||
},
|
||||
{
|
||||
"option": "dgvoodoo2",
|
||||
"label": _("Enable dgvoodoo2"),
|
||||
"type": "bool",
|
||||
"default": False,
|
||||
"advanced": False,
|
||||
"help": _(
|
||||
"dgvoodoo2 is an alternative translation layer for rendering old games "
|
||||
"that utilize D3D1-7 and Glide APIs. As it translates to D3D11, it's "
|
||||
"recommended to use it in combination with DXVK. Only 32-bit apps are supported."
|
||||
),
|
||||
},
|
||||
{
|
||||
"option": "dgvoodoo2_version",
|
||||
"label": _("dgvoodoo2 version"),
|
||||
"advanced": True,
|
||||
"type": "choice_with_entry",
|
||||
"choices": dgvoodoo2Manager().version_choices,
|
||||
"default": dgvoodoo2Manager().version,
|
||||
},
|
||||
{
|
||||
"option": "esync",
|
||||
"label": _("Enable Esync"),
|
||||
|
@ -738,6 +759,11 @@ class wine(Runner):
|
|||
bool(self.runner_config.get("d3d_extras")),
|
||||
self.runner_config.get("d3d_extras_version")
|
||||
)
|
||||
self.setup_dlls(
|
||||
dgvoodoo2Manager,
|
||||
bool(self.runner_config.get("dgvoodoo2")),
|
||||
self.runner_config.get("dgvoodoo2_version")
|
||||
)
|
||||
return True
|
||||
|
||||
def get_dll_overrides(self):
|
||||
|
|
|
@ -17,6 +17,7 @@ from lutris.util.linux import LINUX_SYSTEM
|
|||
from lutris.util.log import logger
|
||||
from lutris.util.system import create_folder
|
||||
from lutris.util.wine.d3d_extras import D3DExtrasManager
|
||||
from lutris.util.wine.dgvoodoo2 import dgvoodoo2Manager
|
||||
from lutris.util.wine.dxvk import DXVKManager
|
||||
from lutris.util.wine.dxvk_nvapi import DXVKNVAPIManager
|
||||
from lutris.util.wine.vkd3d import VKD3DManager
|
||||
|
@ -182,7 +183,7 @@ def update_runtime():
|
|||
if components_to_update:
|
||||
while runtime_updater.current_updates:
|
||||
time.sleep(0.3)
|
||||
for dll_manager_class in (DXVKManager, DXVKNVAPIManager, VKD3DManager, D3DExtrasManager):
|
||||
for dll_manager_class in (DXVKManager, DXVKNVAPIManager, VKD3DManager, D3DExtrasManager, dgvoodoo2Manager):
|
||||
dll_manager = dll_manager_class()
|
||||
dll_manager.upgrade()
|
||||
logger.info("Startup complete")
|
||||
|
|
12
lutris/util/wine/dgvoodoo2.py
Normal file
12
lutris/util/wine/dgvoodoo2.py
Normal file
|
@ -0,0 +1,12 @@
|
|||
import os
|
||||
|
||||
from lutris.settings import RUNTIME_DIR
|
||||
from lutris.util.wine.dll_manager import DLLManager
|
||||
|
||||
|
||||
class dgvoodoo2Manager(DLLManager):
|
||||
component = "dgvoodoo2"
|
||||
base_dir = os.path.join(RUNTIME_DIR, "dgvoodoo2")
|
||||
versions_path = os.path.join(base_dir, "dgvoodoo2_versions.json")
|
||||
managed_dlls = ("d3dimm", "ddraw", "glide", "glide2x", "glide3x", )
|
||||
releases_url = "https://api.github.com/repos/lutris/dgvoodoo2/releases"
|
Loading…
Reference in a new issue