diff --git a/data_from_portwine/locales/PortProton.pot b/data_from_portwine/locales/PortProton.pot index dba19d79..780401ce 100644 --- a/data_from_portwine/locales/PortProton.pot +++ b/data_from_portwine/locales/PortProton.pot @@ -534,6 +534,10 @@ msgid "Instead of DXVK, use WineD3D vulkan (Damavand). Experimental " "function." msgstr "" +msgid "Use dxvk and vkd3d which are bundled with wine or proton. (Does not " + "work with PROTON_LG and WINE_LG)" +msgstr "" + msgid "Disable asynchronous calls for VULKAN and DXVK modes" msgstr "" diff --git a/data_from_portwine/locales/es/LC_MESSAGES/PortProton.po b/data_from_portwine/locales/es/LC_MESSAGES/PortProton.po index 001d708f..9fde19d2 100644 --- a/data_from_portwine/locales/es/LC_MESSAGES/PortProton.po +++ b/data_from_portwine/locales/es/LC_MESSAGES/PortProton.po @@ -642,6 +642,13 @@ msgstr "" msgid "Instead of DXVK, use WineD3D vulkan (Damavand). Experimental function." msgstr "WineD3D Vulkan (Damavand experimental)" +msgid "" +"Use dxvk and vkd3d which are bundled with wine or proton. (Does not work " +"with PROTON_LG and WINE_LG)" +msgstr "" +"Utilice dxvk y vkd3d que vienen incluidos con wine o proton. (No funciona " +"con PROTON_LG y WINE_LG)" + msgid "Disable asynchronous calls for VULKAN and DXVK modes" msgstr "Desactivar llamadas asíncronas para los modos VULKAN y DXVK" diff --git a/data_from_portwine/locales/ru/LC_MESSAGES/PortProton.po b/data_from_portwine/locales/ru/LC_MESSAGES/PortProton.po index af537ff6..06d99106 100644 --- a/data_from_portwine/locales/ru/LC_MESSAGES/PortProton.po +++ b/data_from_portwine/locales/ru/LC_MESSAGES/PortProton.po @@ -663,6 +663,13 @@ msgstr "" "Вместо DXVK используется WineD3D vulkan (Дамаванд). Экспериментальная " "функция." +msgid "" +"Use dxvk and vkd3d which are bundled with wine or proton. (Does not work " +"with PROTON_LG and WINE_LG)" +msgstr "" +"Использовать dxvk и vkd3d, которые поставляются в комплекте с wine или " +"proton. (Не работает с PROTON_LG и WINE_LG)" + msgid "Disable asynchronous calls for VULKAN and DXVK modes" msgstr "Отключить асинхронные вызовы для режимов VULKAN и DXVK" diff --git a/data_from_portwine/scripts/functions_helper b/data_from_portwine/scripts/functions_helper index b9320a01..bb42ce94 100755 --- a/data_from_portwine/scripts/functions_helper +++ b/data_from_portwine/scripts/functions_helper @@ -665,7 +665,6 @@ var_winedlloverride_update () { export WINEDLLOVERRIDES="${1}${WINEDLLOVERRIDES:+;$WINEDLLOVERRIDES}" } - var_vkd3d_config_update () { if echo "$VKD3D_CONFIG" | grep "$1" then return 0 @@ -2455,7 +2454,6 @@ pw_init_db () { ;; esac - [[ "${START_FROM_STEAM}" == 1 ]] && export PW_GUI_DISABLED_CS=1 [[ "${START_FROM_PP_GUI}" == 1 ]] && export PW_GUI_DISABLED_CS=0 && unset START_FROM_PP_GUI @@ -3691,6 +3689,40 @@ start_portwine () { fi fi + if [[ $PW_USE_SUPPLIED_DXVK_VKD3D == "1" ]] \ + && [[ ! $PW_WINE_USE =~ (PROTON_LG|WINE_LG) ]] \ + && [[ ! $PW_VULKAN_USE =~ (0|3) ]] \ + && [[ -f "${WINEDIR}/lib64/wine/dxvk/d3d9.dll" ]] ; then + if [[ -f "${WINEDIR}/lib64/wine/dxvk/d3d10.dll" && -f "${WINEDIR}/lib64/wine/dxvk/d3d10_1.dll" ]] ; then + CP_DXVK_FILES="d3d11 d3d10core d3d10_1 d3d10 d3d9 dxgi" + CP_WINE_FILES="" + else + CP_DXVK_FILES="d3d11 d3d10core d3d9 dxgi" + CP_WINE_FILES="d3d10_1 d3d10" + fi + if [[ $PW_DGVOODOO2 != "1" ]] ; then + if [[ -f "${WINEDIR}/lib64/wine/d8vk/d3d8.dll" ]] ; then + try_force_link_file "${WINEDIR}/lib/wine/d8vk/d3d8.dll" "${WINEPREFIX}/drive_c/windows/syswow64/d3d8.dll" + try_force_link_file "${WINEDIR}/lib64/wine/d8vk/d3d8.dll" "${WINEPREFIX}/drive_c/windows/system32/d3d8.dll" + var_winedlloverride_update "d3d8=n" + elif [[ -f "${WINEDIR}/lib64/wine/dxvk/d3d8.dll" ]] + then add_to_var CP_DXVK_FILES "d3d8" + else add_to_var CP_WINE_FILES "d3d8" + fi + fi + if [[ -f "${WINEDIR}/lib64/wine/vkd3d-proton/d3d12core.dll" && -f "${WINEDIR}/lib64/vkd3d/libvkd3d-1.dll" ]] ; then + CP_VKD3D_FILES="d3d12 d3d12core libvkd3d-1 libvkd3d-shader-1" + elif [[ -f "${WINEDIR}/lib64/wine/vkd3d-proton/d3d12.dll" && -f "${WINEDIR}/lib64/vkd3d/libvkd3d-shader-1.dll" ]] ; then + CP_VKD3D_FILES="d3d12 libvkd3d-1 libvkd3d-shader-1" + add_to_var CP_WINE_FILES "d3d12core" + else + CP_VKD3D_FILES="libvkd3d-1 libvkd3d-shader-1" + add_to_var CP_WINE_FILES "d3d12 d3d12core" + fi + else + PW_USE_SUPPLIED_DXVK_VKD3D="0" + fi + # DGVOODOO2 enable: if [[ "${PW_DGVOODOO2}" == "1" ]] ; then print_info "Try create symlink DGVOODOO2 files..." @@ -3704,26 +3736,31 @@ start_portwine () { try_force_link_file "${PATH_TO_DGV2_FILES}/x64/d3d9.dll" "${WINEPREFIX}/drive_c/windows/system32/d3d9.dll" try_remove_file "${WINEPREFIX}/drive_c/windows/system32/dgVoodoo.conf" try_force_link_file "${DGV2CONF}" "${WINEPREFIX}/drive_c/windows/system32/dgVoodoo.conf" - case "${PW_VULKAN_USE}" in - 0) - rm_from_var CP_WINE_FILES "d3d9 d3d8" - ;; - 1) - rm_from_var CP_DXVK_FILES "d3d9" - rm_from_var CP_WINE_FILES "d3d8" - ;; - 2) - rm_from_var CP_DXVK_FILES "d3d9 d3d8" - ;; - 3) - rm_from_var CP_GALLIUM_NINE_FILES "d3d9" - rm_from_var CP_WINE_FILES "d3d8" - ;; - 5) - rm_from_var CP_DXVK_FILES "d3d9" - rm_from_var CP_WINE_FILES "d3d8" - ;; - esac + + if [[ $PW_USE_SUPPLIED_DXVK_VKD3D == "1" ]] ; then + rm_from_var CP_DXVK_FILES "d3d9" + else + case "${PW_VULKAN_USE}" in + 0) + rm_from_var CP_WINE_FILES "d3d9 d3d8" + ;; + 1) + rm_from_var CP_DXVK_FILES "d3d9" + rm_from_var CP_WINE_FILES "d3d8" + ;; + 2) + rm_from_var CP_DXVK_FILES "d3d9 d3d8" + ;; + 3) + rm_from_var CP_GALLIUM_NINE_FILES "d3d9" + rm_from_var CP_WINE_FILES "d3d8" + ;; + 5) + rm_from_var CP_DXVK_FILES "d3d9" + rm_from_var CP_WINE_FILES "d3d8" + ;; + esac + fi fi if [[ "${PW_DGV2_GLIDE_NAPALM}" == "1" ]] ; then @@ -3914,13 +3951,16 @@ start_portwine () { if [[ -n "$CP_DXVK_FILES" ]] ; then print_info "Try create symlink DXVK files..." for wine_dxvk_dll in $CP_DXVK_FILES ; do - if [[ -f "${PATH_TO_DXVK_FILES}/x64/${wine_dxvk_dll}.dll" ]] ; then + if [[ $PW_USE_SUPPLIED_DXVK_VKD3D == "1" ]] ; then + try_force_link_file "${WINEDIR}/lib/wine/dxvk/${wine_dxvk_dll}.dll" "${WINEPREFIX}/drive_c/windows/syswow64/${wine_dxvk_dll}.dll" + try_force_link_file "${WINEDIR}/lib64/wine/dxvk/${wine_dxvk_dll}.dll" "${WINEPREFIX}/drive_c/windows/system32/${wine_dxvk_dll}.dll" + else try_force_link_file "${PATH_TO_DXVK_FILES}/x32/${wine_dxvk_dll}.dll" "${WINEPREFIX}/drive_c/windows/syswow64/${wine_dxvk_dll}.dll" try_force_link_file "${PATH_TO_DXVK_FILES}/x64/${wine_dxvk_dll}.dll" "${WINEPREFIX}/drive_c/windows/system32/${wine_dxvk_dll}.dll" - if [[ "$PW_USE_FAKE_DLSS_3" == "1" ]] && [[ "$wine_dxvk_dll" == dxgi ]] - then var_winedlloverride_update "dxgi=n,b" - else var_winedlloverride_update "${wine_dxvk_dll}=n" - fi + fi + if [[ $PW_USE_FAKE_DLSS_3 == "1" ]] && [[ $wine_dxvk_dll == "dxgi" ]] + then var_winedlloverride_update "dxgi=n,b" + else var_winedlloverride_update "${wine_dxvk_dll}=n" fi done create_new_dir "${PATH_TO_DXVK_FILES}/dxvk_cache" @@ -3930,9 +3970,15 @@ start_portwine () { if [[ "$DXVK_ENABLE_NVAPI" == "1" ]] ; then print_info "Try create symlink NVAPI files..." - try_force_link_file "${PATH_TO_DXVK_FILES}/x32/nvapi.dll" "${WINEPREFIX}/drive_c/windows/syswow64/nvapi.dll" - try_force_link_file "${PATH_TO_DXVK_FILES}/x64/nvapi64.dll" "${WINEPREFIX}/drive_c/windows/system32/nvapi64.dll" - try_force_link_file "${PATH_TO_DXVK_FILES}/x64/nvofapi64.dll" "${WINEPREFIX}/drive_c/windows/system32/nvofapi64.dll" + if [[ $PW_USE_SUPPLIED_DXVK_VKD3D == "1" ]] && [[ -f "${WINEDIR}/lib64/wine/nvapi/nvapi64.dll" ]] ; then + try_force_link_file "${WINEDIR}/lib/wine/nvapi/nvapi.dll" "${WINEPREFIX}/drive_c/windows/syswow64/nvapi.dll" + try_force_link_file "${WINEDIR}/lib64/wine/nvapi/nvapi64.dll" "${WINEPREFIX}/drive_c/windows/system32/nvapi64.dll" + try_force_link_file "${WINEDIR}/lib64/wine/nvapi/nvofapi64.dll" "${WINEPREFIX}/drive_c/windows/system32/nvofapi64.dll" + else + try_force_link_file "${PATH_TO_DXVK_FILES}/x32/nvapi.dll" "${WINEPREFIX}/drive_c/windows/syswow64/nvapi.dll" + try_force_link_file "${PATH_TO_DXVK_FILES}/x64/nvapi64.dll" "${WINEPREFIX}/drive_c/windows/system32/nvapi64.dll" + try_force_link_file "${PATH_TO_DXVK_FILES}/x64/nvofapi64.dll" "${WINEPREFIX}/drive_c/windows/system32/nvofapi64.dll" + fi var_winedlloverride_update "nvapi64,nvofapi64,nvapi=n;nvcuda=b" else try_remove_file "${WINEPREFIX}/drive_c/windows/syswow64/nvapi.dll" @@ -3943,11 +3989,20 @@ start_portwine () { if [[ -n "$CP_VKD3D_FILES" ]] ; then print_info "Try create symlink VKD3D files..." for wine_vkd3d_dll in $CP_VKD3D_FILES ; do - if [[ -f "${PATH_TO_VKD3D_FILES}/x64/${wine_vkd3d_dll}.dll" ]] ; then + if [[ $PW_USE_SUPPLIED_DXVK_VKD3D == "1" ]] ; then + if [[ $wine_vkd3d_dll =~ d3d12 ]] ; then + try_force_link_file "${WINEDIR}/lib/wine/vkd3d-proton/${wine_vkd3d_dll}.dll" "${WINEPREFIX}/drive_c/windows/syswow64/${wine_vkd3d_dll}.dll" + try_force_link_file "${WINEDIR}/lib64/wine/vkd3d-proton/${wine_vkd3d_dll}.dll" "${WINEPREFIX}/drive_c/windows/system32/${wine_vkd3d_dll}.dll" + fi + if [[ $wine_vkd3d_dll =~ libvkd3d ]] ; then + try_force_link_file "${WINEDIR}/lib/vkd3d/${wine_vkd3d_dll}.dll" "${WINEPREFIX}/drive_c/windows/syswow64/${wine_vkd3d_dll}.dll" + try_force_link_file "${WINEDIR}/lib64/vkd3d/${wine_vkd3d_dll}.dll" "${WINEPREFIX}/drive_c/windows/system32/${wine_vkd3d_dll}.dll" + fi + else try_force_link_file "${PATH_TO_VKD3D_FILES}/x86/${wine_vkd3d_dll}.dll" "${WINEPREFIX}/drive_c/windows/syswow64/${wine_vkd3d_dll}.dll" try_force_link_file "${PATH_TO_VKD3D_FILES}/x64/${wine_vkd3d_dll}.dll" "${WINEPREFIX}/drive_c/windows/system32/${wine_vkd3d_dll}.dll" - var_winedlloverride_update "${wine_vkd3d_dll}=n" fi + var_winedlloverride_update "${wine_vkd3d_dll}=n" done create_new_dir "${PATH_TO_VKD3D_FILES}/vkd3d_cache" export VKD3D_SHADER_CACHE_PATH="${PATH_TO_VKD3D_FILES}/vkd3d_cache" @@ -4148,7 +4203,6 @@ start_portwine () { get_and_set_reg_file --delete 'Software\Wine\Drivers' 'Graphics' fi - case "$PW_SOUND_DRIVER_USE" in pulse) get_and_set_reg_file --add 'Software\Wine\Drivers' 'Audio' 'REG_SZ' "pulse" "user" ;; alsa) get_and_set_reg_file --add 'Software\Wine\Drivers' 'Audio' 'REG_SZ' "alsa" "user" ;; @@ -4332,7 +4386,6 @@ pw_run () { check_variables SteamAppId "0" check_variables SteamGameId "0" - PW_LOG_TO_FILE="${PORT_WINE_PATH}/PortProton.log" PW_LD_LIBRARY_PATH="${PW_LD_LIBRARY_PATH}:${WINE_LIBRARY_PATH}" print_var "WINEDIR" "WINEPREFIX" "WINEDLLOVERRIDES" "PATH_TO_GAME" "PW_WINE_USE" "PW_VULKAN_USE" "VULKAN_DRIVER_NAME" @@ -5107,7 +5160,7 @@ gui_edit_db () { PW_USE_D3D_EXTRAS PW_FIX_VIDEO_IN_GAME PW_REDUCE_PULSE_LATENCY PW_USE_US_LAYOUT PW_USE_GSTREAMER PW_USE_SHADER_CACHE PW_USE_WINE_DXGI PW_USE_EAC_AND_BE PW_USE_SYSTEM_VK_LAYERS PW_USE_OBS_VKCAPTURE PW_DISABLE_COMPOSITING PW_USE_RUNTIME PW_DINPUT_PROTOCOL PW_USE_NATIVE_WAYLAND PW_USE_GALLIUM_ZINK PW_USE_GALLIUM_NINE - PW_USE_DAMAVAND + PW_USE_DAMAVAND PW_USE_SUPPLIED_DXVK_VKD3D ) if check_wayland_session ; then @@ -5163,6 +5216,7 @@ gui_edit_db () { PW_USE_GALLIUM_ZINK_INFO=${translations[Use Gallium Zink (OpenGL driver is implemented via Vulkan)]} PW_USE_GALLIUM_NINE_INFO=${translations[Use Gallium Nine (native DirectX 9 for MESA)]} PW_USE_DAMAVAND_INFO=${translations[Instead of DXVK, use WineD3D vulkan (Damavand). Experimental function.]} + PW_USE_SUPPLIED_DXVK_VKD3D_INFO=${translations[Use dxvk and vkd3d which are bundled with wine or proton. (Does not work with PROTON_LG and WINE_LG)]} # PW_VULKAN_NO_ASYNC_INFO=${translations[Disable asynchronous calls for VULKAN and DXVK modes]} # PW_OLD_GL_STRING_INFO=${translations[Forced use of older versions of OpenGL]} @@ -5173,8 +5227,7 @@ gui_edit_db () { 0) # WineD3D OpenGL VKD3D_CB="DCB" - DISABLE_EDIT_DB_LIST="PW_VKBASALT PW_VKBASALT_USER_CONF PW_USE_RAY_TRACING PW_USE_OBS_VKCAPTURE PW_USE_GALLIUM_ZINK PW_USE_DAMAVAND - " + DISABLE_EDIT_DB_LIST="PW_VKBASALT PW_VKBASALT_USER_CONF PW_USE_RAY_TRACING PW_USE_OBS_VKCAPTURE PW_USE_GALLIUM_ZINK PW_USE_DAMAVAND" ;; 1|2) # Stable, Newest @@ -5183,11 +5236,12 @@ gui_edit_db () { 5) # Legacy VKD3D_CB="DCB" - DISABLE_EDIT_DB_LIST="PW_USE_RAY_TRACING - " + DISABLE_EDIT_DB_LIST="PW_USE_RAY_TRACING" ;; esac + [[ $PW_WINE_USE =~ (PROTON_LG|WINE_LG) ]] && DISABLE_EDIT_DB_LIST+=" PW_USE_SUPPLIED_DXVK_VKD3D" + unset ADD_CHK_BOX_EDIT_DB for int_to_boole in "${PW_EDIT_DB_LIST[@]}" ; do if [[ "${!int_to_boole}" == "1" ]] @@ -5197,8 +5251,7 @@ gui_edit_db () { TMP_HELP_FOR_GUI="${int_to_boole}_INFO" int_to_boole_non_pw="${int_to_boole//PW_/}" int_to_boole_non_pw="${int_to_boole_non_pw//"_"/" "}" - if [[ ! "${PW_VULKAN_USE}" =~ ^(1|2)$ ]] \ - && [[ -n $DISABLE_EDIT_DB_LIST ]] ; then + if [[ -n $DISABLE_EDIT_DB_LIST ]] ; then unset CHECK_BOOLE_TRUE for check_boole in $DISABLE_EDIT_DB_LIST ; do if [[ $check_boole == "$int_to_boole" ]] ; then @@ -5792,8 +5845,7 @@ gui_dgvoodoo2 () { TMP_HELP_FOR_GUI="${int_to_boole}_INFO" int_to_boole_non_pw="${int_to_boole//PW_DGV2/}" int_to_boole_non_pw="${int_to_boole_non_pw//"_"/" "}" - if [[ ! "${PW_VULKAN_USE}" =~ ^(1|2)$ ]] \ - && [[ -n $DISABLE_DGV2_LIST ]] ; then + if [[ -n $DISABLE_DGV2_LIST ]] ; then unset CHECK_BOOLE_TRUE for check_boole in $DISABLE_DGV2_LIST ; do if [[ $check_boole == "$int_to_boole" ]] ; then diff --git a/data_from_portwine/scripts/var b/data_from_portwine/scripts/var index 663a82e6..b957d208 100755 --- a/data_from_portwine/scripts/var +++ b/data_from_portwine/scripts/var @@ -41,6 +41,7 @@ export STAGING_SHARED_MEMORY="1" export PW_USE_GALLIUM_ZINK="0" export PW_USE_GALLIUM_NINE="0" export PW_USE_DAMAVAND="0" +export PW_USE_SUPPLIED_DXVK_VKD3D="1" ###DEFAULT_WINE### export PW_WINE_USE="PROTON_LG" export PW_PLUGINS_VER="_v20"