Rebrand Common FS Path functions
This commit is contained in:
parent
e8f646b0fd
commit
16dfc39f89
97 changed files with 347 additions and 369 deletions
|
@ -3,8 +3,6 @@
|
||||||
# SPDX-FileCopyrightText: 2019 yuzu Emulator Project
|
# SPDX-FileCopyrightText: 2019 yuzu Emulator Project
|
||||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
# Modified by JuanCStar on 2024/03/06
|
|
||||||
|
|
||||||
. .ci/scripts/common/pre-upload.sh
|
. .ci/scripts/common/pre-upload.sh
|
||||||
|
|
||||||
APPIMAGE_NAME="yuzu-${RELEASE_NAME}-${GITDATE}-${GITREV}.AppImage"
|
APPIMAGE_NAME="yuzu-${RELEASE_NAME}-${GITDATE}-${GITREV}.AppImage"
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
# SPDX-FileCopyrightText: 2018 yuzu Emulator Project
|
# SPDX-FileCopyrightText: 2018 yuzu Emulator Project
|
||||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
# Modified by JuanCStar on 2024/03/06
|
|
||||||
|
|
||||||
cmake_minimum_required(VERSION 3.22)
|
cmake_minimum_required(VERSION 3.22)
|
||||||
|
|
||||||
project(yuzu)
|
project(yuzu)
|
||||||
|
@ -40,7 +38,7 @@ option(YUZU_USE_EXTERNAL_VULKAN_HEADERS "Use Vulkan-Headers from externals" ON)
|
||||||
|
|
||||||
option(YUZU_USE_EXTERNAL_VULKAN_UTILITY_LIBRARIES "Use Vulkan-Utility-Libraries from externals" ON)
|
option(YUZU_USE_EXTERNAL_VULKAN_UTILITY_LIBRARIES "Use Vulkan-Utility-Libraries from externals" ON)
|
||||||
|
|
||||||
option(YUZU_USE_QT_MULTIMEDIA "Use QtMultimedia for Camera" OFF)
|
option(SUYU_USE_QT_MULTIMEDIA "Use QtMultimedia for Camera" OFF)
|
||||||
|
|
||||||
option(YUZU_USE_QT_WEB_ENGINE "Use QtWebEngine for web applet implementation" OFF)
|
option(YUZU_USE_QT_WEB_ENGINE "Use QtWebEngine for web applet implementation" OFF)
|
||||||
|
|
||||||
|
@ -66,7 +64,7 @@ option(YUZU_ENABLE_LTO "Enable link-time optimization" OFF)
|
||||||
|
|
||||||
option(YUZU_DOWNLOAD_TIME_ZONE_DATA "Always download time zone binaries" OFF)
|
option(YUZU_DOWNLOAD_TIME_ZONE_DATA "Always download time zone binaries" OFF)
|
||||||
|
|
||||||
option(YUZU_ENABLE_PORTABLE "Allow yuzu to enable portable mode if a user folder is found in the CWD" ON)
|
option(SUYU_ENABLE_PORTABLE "Allow suyu to enable portable mode if a user folder is found in the CWD" ON)
|
||||||
|
|
||||||
CMAKE_DEPENDENT_OPTION(YUZU_USE_FASTER_LD "Check if a faster linker is available" ON "NOT WIN32" OFF)
|
CMAKE_DEPENDENT_OPTION(YUZU_USE_FASTER_LD "Check if a faster linker is available" ON "NOT WIN32" OFF)
|
||||||
|
|
||||||
|
@ -264,7 +262,7 @@ endif()
|
||||||
message(STATUS "Target architecture: ${ARCHITECTURE}")
|
message(STATUS "Target architecture: ${ARCHITECTURE}")
|
||||||
|
|
||||||
if (UNIX)
|
if (UNIX)
|
||||||
add_definitions(-DYUZU_UNIX=1)
|
add_definitions(-DSUYU_UNIX=1)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (ARCHITECTURE_arm64 AND (ANDROID OR ${CMAKE_SYSTEM_NAME} STREQUAL "Linux"))
|
if (ARCHITECTURE_arm64 AND (ANDROID OR ${CMAKE_SYSTEM_NAME} STREQUAL "Linux"))
|
||||||
|
@ -373,7 +371,7 @@ function(set_yuzu_qt_components)
|
||||||
if (${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
|
if (${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
|
||||||
list(APPEND YUZU_QT_COMPONENTS2 DBus)
|
list(APPEND YUZU_QT_COMPONENTS2 DBus)
|
||||||
endif()
|
endif()
|
||||||
if (YUZU_USE_QT_MULTIMEDIA)
|
if (SUYU_USE_QT_MULTIMEDIA)
|
||||||
list(APPEND YUZU_QT_COMPONENTS2 Multimedia)
|
list(APPEND YUZU_QT_COMPONENTS2 Multimedia)
|
||||||
endif()
|
endif()
|
||||||
if (YUZU_USE_QT_WEB_ENGINE)
|
if (YUZU_USE_QT_WEB_ENGINE)
|
||||||
|
@ -411,7 +409,7 @@ if(ENABLE_QT)
|
||||||
set(QT_DEFAULT_MAJOR_VERSION 5)
|
set(QT_DEFAULT_MAJOR_VERSION 5)
|
||||||
set(QT_MAJOR_VERSION 5)
|
set(QT_MAJOR_VERSION 5)
|
||||||
|
|
||||||
set(YUZU_USE_QT_MULTIMEDIA ON)
|
set(SUYU_USE_QT_MULTIMEDIA ON)
|
||||||
# Check for system Qt on Linux, fallback to bundled Qt
|
# Check for system Qt on Linux, fallback to bundled Qt
|
||||||
if (UNIX AND NOT APPLE)
|
if (UNIX AND NOT APPLE)
|
||||||
if (NOT YUZU_USE_BUNDLED_QT)
|
if (NOT YUZU_USE_BUNDLED_QT)
|
||||||
|
@ -518,7 +516,7 @@ if(ENABLE_QT)
|
||||||
|
|
||||||
set(YUZU_QT_NO_CMAKE_SYSTEM_PATH "NO_CMAKE_SYSTEM_PATH")
|
set(YUZU_QT_NO_CMAKE_SYSTEM_PATH "NO_CMAKE_SYSTEM_PATH")
|
||||||
# Binary package for Qt5 has Qt Multimedia
|
# Binary package for Qt5 has Qt Multimedia
|
||||||
set(YUZU_USE_QT_MULTIMEDIA ON CACHE BOOL "Use Qt Multimedia" FORCE)
|
set(SUYU_USE_QT_MULTIMEDIA ON CACHE BOOL "Use Qt Multimedia" FORCE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set_yuzu_qt_components()
|
set_yuzu_qt_components()
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
# SPDX-FileCopyrightText: 2016 Citra Emulator Project
|
# SPDX-FileCopyrightText: 2016 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
function(copy_yuzu_Qt5_deps target_dir)
|
function(copy_yuzu_Qt5_deps target_dir)
|
||||||
|
@ -33,7 +33,7 @@ function(copy_yuzu_Qt5_deps target_dir)
|
||||||
Qt5Widgets$<$<CONFIG:Debug>:d>.*
|
Qt5Widgets$<$<CONFIG:Debug>:d>.*
|
||||||
Qt5Network$<$<CONFIG:Debug>:d>.*
|
Qt5Network$<$<CONFIG:Debug>:d>.*
|
||||||
)
|
)
|
||||||
if (YUZU_USE_QT_MULTIMEDIA)
|
if (SUYU_USE_QT_MULTIMEDIA)
|
||||||
windows_copy_files(${target_dir} ${Qt5_DLL_DIR} ${DLL_DEST}
|
windows_copy_files(${target_dir} ${Qt5_DLL_DIR} ${DLL_DEST}
|
||||||
Qt5Multimedia$<$<CONFIG:Debug>:d>.*
|
Qt5Multimedia$<$<CONFIG:Debug>:d>.*
|
||||||
)
|
)
|
||||||
|
|
2
dist/languages/ar.ts
vendored
2
dist/languages/ar.ts
vendored
|
@ -6838,7 +6838,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>الخروج من يوزو</translation>
|
<translation>الخروج من يوزو</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/ca.ts
vendored
2
dist/languages/ca.ts
vendored
|
@ -6875,7 +6875,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation type="unfinished"/>
|
<translation type="unfinished"/>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/cs.ts
vendored
2
dist/languages/cs.ts
vendored
|
@ -6859,7 +6859,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Ukončit yuzu</translation>
|
<translation>Ukončit yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/da.ts
vendored
2
dist/languages/da.ts
vendored
|
@ -6863,7 +6863,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation type="unfinished"/>
|
<translation type="unfinished"/>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/de.ts
vendored
2
dist/languages/de.ts
vendored
|
@ -6886,7 +6886,7 @@ Debug Nachricht:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>yuzu verlassen</translation>
|
<translation>yuzu verlassen</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/el.ts
vendored
2
dist/languages/el.ts
vendored
|
@ -6859,7 +6859,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation type="unfinished"/>
|
<translation type="unfinished"/>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/es.ts
vendored
2
dist/languages/es.ts
vendored
|
@ -6932,7 +6932,7 @@ Mensaje de depuración: </translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Cerrar yuzu</translation>
|
<translation>Cerrar yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/fr.ts
vendored
2
dist/languages/fr.ts
vendored
|
@ -6925,7 +6925,7 @@ Message de débogage : </translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Quitter yuzu</translation>
|
<translation>Quitter yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/hu.ts
vendored
2
dist/languages/hu.ts
vendored
|
@ -6899,7 +6899,7 @@ Hibakereső üzenet:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Kilépés a yuzuból</translation>
|
<translation>Kilépés a yuzuból</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/id.ts
vendored
2
dist/languages/id.ts
vendored
|
@ -6916,7 +6916,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation type="unfinished"/>
|
<translation type="unfinished"/>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/it.ts
vendored
2
dist/languages/it.ts
vendored
|
@ -6895,7 +6895,7 @@ Messaggio di debug:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Esci da yuzu</translation>
|
<translation>Esci da yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/ja_JP.ts
vendored
2
dist/languages/ja_JP.ts
vendored
|
@ -6881,7 +6881,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>yuzuを終了</translation>
|
<translation>yuzuを終了</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/ko_KR.ts
vendored
2
dist/languages/ko_KR.ts
vendored
|
@ -6880,7 +6880,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>yuzu 종료</translation>
|
<translation>yuzu 종료</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/nb.ts
vendored
2
dist/languages/nb.ts
vendored
|
@ -6885,7 +6885,7 @@ Feilmelding:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Avslutt yuzu</translation>
|
<translation>Avslutt yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/nl.ts
vendored
2
dist/languages/nl.ts
vendored
|
@ -6873,7 +6873,7 @@ Debug-bericht: </translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>yuzu afsluiten</translation>
|
<translation>yuzu afsluiten</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/pl.ts
vendored
2
dist/languages/pl.ts
vendored
|
@ -6876,7 +6876,7 @@ Komunikat debugowania:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Wyjdź z yuzu</translation>
|
<translation>Wyjdź z yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/pt_BR.ts
vendored
2
dist/languages/pt_BR.ts
vendored
|
@ -6934,7 +6934,7 @@ Mensagem de depuração:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Sair do yuzu</translation>
|
<translation>Sair do yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/pt_PT.ts
vendored
2
dist/languages/pt_PT.ts
vendored
|
@ -6917,7 +6917,7 @@ Mensagem de depuração:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Sair do yuzu</translation>
|
<translation>Sair do yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/ru_RU.ts
vendored
2
dist/languages/ru_RU.ts
vendored
|
@ -6930,7 +6930,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Выйти из yuzu</translation>
|
<translation>Выйти из yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/sv.ts
vendored
2
dist/languages/sv.ts
vendored
|
@ -6854,7 +6854,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation type="unfinished"/>
|
<translation type="unfinished"/>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/tr_TR.ts
vendored
2
dist/languages/tr_TR.ts
vendored
|
@ -6876,7 +6876,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Yuzu'dan çık</translation>
|
<translation>Yuzu'dan çık</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/uk.ts
vendored
2
dist/languages/uk.ts
vendored
|
@ -6889,7 +6889,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Вийти з yuzu</translation>
|
<translation>Вийти з yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/vi.ts
vendored
2
dist/languages/vi.ts
vendored
|
@ -6882,7 +6882,7 @@ Tin nhắn gỡ lỗi:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Thoát yuzu</translation>
|
<translation>Thoát yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/vi_VN.ts
vendored
2
dist/languages/vi_VN.ts
vendored
|
@ -6882,7 +6882,7 @@ Tin nhắn gỡ lỗi:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>Thoát yuzu</translation>
|
<translation>Thoát yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/zh_CN.ts
vendored
2
dist/languages/zh_CN.ts
vendored
|
@ -6930,7 +6930,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>退出 yuzu</translation>
|
<translation>退出 yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
2
dist/languages/zh_TW.ts
vendored
2
dist/languages/zh_TW.ts
vendored
|
@ -6926,7 +6926,7 @@ Debug Message: </source>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
<location filename="../../src/yuzu/uisettings.h" line="242"/>
|
||||||
<source>Exit yuzu</source>
|
<source>Exit suyu</source>
|
||||||
<translation>離開 yuzu</translation>
|
<translation>離開 yuzu</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2023 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2023 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <codecvt>
|
#include <codecvt>
|
||||||
|
@ -659,7 +659,7 @@ void Java_org_yuzu_yuzu_1emu_NativeLibrary_submitInlineKeyboardInput(JNIEnv* env
|
||||||
|
|
||||||
void Java_org_yuzu_yuzu_1emu_NativeLibrary_initializeEmptyUserDirectory(JNIEnv* env,
|
void Java_org_yuzu_yuzu_1emu_NativeLibrary_initializeEmptyUserDirectory(JNIEnv* env,
|
||||||
jobject instance) {
|
jobject instance) {
|
||||||
const auto nand_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir);
|
const auto nand_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir);
|
||||||
auto vfs_nand_dir = EmulationSession::GetInstance().System().GetFilesystem()->OpenDirectory(
|
auto vfs_nand_dir = EmulationSession::GetInstance().System().GetFilesystem()->OpenDirectory(
|
||||||
Common::FS::PathToUTF8String(nand_dir), FileSys::OpenMode::Read);
|
Common::FS::PathToUTF8String(nand_dir), FileSys::OpenMode::Read);
|
||||||
|
|
||||||
|
@ -831,7 +831,7 @@ jstring Java_org_yuzu_yuzu_1emu_NativeLibrary_getSavePath(JNIEnv* env, jobject j
|
||||||
const auto user_id = manager.GetUser(static_cast<std::size_t>(0));
|
const auto user_id = manager.GetUser(static_cast<std::size_t>(0));
|
||||||
ASSERT(user_id);
|
ASSERT(user_id);
|
||||||
|
|
||||||
const auto nandDir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir);
|
const auto nandDir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir);
|
||||||
auto vfsNandDir = system.GetFilesystem()->OpenDirectory(Common::FS::PathToUTF8String(nandDir),
|
auto vfsNandDir = system.GetFilesystem()->OpenDirectory(Common::FS::PathToUTF8String(nandDir),
|
||||||
FileSys::OpenMode::Read);
|
FileSys::OpenMode::Read);
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2024 yuzu Emulator Project
|
// SPDX-FileCopyrightText: 2024 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <common/fs/fs.h>
|
#include <common/fs/fs.h>
|
||||||
|
@ -44,7 +44,7 @@ bool IsProfileNameValid(std::string_view profile_name) {
|
||||||
}
|
}
|
||||||
|
|
||||||
bool ProfileExistsInFilesystem(std::string_view profile_name) {
|
bool ProfileExistsInFilesystem(std::string_view profile_name) {
|
||||||
return Common::FS::Exists(Common::FS::GetYuzuPath(Common::FS::YuzuPath::ConfigDir) / "input" /
|
return Common::FS::Exists(Common::FS::GetSuyuPath(Common::FS::SuyuPath::ConfigDir) / "input" /
|
||||||
fmt::format("{}.ini", profile_name));
|
fmt::format("{}.ini", profile_name));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -304,7 +304,7 @@ void Java_org_yuzu_yuzu_1emu_features_input_NativeInput_loadInputProfiles(JNIEnv
|
||||||
jobject j_obj) {
|
jobject j_obj) {
|
||||||
map_profiles.clear();
|
map_profiles.clear();
|
||||||
const auto input_profile_loc =
|
const auto input_profile_loc =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::ConfigDir) / "input";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::ConfigDir) / "input";
|
||||||
|
|
||||||
if (Common::FS::IsDir(input_profile_loc)) {
|
if (Common::FS::IsDir(input_profile_loc)) {
|
||||||
Common::FS::IterateDirEntries(
|
Common::FS::IterateDirEntries(
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
# SPDX-FileCopyrightText: 2018 yuzu Emulator Project
|
# SPDX-FileCopyrightText: 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
if (DEFINED ENV{AZURECIREPO})
|
if (DEFINED ENV{AZURECIREPO})
|
||||||
|
@ -161,8 +161,8 @@ add_library(common STATIC
|
||||||
zstd_compression.h
|
zstd_compression.h
|
||||||
)
|
)
|
||||||
|
|
||||||
if (YUZU_ENABLE_PORTABLE)
|
if (SUYU_ENABLE_PORTABLE)
|
||||||
add_compile_definitions(YUZU_ENABLE_PORTABLE)
|
add_compile_definitions(SUYU_ENABLE_PORTABLE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
|
|
|
@ -1,14 +1,14 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
// yuzu data directories
|
// suyu data directories
|
||||||
|
|
||||||
#define YUZU_DIR "suyu"
|
#define SUYU_DIR "suyu"
|
||||||
#define PORTABLE_DIR "user"
|
#define PORTABLE_DIR "user"
|
||||||
|
|
||||||
// Sub-directories contained within a yuzu data directory
|
// Sub-directories contained within a suyu data directory
|
||||||
|
|
||||||
#define AMIIBO_DIR "amiibo"
|
#define AMIIBO_DIR "amiibo"
|
||||||
#define CACHE_DIR "cache"
|
#define CACHE_DIR "cache"
|
||||||
|
@ -26,6 +26,6 @@
|
||||||
#define TAS_DIR "tas"
|
#define TAS_DIR "tas"
|
||||||
#define ICONS_DIR "icons"
|
#define ICONS_DIR "icons"
|
||||||
|
|
||||||
// yuzu-specific files
|
// suyu-specific files
|
||||||
|
|
||||||
#define LOG_FILE "suyu_log.txt"
|
#define LOG_FILE "suyu_log.txt"
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -56,10 +56,10 @@ namespace fs = std::filesystem;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The PathManagerImpl is a singleton allowing to manage the mapping of
|
* The PathManagerImpl is a singleton allowing to manage the mapping of
|
||||||
* YuzuPath enums to real filesystem paths.
|
* SuyuPath enums to real filesystem paths.
|
||||||
* This class provides 2 functions: GetYuzuPathImpl and SetYuzuPathImpl.
|
* This class provides 2 functions: GetSuyuPathImpl and SetSuyuPathImpl.
|
||||||
* These are used by GetYuzuPath and SetYuzuPath respectively to get or modify
|
* These are used by GetSuyuPath and SetSuyuPath respectively to get or modify
|
||||||
* the path mapped by the YuzuPath enum.
|
* the path mapped by the SuyuPath enum.
|
||||||
*/
|
*/
|
||||||
class PathManagerImpl {
|
class PathManagerImpl {
|
||||||
public:
|
public:
|
||||||
|
@ -75,62 +75,62 @@ public:
|
||||||
PathManagerImpl(PathManagerImpl&&) = delete;
|
PathManagerImpl(PathManagerImpl&&) = delete;
|
||||||
PathManagerImpl& operator=(PathManagerImpl&&) = delete;
|
PathManagerImpl& operator=(PathManagerImpl&&) = delete;
|
||||||
|
|
||||||
[[nodiscard]] const fs::path& GetYuzuPathImpl(YuzuPath yuzu_path) {
|
[[nodiscard]] const fs::path& GetSuyuPathImpl(SuyuPath suyu_path) {
|
||||||
return yuzu_paths.at(yuzu_path);
|
return suyu_paths.at(suyu_path);
|
||||||
}
|
}
|
||||||
|
|
||||||
void SetYuzuPathImpl(YuzuPath yuzu_path, const fs::path& new_path) {
|
void SetSuyuPathImpl(SuyuPath suyu_path, const fs::path& new_path) {
|
||||||
yuzu_paths.insert_or_assign(yuzu_path, new_path);
|
suyu_paths.insert_or_assign(suyu_path, new_path);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Reinitialize(fs::path yuzu_path = {}) {
|
void Reinitialize(fs::path suyu_path = {}) {
|
||||||
fs::path yuzu_path_cache;
|
fs::path suyu_path_cache;
|
||||||
fs::path yuzu_path_config;
|
fs::path suyu_path_config;
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
#ifdef YUZU_ENABLE_PORTABLE
|
#ifdef SUYU_ENABLE_PORTABLE
|
||||||
yuzu_path = GetExeDirectory() / PORTABLE_DIR;
|
suyu_path = GetExeDirectory() / PORTABLE_DIR;
|
||||||
#endif
|
#endif
|
||||||
if (!IsDir(yuzu_path)) {
|
if (!IsDir(suyu_path)) {
|
||||||
yuzu_path = GetAppDataRoamingDirectory() / YUZU_DIR;
|
suyu_path = GetAppDataRoamingDirectory() / SUYU_DIR;
|
||||||
}
|
}
|
||||||
|
|
||||||
yuzu_path_cache = yuzu_path / CACHE_DIR;
|
suyu_path_cache = suyu_path / CACHE_DIR;
|
||||||
yuzu_path_config = yuzu_path / CONFIG_DIR;
|
suyu_path_config = suyu_path / CONFIG_DIR;
|
||||||
#elif ANDROID
|
#elif ANDROID
|
||||||
ASSERT(!yuzu_path.empty());
|
ASSERT(!suyu_path.empty());
|
||||||
yuzu_path_cache = yuzu_path / CACHE_DIR;
|
suyu_path_cache = suyu_path / CACHE_DIR;
|
||||||
yuzu_path_config = yuzu_path / CONFIG_DIR;
|
suyu_path_config = suyu_path / CONFIG_DIR;
|
||||||
#else
|
#else
|
||||||
#ifdef YUZU_ENABLE_PORTABLE
|
#ifdef SUYU_ENABLE_PORTABLE
|
||||||
yuzu_path = GetCurrentDir() / PORTABLE_DIR;
|
suyu_path = GetCurrentDir() / PORTABLE_DIR;
|
||||||
#endif
|
#endif
|
||||||
if (Exists(yuzu_path) && IsDir(yuzu_path)) {
|
if (Exists(suyu_path) && IsDir(suyu_path)) {
|
||||||
yuzu_path_cache = yuzu_path / CACHE_DIR;
|
suyu_path_cache = suyu_path / CACHE_DIR;
|
||||||
yuzu_path_config = yuzu_path / CONFIG_DIR;
|
suyu_path_config = suyu_path / CONFIG_DIR;
|
||||||
} else {
|
} else {
|
||||||
yuzu_path = GetDataDirectory("XDG_DATA_HOME") / YUZU_DIR;
|
suyu_path = GetDataDirectory("XDG_DATA_HOME") / SUYU_DIR;
|
||||||
yuzu_path_cache = GetDataDirectory("XDG_CACHE_HOME") / YUZU_DIR;
|
suyu_path_cache = GetDataDirectory("XDG_CACHE_HOME") / SUYU_DIR;
|
||||||
yuzu_path_config = GetDataDirectory("XDG_CONFIG_HOME") / YUZU_DIR;
|
suyu_path_config = GetDataDirectory("XDG_CONFIG_HOME") / SUYU_DIR;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
GenerateYuzuPath(YuzuPath::YuzuDir, yuzu_path);
|
GenerateSuyuPath(SuyuPath::SuyuDir, suyu_path);
|
||||||
GenerateYuzuPath(YuzuPath::AmiiboDir, yuzu_path / AMIIBO_DIR);
|
GenerateSuyuPath(SuyuPath::AmiiboDir, suyu_path / AMIIBO_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::CacheDir, yuzu_path_cache);
|
GenerateSuyuPath(SuyuPath::CacheDir, suyu_path_cache);
|
||||||
GenerateYuzuPath(YuzuPath::ConfigDir, yuzu_path_config);
|
GenerateSuyuPath(SuyuPath::ConfigDir, suyu_path_config);
|
||||||
GenerateYuzuPath(YuzuPath::CrashDumpsDir, yuzu_path / CRASH_DUMPS_DIR);
|
GenerateSuyuPath(SuyuPath::CrashDumpsDir, suyu_path / CRASH_DUMPS_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::DumpDir, yuzu_path / DUMP_DIR);
|
GenerateSuyuPath(SuyuPath::DumpDir, suyu_path / DUMP_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::KeysDir, yuzu_path / KEYS_DIR);
|
GenerateSuyuPath(SuyuPath::KeysDir, suyu_path / KEYS_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::LoadDir, yuzu_path / LOAD_DIR);
|
GenerateSuyuPath(SuyuPath::LoadDir, suyu_path / LOAD_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::LogDir, yuzu_path / LOG_DIR);
|
GenerateSuyuPath(SuyuPath::LogDir, suyu_path / LOG_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::NANDDir, yuzu_path / NAND_DIR);
|
GenerateSuyuPath(SuyuPath::NANDDir, suyu_path / NAND_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::PlayTimeDir, yuzu_path / PLAY_TIME_DIR);
|
GenerateSuyuPath(SuyuPath::PlayTimeDir, suyu_path / PLAY_TIME_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::ScreenshotsDir, yuzu_path / SCREENSHOTS_DIR);
|
GenerateSuyuPath(SuyuPath::ScreenshotsDir, suyu_path / SCREENSHOTS_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::SDMCDir, yuzu_path / SDMC_DIR);
|
GenerateSuyuPath(SuyuPath::SDMCDir, suyu_path / SDMC_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::ShaderDir, yuzu_path / SHADER_DIR);
|
GenerateSuyuPath(SuyuPath::ShaderDir, suyu_path / SHADER_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::TASDir, yuzu_path / TAS_DIR);
|
GenerateSuyuPath(SuyuPath::TASDir, suyu_path / TAS_DIR);
|
||||||
GenerateYuzuPath(YuzuPath::IconsDir, yuzu_path / ICONS_DIR);
|
GenerateSuyuPath(SuyuPath::IconsDir, suyu_path / ICONS_DIR);
|
||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
@ -140,13 +140,13 @@ private:
|
||||||
|
|
||||||
~PathManagerImpl() = default;
|
~PathManagerImpl() = default;
|
||||||
|
|
||||||
void GenerateYuzuPath(YuzuPath yuzu_path, const fs::path& new_path) {
|
void GenerateSuyuPath(SuyuPath suyu_path, const fs::path& new_path) {
|
||||||
void(FS::CreateDir(new_path));
|
void(FS::CreateDir(new_path));
|
||||||
|
|
||||||
SetYuzuPathImpl(yuzu_path, new_path);
|
SetSuyuPathImpl(suyu_path, new_path);
|
||||||
}
|
}
|
||||||
|
|
||||||
std::unordered_map<YuzuPath, fs::path> yuzu_paths;
|
std::unordered_map<SuyuPath, fs::path> suyu_paths;
|
||||||
};
|
};
|
||||||
|
|
||||||
bool ValidatePath(const fs::path& path) {
|
bool ValidatePath(const fs::path& path) {
|
||||||
|
@ -230,22 +230,22 @@ void SetAppDirectory(const std::string& app_directory) {
|
||||||
PathManagerImpl::GetInstance().Reinitialize(app_directory);
|
PathManagerImpl::GetInstance().Reinitialize(app_directory);
|
||||||
}
|
}
|
||||||
|
|
||||||
const fs::path& GetYuzuPath(YuzuPath yuzu_path) {
|
const fs::path& GetSuyuPath(SuyuPath suyu_path) {
|
||||||
return PathManagerImpl::GetInstance().GetYuzuPathImpl(yuzu_path);
|
return PathManagerImpl::GetInstance().GetSuyuPathImpl(suyu_path);
|
||||||
}
|
}
|
||||||
|
|
||||||
std::string GetYuzuPathString(YuzuPath yuzu_path) {
|
std::string GetSuyuPathString(SuyuPath suyu_path) {
|
||||||
return PathToUTF8String(GetYuzuPath(yuzu_path));
|
return PathToUTF8String(GetSuyuPath(suyu_path));
|
||||||
}
|
}
|
||||||
|
|
||||||
void SetYuzuPath(YuzuPath yuzu_path, const fs::path& new_path) {
|
void SetSuyuPath(SuyuPath suyu_path, const fs::path& new_path) {
|
||||||
if (!FS::IsDir(new_path)) {
|
if (!FS::IsDir(new_path)) {
|
||||||
LOG_ERROR(Common_Filesystem, "Filesystem object at new_path={} is not a directory",
|
LOG_ERROR(Common_Filesystem, "Filesystem object at new_path={} is not a directory",
|
||||||
PathToUTF8String(new_path));
|
PathToUTF8String(new_path));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
PathManagerImpl::GetInstance().SetYuzuPathImpl(yuzu_path, new_path);
|
PathManagerImpl::GetInstance().SetSuyuPathImpl(suyu_path, new_path);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
@ -10,8 +10,8 @@
|
||||||
|
|
||||||
namespace Common::FS {
|
namespace Common::FS {
|
||||||
|
|
||||||
enum class YuzuPath {
|
enum class SuyuPath {
|
||||||
YuzuDir, // Where yuzu stores its data.
|
SuyuDir, // Where suyu stores its data.
|
||||||
AmiiboDir, // Where Amiibo backups are stored.
|
AmiiboDir, // Where Amiibo backups are stored.
|
||||||
CacheDir, // Where cached filesystem data is stored.
|
CacheDir, // Where cached filesystem data is stored.
|
||||||
ConfigDir, // Where config files are stored.
|
ConfigDir, // Where config files are stored.
|
||||||
|
@ -22,7 +22,7 @@ enum class YuzuPath {
|
||||||
LogDir, // Where log files are stored.
|
LogDir, // Where log files are stored.
|
||||||
NANDDir, // Where the emulated NAND is stored.
|
NANDDir, // Where the emulated NAND is stored.
|
||||||
PlayTimeDir, // Where play time data is stored.
|
PlayTimeDir, // Where play time data is stored.
|
||||||
ScreenshotsDir, // Where yuzu screenshots are stored.
|
ScreenshotsDir, // Where suyu screenshots are stored.
|
||||||
SDMCDir, // Where the emulated SDMC is stored.
|
SDMCDir, // Where the emulated SDMC is stored.
|
||||||
ShaderDir, // Where shaders are stored.
|
ShaderDir, // Where shaders are stored.
|
||||||
TASDir, // Where TAS scripts are stored.
|
TASDir, // Where TAS scripts are stored.
|
||||||
|
@ -193,39 +193,39 @@ template <typename Path>
|
||||||
void SetAppDirectory(const std::string& app_directory);
|
void SetAppDirectory(const std::string& app_directory);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the filesystem path associated with the YuzuPath enum.
|
* Gets the filesystem path associated with the SuyuPath enum.
|
||||||
*
|
*
|
||||||
* @param yuzu_path YuzuPath enum
|
* @param suyu_path SuyuPath enum
|
||||||
*
|
*
|
||||||
* @returns The filesystem path associated with the YuzuPath enum.
|
* @returns The filesystem path associated with the SuyuPath enum.
|
||||||
*/
|
*/
|
||||||
[[nodiscard]] const std::filesystem::path& GetYuzuPath(YuzuPath yuzu_path);
|
[[nodiscard]] const std::filesystem::path& GetSuyuPath(SuyuPath suyu_path);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the filesystem path associated with the YuzuPath enum as a UTF-8 encoded std::string.
|
* Gets the filesystem path associated with the SuyuPath enum as a UTF-8 encoded std::string.
|
||||||
*
|
*
|
||||||
* @param yuzu_path YuzuPath enum
|
* @param suyu_path SuyuPath enum
|
||||||
*
|
*
|
||||||
* @returns The filesystem path associated with the YuzuPath enum as a UTF-8 encoded std::string.
|
* @returns The filesystem path associated with the SuyuPath enum as a UTF-8 encoded std::string.
|
||||||
*/
|
*/
|
||||||
[[nodiscard]] std::string GetYuzuPathString(YuzuPath yuzu_path);
|
[[nodiscard]] std::string GetSuyuPathString(SuyuPath suyu_path);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets a new filesystem path associated with the YuzuPath enum.
|
* Sets a new filesystem path associated with the SuyuPath enum.
|
||||||
* If the filesystem object at new_path is not a directory, this function will not do anything.
|
* If the filesystem object at new_path is not a directory, this function will not do anything.
|
||||||
*
|
*
|
||||||
* @param yuzu_path YuzuPath enum
|
* @param suyu_path SuyuPath enum
|
||||||
* @param new_path New filesystem path
|
* @param new_path New filesystem path
|
||||||
*/
|
*/
|
||||||
void SetYuzuPath(YuzuPath yuzu_path, const std::filesystem::path& new_path);
|
void SetSuyuPath(SuyuPath suyu_path, const std::filesystem::path& new_path);
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
template <typename Path>
|
template <typename Path>
|
||||||
void SetYuzuPath(YuzuPath yuzu_path, const Path& new_path) {
|
void SetSuyuPath(SuyuPath suyu_path, const Path& new_path) {
|
||||||
if constexpr (IsChar<typename Path::value_type>) {
|
if constexpr (IsChar<typename Path::value_type>) {
|
||||||
SetYuzuPath(yuzu_path, ToU8String(new_path));
|
SetSuyuPath(suyu_path, ToU8String(new_path));
|
||||||
} else {
|
} else {
|
||||||
SetYuzuPath(yuzu_path, std::filesystem::path{new_path});
|
SetSuyuPath(suyu_path, std::filesystem::path{new_path});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -257,14 +257,14 @@ void SetYuzuPath(YuzuPath yuzu_path, const Path& new_path) {
|
||||||
[[nodiscard]] std::filesystem::path GetHomeDirectory();
|
[[nodiscard]] std::filesystem::path GetHomeDirectory();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the relevant paths for yuzu to store its data based on the given XDG environment variable.
|
* Gets the relevant paths for suyu to store its data based on the given XDG environment variable.
|
||||||
* See https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
|
* See https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
|
||||||
* Defaults to $HOME/.local/share for main application data,
|
* Defaults to $HOME/.local/share for main application data,
|
||||||
* $HOME/.cache for cached data, and $HOME/.config for configuration files.
|
* $HOME/.cache for cached data, and $HOME/.config for configuration files.
|
||||||
*
|
*
|
||||||
* @param env_name XDG environment variable name
|
* @param env_name XDG environment variable name
|
||||||
*
|
*
|
||||||
* @returns The path where yuzu should store its data.
|
* @returns The path where suyu should store its data.
|
||||||
*/
|
*/
|
||||||
[[nodiscard]] std::filesystem::path GetDataDirectory(const std::string& env_name);
|
[[nodiscard]] std::filesystem::path GetDataDirectory(const std::string& env_name);
|
||||||
|
|
||||||
|
@ -288,11 +288,11 @@ enum class DirectorySeparator {
|
||||||
};
|
};
|
||||||
|
|
||||||
// Splits the path on '/' or '\' and put the components into a vector
|
// Splits the path on '/' or '\' and put the components into a vector
|
||||||
// i.e. "C:\Users\Yuzu\Documents\save.bin" becomes {"C:", "Users", "Yuzu", "Documents", "save.bin" }
|
// i.e. "C:\Users\Suyu\Documents\save.bin" becomes {"C:", "Users", "Suyu", "Documents", "save.bin" }
|
||||||
[[nodiscard]] std::vector<std::string_view> SplitPathComponents(std::string_view filename);
|
[[nodiscard]] std::vector<std::string_view> SplitPathComponents(std::string_view filename);
|
||||||
|
|
||||||
// Splits the path on '/' or '\' and put the components into a vector
|
// Splits the path on '/' or '\' and put the components into a vector
|
||||||
// i.e. "C:\Users\Yuzu\Documents\save.bin" becomes {"C:", "Users", "Yuzu", "Documents", "save.bin" }
|
// i.e. "C:\Users\Suyu\Documents\save.bin" becomes {"C:", "Users", "Suyu", "Documents", "save.bin" }
|
||||||
[[nodiscard]] std::vector<std::string> SplitPathComponentsCopy(std::string_view filename);
|
[[nodiscard]] std::vector<std::string> SplitPathComponentsCopy(std::string_view filename);
|
||||||
|
|
||||||
// Removes trailing slash, makes all '\\' into '/', and removes duplicate '/'. Makes '/' into '\\'
|
// Removes trailing slash, makes all '\\' into '/', and removes duplicate '/'. Makes '/' into '\\'
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2014 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2014 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <atomic>
|
#include <atomic>
|
||||||
|
@ -195,7 +195,7 @@ public:
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
using namespace Common::FS;
|
using namespace Common::FS;
|
||||||
const auto& log_dir = GetYuzuPath(YuzuPath::LogDir);
|
const auto& log_dir = GetSuyuPath(SuyuPath::LogDir);
|
||||||
void(CreateDir(log_dir));
|
void(CreateDir(log_dir));
|
||||||
Filter filter;
|
Filter filter;
|
||||||
filter.ParseFilterString(Settings::values.log_filter.GetValue());
|
filter.ParseFilterString(Settings::values.log_filter.GetValue());
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <cstdlib>
|
#include <cstdlib>
|
||||||
|
@ -14,7 +14,7 @@ namespace Common {
|
||||||
void ConfigureNvidiaEnvironmentFlags() {
|
void ConfigureNvidiaEnvironmentFlags() {
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
const auto nvidia_shader_dir =
|
const auto nvidia_shader_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::ShaderDir) / "nvidia";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::ShaderDir) / "nvidia";
|
||||||
|
|
||||||
if (!Common::FS::CreateDirs(nvidia_shader_dir)) {
|
if (!Common::FS::CreateDirs(nvidia_shader_dir)) {
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <version>
|
#include <version>
|
||||||
|
@ -130,11 +130,11 @@ void LogSettings() {
|
||||||
log_setting(name, setting->Canonicalize());
|
log_setting(name, setting->Canonicalize());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
log_path("DataStorage_CacheDir", Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir));
|
log_path("DataStorage_CacheDir", Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir));
|
||||||
log_path("DataStorage_ConfigDir", Common::FS::GetYuzuPath(Common::FS::YuzuPath::ConfigDir));
|
log_path("DataStorage_ConfigDir", Common::FS::GetSuyuPath(Common::FS::SuyuPath::ConfigDir));
|
||||||
log_path("DataStorage_LoadDir", Common::FS::GetYuzuPath(Common::FS::YuzuPath::LoadDir));
|
log_path("DataStorage_LoadDir", Common::FS::GetSuyuPath(Common::FS::SuyuPath::LoadDir));
|
||||||
log_path("DataStorage_NANDDir", Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir));
|
log_path("DataStorage_NANDDir", Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir));
|
||||||
log_path("DataStorage_SDMCDir", Common::FS::GetYuzuPath(Common::FS::YuzuPath::SDMCDir));
|
log_path("DataStorage_SDMCDir", Common::FS::GetSuyuPath(Common::FS::SuyuPath::SDMCDir));
|
||||||
}
|
}
|
||||||
|
|
||||||
void UpdateGPUAccuracy() {
|
void UpdateGPUAccuracy() {
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -372,7 +372,7 @@ Key128 DeriveKeyblobMACKey(const Key128& keyblob_key, const Key128& mac_source)
|
||||||
|
|
||||||
std::optional<Key128> DeriveSDSeed() {
|
std::optional<Key128> DeriveSDSeed() {
|
||||||
const auto system_save_43_path =
|
const auto system_save_43_path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000043";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000043";
|
||||||
const Common::FS::IOFile save_43{system_save_43_path, Common::FS::FileAccessMode::Read,
|
const Common::FS::IOFile save_43{system_save_43_path, Common::FS::FileAccessMode::Read,
|
||||||
Common::FS::FileType::BinaryFile};
|
Common::FS::FileType::BinaryFile};
|
||||||
|
|
||||||
|
@ -381,7 +381,7 @@ std::optional<Key128> DeriveSDSeed() {
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto sd_private_path =
|
const auto sd_private_path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::SDMCDir) / "Nintendo/Contents/private";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::SDMCDir) / "Nintendo/Contents/private";
|
||||||
|
|
||||||
const Common::FS::IOFile sd_private{sd_private_path, Common::FS::FileAccessMode::Read,
|
const Common::FS::IOFile sd_private{sd_private_path, Common::FS::FileAccessMode::Read,
|
||||||
Common::FS::FileType::BinaryFile};
|
Common::FS::FileType::BinaryFile};
|
||||||
|
@ -640,7 +640,7 @@ KeyManager::KeyManager() {
|
||||||
|
|
||||||
void KeyManager::ReloadKeys() {
|
void KeyManager::ReloadKeys() {
|
||||||
// Initialize keys
|
// Initialize keys
|
||||||
const auto yuzu_keys_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::KeysDir);
|
const auto yuzu_keys_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::KeysDir);
|
||||||
|
|
||||||
if (!Common::FS::CreateDir(yuzu_keys_dir)) {
|
if (!Common::FS::CreateDir(yuzu_keys_dir)) {
|
||||||
LOG_ERROR(Core, "Failed to create the keys directory.");
|
LOG_ERROR(Core, "Failed to create the keys directory.");
|
||||||
|
@ -861,7 +861,7 @@ void KeyManager::SetKey(S256KeyType id, Key256 key, u64 field1, u64 field2) {
|
||||||
}
|
}
|
||||||
|
|
||||||
bool KeyManager::KeyFileExists(bool title) {
|
bool KeyManager::KeyFileExists(bool title) {
|
||||||
const auto yuzu_keys_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::KeysDir);
|
const auto yuzu_keys_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::KeysDir);
|
||||||
|
|
||||||
if (title) {
|
if (title) {
|
||||||
return Common::FS::Exists(yuzu_keys_dir / "title.keys");
|
return Common::FS::Exists(yuzu_keys_dir / "title.keys");
|
||||||
|
@ -1108,7 +1108,7 @@ void KeyManager::PopulateTickets() {
|
||||||
std::vector<Ticket> tickets;
|
std::vector<Ticket> tickets;
|
||||||
|
|
||||||
const auto system_save_e1_path =
|
const auto system_save_e1_path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/80000000000000e1";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/80000000000000e1";
|
||||||
if (Common::FS::Exists(system_save_e1_path)) {
|
if (Common::FS::Exists(system_save_e1_path)) {
|
||||||
const Common::FS::IOFile save_e1{system_save_e1_path, Common::FS::FileAccessMode::Read,
|
const Common::FS::IOFile save_e1{system_save_e1_path, Common::FS::FileAccessMode::Read,
|
||||||
Common::FS::FileType::BinaryFile};
|
Common::FS::FileType::BinaryFile};
|
||||||
|
@ -1117,7 +1117,7 @@ void KeyManager::PopulateTickets() {
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto system_save_e2_path =
|
const auto system_save_e2_path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/80000000000000e2";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/80000000000000e2";
|
||||||
if (Common::FS::Exists(system_save_e2_path)) {
|
if (Common::FS::Exists(system_save_e2_path)) {
|
||||||
const Common::FS::IOFile save_e2{system_save_e2_path, Common::FS::FileAccessMode::Read,
|
const Common::FS::IOFile save_e2{system_save_e2_path, Common::FS::FileAccessMode::Read,
|
||||||
Common::FS::FileType::BinaryFile};
|
Common::FS::FileType::BinaryFile};
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <fmt/format.h>
|
#include <fmt/format.h>
|
||||||
|
@ -83,7 +83,7 @@ VirtualFile BISFactory::OpenPartitionStorage(BisPartitionId id,
|
||||||
VirtualFilesystem file_system) const {
|
VirtualFilesystem file_system) const {
|
||||||
auto& keys = Core::Crypto::KeyManager::Instance();
|
auto& keys = Core::Crypto::KeyManager::Instance();
|
||||||
Core::Crypto::PartitionDataManager pdm{file_system->OpenDirectory(
|
Core::Crypto::PartitionDataManager pdm{file_system->OpenDirectory(
|
||||||
Common::FS::GetYuzuPathString(Common::FS::YuzuPath::NANDDir), OpenMode::Read)};
|
Common::FS::GetSuyuPathString(Common::FS::SuyuPath::NANDDir), OpenMode::Read)};
|
||||||
keys.PopulateFromPartitionData(pdm);
|
keys.PopulateFromPartitionData(pdm);
|
||||||
|
|
||||||
switch (id) {
|
switch (id) {
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -36,7 +36,7 @@ namespace Service::Account {
|
||||||
constexpr std::size_t THUMBNAIL_SIZE = 0x24000;
|
constexpr std::size_t THUMBNAIL_SIZE = 0x24000;
|
||||||
|
|
||||||
static std::filesystem::path GetImagePath(const Common::UUID& uuid) {
|
static std::filesystem::path GetImagePath(const Common::UUID& uuid) {
|
||||||
return Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) /
|
return Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) /
|
||||||
fmt::format("system/save/8000000000000010/su/avators/{}.jpg", uuid.FormattedString());
|
fmt::format("system/save/8000000000000010/su/avators/{}.jpg", uuid.FormattedString());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
|
@ -377,7 +377,7 @@ bool ProfileManager::SetProfileBaseAndData(Common::UUID uuid, const ProfileBase&
|
||||||
}
|
}
|
||||||
|
|
||||||
void ProfileManager::ParseUserSaveFile() {
|
void ProfileManager::ParseUserSaveFile() {
|
||||||
const auto save_path(FS::GetYuzuPath(FS::YuzuPath::NANDDir) / ACC_SAVE_AVATORS_BASE_PATH /
|
const auto save_path(FS::GetSuyuPath(FS::SuyuPath::NANDDir) / ACC_SAVE_AVATORS_BASE_PATH /
|
||||||
"profiles.dat");
|
"profiles.dat");
|
||||||
const FS::IOFile save(save_path, FS::FileAccessMode::Read, FS::FileType::BinaryFile);
|
const FS::IOFile save(save_path, FS::FileAccessMode::Read, FS::FileType::BinaryFile);
|
||||||
|
|
||||||
|
@ -429,12 +429,12 @@ void ProfileManager::WriteUserSaveFile() {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto raw_path(FS::GetYuzuPath(FS::YuzuPath::NANDDir) / "system/save/8000000000000010");
|
const auto raw_path(FS::GetSuyuPath(FS::SuyuPath::NANDDir) / "system/save/8000000000000010");
|
||||||
if (FS::IsFile(raw_path) && !FS::RemoveFile(raw_path)) {
|
if (FS::IsFile(raw_path) && !FS::RemoveFile(raw_path)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto save_path(FS::GetYuzuPath(FS::YuzuPath::NANDDir) / ACC_SAVE_AVATORS_BASE_PATH /
|
const auto save_path(FS::GetSuyuPath(FS::SuyuPath::NANDDir) / ACC_SAVE_AVATORS_BASE_PATH /
|
||||||
"profiles.dat");
|
"profiles.dat");
|
||||||
|
|
||||||
if (!FS::CreateParentDirs(save_path)) {
|
if (!FS::CreateParentDirs(save_path)) {
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include "common/assert.h"
|
#include "common/assert.h"
|
||||||
|
@ -155,7 +155,7 @@ void ExtractSharedFonts(Core::System& system) {
|
||||||
"FontNintendoExtended2.ttf",
|
"FontNintendoExtended2.ttf",
|
||||||
};
|
};
|
||||||
|
|
||||||
const auto fonts_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) / "fonts";
|
const auto fonts_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) / "fonts";
|
||||||
|
|
||||||
for (std::size_t i = 0; i < NS::SHARED_FONTS.size(); ++i) {
|
for (std::size_t i = 0; i < NS::SHARED_FONTS.size(); ++i) {
|
||||||
const auto font_file_path = fonts_dir / DECRYPTED_SHARED_FONTS[i];
|
const auto font_file_path = fonts_dir / DECRYPTED_SHARED_FONTS[i];
|
||||||
|
@ -415,7 +415,7 @@ void WebBrowser::InitializeOffline() {
|
||||||
"system_data",
|
"system_data",
|
||||||
};
|
};
|
||||||
|
|
||||||
offline_cache_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) /
|
offline_cache_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) /
|
||||||
fmt::format("offline_web_applet_{}/{:016X}",
|
fmt::format("offline_web_applet_{}/{:016X}",
|
||||||
RESOURCE_TYPES[static_cast<u32>(document_kind) - 1], title_id);
|
RESOURCE_TYPES[static_cast<u32>(document_kind) - 1], title_id);
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2023 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2023 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <sstream>
|
#include <sstream>
|
||||||
|
@ -303,7 +303,7 @@ void AlbumManager::FindScreenshots() {
|
||||||
album_files.clear();
|
album_files.clear();
|
||||||
|
|
||||||
// TODO: Swap this with a blocking operation.
|
// TODO: Swap this with a blocking operation.
|
||||||
const auto screenshots_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::ScreenshotsDir);
|
const auto screenshots_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::ScreenshotsDir);
|
||||||
Common::FS::IterateDirEntries(
|
Common::FS::IterateDirEntries(
|
||||||
screenshots_dir,
|
screenshots_dir,
|
||||||
[this](const std::filesystem::path& full_path) {
|
[this](const std::filesystem::path& full_path) {
|
||||||
|
@ -438,7 +438,7 @@ static void PNGToMemory(void* context, void* data, int len) {
|
||||||
Result AlbumManager::SaveImage(ApplicationAlbumEntry& out_entry, std::span<const u8> image,
|
Result AlbumManager::SaveImage(ApplicationAlbumEntry& out_entry, std::span<const u8> image,
|
||||||
u64 title_id, const AlbumFileDateTime& date) const {
|
u64 title_id, const AlbumFileDateTime& date) const {
|
||||||
const auto screenshot_path =
|
const auto screenshot_path =
|
||||||
Common::FS::GetYuzuPathString(Common::FS::YuzuPath::ScreenshotsDir);
|
Common::FS::GetSuyuPathString(Common::FS::SuyuPath::ScreenshotsDir);
|
||||||
const std::string formatted_date =
|
const std::string formatted_date =
|
||||||
fmt::format("{:04}-{:02}-{:02}_{:02}-{:02}-{:02}-{:03}", date.year, date.month, date.day,
|
fmt::format("{:04}-{:02}-{:02}_{:02}-{:02}-{:02}-{:03}", date.year, date.month, date.day,
|
||||||
date.hour, date.minute, date.second, 0);
|
date.hour, date.minute, date.second, 0);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
@ -346,12 +346,12 @@ std::shared_ptr<SaveDataController> FileSystemController::OpenSaveDataController
|
||||||
|
|
||||||
std::shared_ptr<FileSys::SaveDataFactory> FileSystemController::CreateSaveDataFactory(
|
std::shared_ptr<FileSys::SaveDataFactory> FileSystemController::CreateSaveDataFactory(
|
||||||
ProgramId program_id) {
|
ProgramId program_id) {
|
||||||
using YuzuPath = Common::FS::YuzuPath;
|
using SuyuPath = Common::FS::SuyuPath;
|
||||||
const auto rw_mode = FileSys::OpenMode::ReadWrite;
|
const auto rw_mode = FileSys::OpenMode::ReadWrite;
|
||||||
|
|
||||||
auto vfs = system.GetFilesystem();
|
auto vfs = system.GetFilesystem();
|
||||||
const auto nand_directory =
|
const auto nand_directory =
|
||||||
vfs->OpenDirectory(Common::FS::GetYuzuPathString(YuzuPath::NANDDir), rw_mode);
|
vfs->OpenDirectory(Common::FS::GetSuyuPathString(SuyuPath::NANDDir), rw_mode);
|
||||||
return std::make_shared<FileSys::SaveDataFactory>(system, program_id,
|
return std::make_shared<FileSys::SaveDataFactory>(system, program_id,
|
||||||
std::move(nand_directory));
|
std::move(nand_directory));
|
||||||
}
|
}
|
||||||
|
@ -683,20 +683,20 @@ void FileSystemController::CreateFactories(FileSys::VfsFilesystem& vfs, bool ove
|
||||||
sdmc_factory = nullptr;
|
sdmc_factory = nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
using YuzuPath = Common::FS::YuzuPath;
|
using SuyuPath = Common::FS::SuyuPath;
|
||||||
const auto sdmc_dir_path = Common::FS::GetYuzuPath(YuzuPath::SDMCDir);
|
const auto sdmc_dir_path = Common::FS::GetSuyuPath(SuyuPath::SDMCDir);
|
||||||
const auto sdmc_load_dir_path = sdmc_dir_path / "atmosphere/contents";
|
const auto sdmc_load_dir_path = sdmc_dir_path / "atmosphere/contents";
|
||||||
const auto rw_mode = FileSys::OpenMode::ReadWrite;
|
const auto rw_mode = FileSys::OpenMode::ReadWrite;
|
||||||
|
|
||||||
auto nand_directory =
|
auto nand_directory =
|
||||||
vfs.OpenDirectory(Common::FS::GetYuzuPathString(YuzuPath::NANDDir), rw_mode);
|
vfs.OpenDirectory(Common::FS::GetSuyuPathString(SuyuPath::NANDDir), rw_mode);
|
||||||
auto sd_directory = vfs.OpenDirectory(Common::FS::PathToUTF8String(sdmc_dir_path), rw_mode);
|
auto sd_directory = vfs.OpenDirectory(Common::FS::PathToUTF8String(sdmc_dir_path), rw_mode);
|
||||||
auto load_directory = vfs.OpenDirectory(Common::FS::GetYuzuPathString(YuzuPath::LoadDir),
|
auto load_directory = vfs.OpenDirectory(Common::FS::GetSuyuPathString(SuyuPath::LoadDir),
|
||||||
FileSys::OpenMode::Read);
|
FileSys::OpenMode::Read);
|
||||||
auto sd_load_directory = vfs.OpenDirectory(Common::FS::PathToUTF8String(sdmc_load_dir_path),
|
auto sd_load_directory = vfs.OpenDirectory(Common::FS::PathToUTF8String(sdmc_load_dir_path),
|
||||||
FileSys::OpenMode::Read);
|
FileSys::OpenMode::Read);
|
||||||
auto dump_directory =
|
auto dump_directory =
|
||||||
vfs.OpenDirectory(Common::FS::GetYuzuPathString(YuzuPath::DumpDir), rw_mode);
|
vfs.OpenDirectory(Common::FS::GetSuyuPathString(SuyuPath::DumpDir), rw_mode);
|
||||||
|
|
||||||
if (bis_factory == nullptr) {
|
if (bis_factory == nullptr) {
|
||||||
bis_factory = std::make_unique<FileSys::BISFactory>(
|
bis_factory = std::make_unique<FileSys::BISFactory>(
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2023 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2023 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include "common/assert.h"
|
#include "common/assert.h"
|
||||||
|
@ -22,9 +22,9 @@ DatabaseManager::DatabaseManager() {}
|
||||||
Result DatabaseManager::MountSaveData() {
|
Result DatabaseManager::MountSaveData() {
|
||||||
if (!is_save_data_mounted) {
|
if (!is_save_data_mounted) {
|
||||||
system_save_dir =
|
system_save_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000030";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000030";
|
||||||
if (is_test_db) {
|
if (is_test_db) {
|
||||||
system_save_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) /
|
system_save_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) /
|
||||||
"system/save/8000000000000031";
|
"system/save/8000000000000031";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-3.0-or-later
|
// SPDX-License-Identifier: GPL-3.0-or-later
|
||||||
|
|
||||||
// SPDX-FileCopyrightText: Copyright 2017 socram8888/amiitool
|
// SPDX-FileCopyrightText: Copyright 2017 socram8888/amiitool
|
||||||
|
@ -271,7 +271,7 @@ void Cipher(const DerivedKeys& keys, const NTAG215File& in_data, NTAG215File& ou
|
||||||
}
|
}
|
||||||
|
|
||||||
bool LoadKeys(InternalKey& locked_secret, InternalKey& unfixed_info) {
|
bool LoadKeys(InternalKey& locked_secret, InternalKey& unfixed_info) {
|
||||||
const auto yuzu_keys_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::KeysDir);
|
const auto yuzu_keys_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::KeysDir);
|
||||||
|
|
||||||
const Common::FS::IOFile keys_file{yuzu_keys_dir / "key_retail.bin",
|
const Common::FS::IOFile keys_file{yuzu_keys_dir / "key_retail.bin",
|
||||||
Common::FS::FileAccessMode::Read,
|
Common::FS::FileAccessMode::Read,
|
||||||
|
@ -295,7 +295,7 @@ bool LoadKeys(InternalKey& locked_secret, InternalKey& unfixed_info) {
|
||||||
}
|
}
|
||||||
|
|
||||||
bool IsKeyAvailable() {
|
bool IsKeyAvailable() {
|
||||||
const auto yuzu_keys_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::KeysDir);
|
const auto yuzu_keys_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::KeysDir);
|
||||||
return Common::FS::Exists(yuzu_keys_dir / "key_retail.bin");
|
return Common::FS::Exists(yuzu_keys_dir / "key_retail.bin");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include "core/hle/service/glue/time/static.h"
|
#include "core/hle/service/glue/time/static.h"
|
||||||
|
@ -1261,7 +1261,7 @@ Result NfcDevice::BreakTag(NFP::BreakType break_type) {
|
||||||
Result NfcDevice::HasBackup(const UniqueSerialNumber& uid, std::size_t uuid_size) const {
|
Result NfcDevice::HasBackup(const UniqueSerialNumber& uid, std::size_t uuid_size) const {
|
||||||
ASSERT_MSG(uuid_size < sizeof(UniqueSerialNumber), "Invalid UUID size");
|
ASSERT_MSG(uuid_size < sizeof(UniqueSerialNumber), "Invalid UUID size");
|
||||||
constexpr auto backup_dir = "backup";
|
constexpr auto backup_dir = "backup";
|
||||||
const auto yuzu_amiibo_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::AmiiboDir);
|
const auto yuzu_amiibo_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::AmiiboDir);
|
||||||
const auto file_name =
|
const auto file_name =
|
||||||
fmt::format("{0:02x}.bin", fmt::join(uid.begin(), uid.begin() + uuid_size, ""));
|
fmt::format("{0:02x}.bin", fmt::join(uid.begin(), uid.begin() + uuid_size, ""));
|
||||||
|
|
||||||
|
@ -1282,7 +1282,7 @@ Result NfcDevice::ReadBackupData(const UniqueSerialNumber& uid, std::size_t uuid
|
||||||
std::span<u8> data) const {
|
std::span<u8> data) const {
|
||||||
ASSERT_MSG(uuid_size < sizeof(UniqueSerialNumber), "Invalid UUID size");
|
ASSERT_MSG(uuid_size < sizeof(UniqueSerialNumber), "Invalid UUID size");
|
||||||
constexpr auto backup_dir = "backup";
|
constexpr auto backup_dir = "backup";
|
||||||
const auto yuzu_amiibo_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::AmiiboDir);
|
const auto yuzu_amiibo_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::AmiiboDir);
|
||||||
const auto file_name =
|
const auto file_name =
|
||||||
fmt::format("{0:02x}.bin", fmt::join(uid.begin(), uid.begin() + uuid_size, ""));
|
fmt::format("{0:02x}.bin", fmt::join(uid.begin(), uid.begin() + uuid_size, ""));
|
||||||
|
|
||||||
|
@ -1313,7 +1313,7 @@ Result NfcDevice::WriteBackupData(const UniqueSerialNumber& uid, std::size_t uui
|
||||||
std::span<const u8> data) {
|
std::span<const u8> data) {
|
||||||
ASSERT_MSG(uuid_size < sizeof(UniqueSerialNumber), "Invalid UUID size");
|
ASSERT_MSG(uuid_size < sizeof(UniqueSerialNumber), "Invalid UUID size");
|
||||||
constexpr auto backup_dir = "backup";
|
constexpr auto backup_dir = "backup";
|
||||||
const auto yuzu_amiibo_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::AmiiboDir);
|
const auto yuzu_amiibo_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::AmiiboDir);
|
||||||
const auto file_name =
|
const auto file_name =
|
||||||
fmt::format("{0:02x}.bin", fmt::join(uid.begin(), uid.begin() + uuid_size, ""));
|
fmt::format("{0:02x}.bin", fmt::join(uid.begin(), uid.begin() + uuid_size, ""));
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
|
@ -1308,25 +1308,25 @@ Result ISystemSettingsServer::SetPanelCrcMode(s32 panel_crc_mode) {
|
||||||
|
|
||||||
void ISystemSettingsServer::SetupSettings() {
|
void ISystemSettingsServer::SetupSettings() {
|
||||||
auto system_dir =
|
auto system_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000050";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000050";
|
||||||
if (!LoadSettingsFile(system_dir, []() { return DefaultSystemSettings(); })) {
|
if (!LoadSettingsFile(system_dir, []() { return DefaultSystemSettings(); })) {
|
||||||
ASSERT(false);
|
ASSERT(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
auto private_dir =
|
auto private_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000052";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000052";
|
||||||
if (!LoadSettingsFile(private_dir, []() { return DefaultPrivateSettings(); })) {
|
if (!LoadSettingsFile(private_dir, []() { return DefaultPrivateSettings(); })) {
|
||||||
ASSERT(false);
|
ASSERT(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
auto device_dir =
|
auto device_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000053";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000053";
|
||||||
if (!LoadSettingsFile(device_dir, []() { return DefaultDeviceSettings(); })) {
|
if (!LoadSettingsFile(device_dir, []() { return DefaultDeviceSettings(); })) {
|
||||||
ASSERT(false);
|
ASSERT(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
auto appln_dir =
|
auto appln_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000054";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000054";
|
||||||
if (!LoadSettingsFile(appln_dir, []() { return DefaultApplnSettings(); })) {
|
if (!LoadSettingsFile(appln_dir, []() { return DefaultApplnSettings(); })) {
|
||||||
ASSERT(false);
|
ASSERT(false);
|
||||||
}
|
}
|
||||||
|
@ -1334,25 +1334,25 @@ void ISystemSettingsServer::SetupSettings() {
|
||||||
|
|
||||||
void ISystemSettingsServer::StoreSettings() {
|
void ISystemSettingsServer::StoreSettings() {
|
||||||
auto system_dir =
|
auto system_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000050";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000050";
|
||||||
if (!StoreSettingsFile(system_dir, m_system_settings)) {
|
if (!StoreSettingsFile(system_dir, m_system_settings)) {
|
||||||
LOG_ERROR(Service_SET, "Failed to store System settings");
|
LOG_ERROR(Service_SET, "Failed to store System settings");
|
||||||
}
|
}
|
||||||
|
|
||||||
auto private_dir =
|
auto private_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000052";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000052";
|
||||||
if (!StoreSettingsFile(private_dir, m_private_settings)) {
|
if (!StoreSettingsFile(private_dir, m_private_settings)) {
|
||||||
LOG_ERROR(Service_SET, "Failed to store Private settings");
|
LOG_ERROR(Service_SET, "Failed to store Private settings");
|
||||||
}
|
}
|
||||||
|
|
||||||
auto device_dir =
|
auto device_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000053";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000053";
|
||||||
if (!StoreSettingsFile(device_dir, m_device_settings)) {
|
if (!StoreSettingsFile(device_dir, m_device_settings)) {
|
||||||
LOG_ERROR(Service_SET, "Failed to store Device settings");
|
LOG_ERROR(Service_SET, "Failed to store Device settings");
|
||||||
}
|
}
|
||||||
|
|
||||||
auto appln_dir =
|
auto appln_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000054";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000054";
|
||||||
if (!StoreSettingsFile(appln_dir, m_appln_settings)) {
|
if (!StoreSettingsFile(appln_dir, m_appln_settings)) {
|
||||||
LOG_ERROR(Service_SET, "Failed to store ApplLn settings");
|
LOG_ERROR(Service_SET, "Failed to store ApplLn settings");
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -12,7 +12,7 @@
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
#include <winsock2.h>
|
#include <winsock2.h>
|
||||||
#include <ws2tcpip.h>
|
#include <ws2tcpip.h>
|
||||||
#elif YUZU_UNIX
|
#elif SUYU_UNIX
|
||||||
#include <arpa/inet.h>
|
#include <arpa/inet.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
|
@ -77,7 +77,7 @@ SOCKET GetInterruptSocket() {
|
||||||
sockaddr TranslateFromSockAddrIn(SockAddrIn input) {
|
sockaddr TranslateFromSockAddrIn(SockAddrIn input) {
|
||||||
sockaddr_in result;
|
sockaddr_in result;
|
||||||
|
|
||||||
#if YUZU_UNIX
|
#if SUYU_UNIX
|
||||||
result.sin_len = sizeof(result);
|
result.sin_len = sizeof(result);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -162,7 +162,7 @@ Errno TranslateNativeError(int e, CallType call_type = CallType::Other) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#elif YUZU_UNIX // ^ _WIN32 v YUZU_UNIX
|
#elif SUYU_UNIX // ^ _WIN32 v SUYU_UNIX
|
||||||
|
|
||||||
using SOCKET = int;
|
using SOCKET = int;
|
||||||
using WSAPOLLFD = pollfd;
|
using WSAPOLLFD = pollfd;
|
||||||
|
@ -835,7 +835,7 @@ std::pair<s32, Errno> Socket::Send(std::span<const u8> message, int flags) {
|
||||||
ASSERT(flags == 0);
|
ASSERT(flags == 0);
|
||||||
|
|
||||||
int native_flags = 0;
|
int native_flags = 0;
|
||||||
#if YUZU_UNIX
|
#if SUYU_UNIX
|
||||||
native_flags |= MSG_NOSIGNAL; // do not send us SIGPIPE
|
native_flags |= MSG_NOSIGNAL; // do not send us SIGPIPE
|
||||||
#endif
|
#endif
|
||||||
const auto result = send(fd, reinterpret_cast<const char*>(message.data()),
|
const auto result = send(fd, reinterpret_cast<const char*>(message.data()),
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
@ -13,7 +13,7 @@
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
#include <winsock2.h>
|
#include <winsock2.h>
|
||||||
#elif YUZU_UNIX
|
#elif SUYU_UNIX
|
||||||
#include <netinet/in.h>
|
#include <netinet/in.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -104,7 +104,7 @@ constexpr IPv4Address TranslateIPv4(in_addr addr) {
|
||||||
auto& bytes = addr.S_un.S_un_b;
|
auto& bytes = addr.S_un.S_un_b;
|
||||||
return IPv4Address{bytes.s_b1, bytes.s_b2, bytes.s_b3, bytes.s_b4};
|
return IPv4Address{bytes.s_b1, bytes.s_b2, bytes.s_b3, bytes.s_b4};
|
||||||
}
|
}
|
||||||
#elif YUZU_UNIX
|
#elif SUYU_UNIX
|
||||||
constexpr IPv4Address TranslateIPv4(in_addr addr) {
|
constexpr IPv4Address TranslateIPv4(in_addr addr) {
|
||||||
const u32 bytes = addr.s_addr;
|
const u32 bytes = addr.s_addr;
|
||||||
return IPv4Address{static_cast<u8>(bytes), static_cast<u8>(bytes >> 8),
|
return IPv4Address{static_cast<u8>(bytes), static_cast<u8>(bytes >> 8),
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <chrono>
|
#include <chrono>
|
||||||
|
@ -12,7 +12,7 @@
|
||||||
#include "core/internal_network/socket_proxy.h"
|
#include "core/internal_network/socket_proxy.h"
|
||||||
#include "network/network.h"
|
#include "network/network.h"
|
||||||
|
|
||||||
#if YUZU_UNIX
|
#if SUYU_UNIX
|
||||||
#include <sys/socket.h>
|
#include <sys/socket.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
@ -9,7 +9,7 @@
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
|
||||||
#if defined(_WIN32)
|
#if defined(_WIN32)
|
||||||
#elif !YUZU_UNIX
|
#elif !SUYU_UNIX
|
||||||
#error "Platform not implemented"
|
#error "Platform not implemented"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -24,7 +24,7 @@ struct ProxyPacket;
|
||||||
|
|
||||||
class SocketBase {
|
class SocketBase {
|
||||||
public:
|
public:
|
||||||
#ifdef YUZU_UNIX
|
#ifdef SUYU_UNIX
|
||||||
using SOCKET = int;
|
using SOCKET = int;
|
||||||
static constexpr SOCKET INVALID_SOCKET = -1;
|
static constexpr SOCKET INVALID_SOCKET = -1;
|
||||||
static constexpr SOCKET SOCKET_ERROR = -1;
|
static constexpr SOCKET SOCKET_ERROR = -1;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2017 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2017 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -39,7 +39,7 @@ PerfStats::~PerfStats() {
|
||||||
std::copy(perf_history.begin() + IgnoreFrames, perf_history.begin() + current_index,
|
std::copy(perf_history.begin() + IgnoreFrames, perf_history.begin() + current_index,
|
||||||
std::ostream_iterator<double>(stream, "\n"));
|
std::ostream_iterator<double>(stream, "\n"));
|
||||||
|
|
||||||
const auto path = Common::FS::GetYuzuPath(Common::FS::YuzuPath::LogDir);
|
const auto path = Common::FS::GetSuyuPath(Common::FS::SuyuPath::LogDir);
|
||||||
// %F Date format expanded is "%Y-%m-%d"
|
// %F Date format expanded is "%Y-%m-%d"
|
||||||
const auto filename = fmt::format("{:%F-%H-%M}_{:016X}.csv", *std::localtime(&t), title_id);
|
const auto filename = fmt::format("{:%F-%H-%M}_{:016X}.csv", *std::localtime(&t), title_id);
|
||||||
const auto filepath = path / filename;
|
const auto filepath = path / filename;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <ctime>
|
#include <ctime>
|
||||||
|
@ -27,7 +27,7 @@
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
std::filesystem::path GetPath(std::string_view type, u64 title_id, std::string_view timestamp) {
|
std::filesystem::path GetPath(std::string_view type, u64 title_id, std::string_view timestamp) {
|
||||||
return Common::FS::GetYuzuPath(Common::FS::YuzuPath::LogDir) / type /
|
return Common::FS::GetSuyuPath(Common::FS::SuyuPath::LogDir) / type /
|
||||||
fmt::format("{:016X}_{}.json", title_id, timestamp);
|
fmt::format("{:016X}_{}.json", title_id, timestamp);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -332,7 +332,7 @@ void Reporter::SaveErrorReport(u64 title_id, Result result,
|
||||||
|
|
||||||
void Reporter::SaveFSAccessLog(std::string_view log_message) const {
|
void Reporter::SaveFSAccessLog(std::string_view log_message) const {
|
||||||
const auto access_log_path =
|
const auto access_log_path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::SDMCDir) / "FsAccessLog.txt";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::SDMCDir) / "FsAccessLog.txt";
|
||||||
|
|
||||||
void(Common::FS::AppendStringToFile(access_log_path, Common::FS::FileType::TextFile,
|
void(Common::FS::AppendStringToFile(access_log_path, Common::FS::FileType::TextFile,
|
||||||
log_message));
|
log_message));
|
||||||
|
@ -352,7 +352,7 @@ void Reporter::SaveUserReport() const {
|
||||||
|
|
||||||
void Reporter::ClearFSAccessLog() const {
|
void Reporter::ClearFSAccessLog() const {
|
||||||
const auto access_log_path =
|
const auto access_log_path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::SDMCDir) / "FsAccessLog.txt";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::SDMCDir) / "FsAccessLog.txt";
|
||||||
|
|
||||||
Common::FS::IOFile access_log_file{access_log_path, Common::FS::FileAccessMode::Write,
|
Common::FS::IOFile access_log_file{access_log_path, Common::FS::FileAccessMode::Write,
|
||||||
Common::FS::FileType::TextFile};
|
Common::FS::FileType::TextFile};
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2017 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2017 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <array>
|
#include <array>
|
||||||
|
@ -114,7 +114,7 @@ static constexpr const char* TranslateASTCDecodeMode(Settings::AstcDecodeMode mo
|
||||||
|
|
||||||
u64 GetTelemetryId() {
|
u64 GetTelemetryId() {
|
||||||
u64 telemetry_id{};
|
u64 telemetry_id{};
|
||||||
const auto filename = Common::FS::GetYuzuPath(Common::FS::YuzuPath::ConfigDir) / "telemetry_id";
|
const auto filename = Common::FS::GetSuyuPath(Common::FS::SuyuPath::ConfigDir) / "telemetry_id";
|
||||||
|
|
||||||
bool generate_new_id = !Common::FS::Exists(filename);
|
bool generate_new_id = !Common::FS::Exists(filename);
|
||||||
|
|
||||||
|
@ -156,7 +156,7 @@ u64 GetTelemetryId() {
|
||||||
|
|
||||||
u64 RegenerateTelemetryId() {
|
u64 RegenerateTelemetryId() {
|
||||||
const u64 new_telemetry_id{GenerateTelemetryId()};
|
const u64 new_telemetry_id{GenerateTelemetryId()};
|
||||||
const auto filename = Common::FS::GetYuzuPath(Common::FS::YuzuPath::ConfigDir) / "telemetry_id";
|
const auto filename = Common::FS::GetSuyuPath(Common::FS::SuyuPath::ConfigDir) / "telemetry_id";
|
||||||
|
|
||||||
Common::FS::IOFile file{filename, Common::FS::FileAccessMode::Write,
|
Common::FS::IOFile file{filename, Common::FS::FileAccessMode::Write,
|
||||||
Common::FS::FileType::BinaryFile};
|
Common::FS::FileType::BinaryFile};
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
// SPDX-FileCopyrightText: 2017 Citra Emulator Project & 2024 suyu Emulator Project
|
// SPDX-FileCopyrightText: 2017 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
// Modified by JuanCStar on 2024/03/06
|
|
||||||
|
|
||||||
#include "winresrc.h"
|
#include "winresrc.h"
|
||||||
/////////////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////////////
|
||||||
//
|
//
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project
|
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -25,7 +25,7 @@ Config::Config(const ConfigType config_type)
|
||||||
: type(config_type), global{config_type == ConfigType::GlobalConfig} {}
|
: type(config_type), global{config_type == ConfigType::GlobalConfig} {}
|
||||||
|
|
||||||
void Config::Initialize(const std::string& config_name) {
|
void Config::Initialize(const std::string& config_name) {
|
||||||
const std::filesystem::path fs_config_loc = FS::GetYuzuPath(FS::YuzuPath::ConfigDir);
|
const std::filesystem::path fs_config_loc = FS::GetSuyuPath(FS::SuyuPath::ConfigDir);
|
||||||
const auto config_file = fmt::format("{}.ini", config_name);
|
const auto config_file = fmt::format("{}.ini", config_name);
|
||||||
|
|
||||||
switch (type) {
|
switch (type) {
|
||||||
|
@ -51,7 +51,7 @@ void Config::Initialize(const std::string& config_name) {
|
||||||
|
|
||||||
void Config::Initialize(const std::optional<std::string> config_path) {
|
void Config::Initialize(const std::optional<std::string> config_path) {
|
||||||
const std::filesystem::path default_sdl_config_path =
|
const std::filesystem::path default_sdl_config_path =
|
||||||
FS::GetYuzuPath(FS::YuzuPath::ConfigDir) / "sdl2-config.ini";
|
FS::GetSuyuPath(FS::SuyuPath::ConfigDir) / "sdl2-config.ini";
|
||||||
config_loc = config_path.value_or(FS::PathToUTF8String(default_sdl_config_path));
|
config_loc = config_path.value_or(FS::PathToUTF8String(default_sdl_config_path));
|
||||||
void(FS::CreateParentDir(config_loc));
|
void(FS::CreateParentDir(config_loc));
|
||||||
SetUpIni();
|
SetUpIni();
|
||||||
|
@ -275,11 +275,11 @@ void Config::ReadCoreValues() {
|
||||||
void Config::ReadDataStorageValues() {
|
void Config::ReadDataStorageValues() {
|
||||||
BeginGroup(Settings::TranslateCategory(Settings::Category::DataStorage));
|
BeginGroup(Settings::TranslateCategory(Settings::Category::DataStorage));
|
||||||
|
|
||||||
FS::SetYuzuPath(FS::YuzuPath::NANDDir, ReadStringSetting(std::string("nand_directory")));
|
FS::SetSuyuPath(FS::SuyuPath::NANDDir, ReadStringSetting(std::string("nand_directory")));
|
||||||
FS::SetYuzuPath(FS::YuzuPath::SDMCDir, ReadStringSetting(std::string("sdmc_directory")));
|
FS::SetSuyuPath(FS::SuyuPath::SDMCDir, ReadStringSetting(std::string("sdmc_directory")));
|
||||||
FS::SetYuzuPath(FS::YuzuPath::LoadDir, ReadStringSetting(std::string("load_directory")));
|
FS::SetSuyuPath(FS::SuyuPath::LoadDir, ReadStringSetting(std::string("load_directory")));
|
||||||
FS::SetYuzuPath(FS::YuzuPath::DumpDir, ReadStringSetting(std::string("dump_directory")));
|
FS::SetSuyuPath(FS::SuyuPath::DumpDir, ReadStringSetting(std::string("dump_directory")));
|
||||||
FS::SetYuzuPath(FS::YuzuPath::TASDir, ReadStringSetting(std::string("tas_directory")));
|
FS::SetSuyuPath(FS::SuyuPath::TASDir, ReadStringSetting(std::string("tas_directory")));
|
||||||
|
|
||||||
ReadCategory(Settings::Category::DataStorage);
|
ReadCategory(Settings::Category::DataStorage);
|
||||||
|
|
||||||
|
@ -371,7 +371,7 @@ void Config::ReadScreenshotValues() {
|
||||||
BeginGroup(Settings::TranslateCategory(Settings::Category::Screenshots));
|
BeginGroup(Settings::TranslateCategory(Settings::Category::Screenshots));
|
||||||
|
|
||||||
ReadCategory(Settings::Category::Screenshots);
|
ReadCategory(Settings::Category::Screenshots);
|
||||||
FS::SetYuzuPath(FS::YuzuPath::ScreenshotsDir,
|
FS::SetSuyuPath(FS::SuyuPath::ScreenshotsDir,
|
||||||
ReadStringSetting(std::string("screenshot_path")));
|
ReadStringSetting(std::string("screenshot_path")));
|
||||||
|
|
||||||
EndGroup();
|
EndGroup();
|
||||||
|
@ -577,16 +577,16 @@ void Config::SaveCoreValues() {
|
||||||
void Config::SaveDataStorageValues() {
|
void Config::SaveDataStorageValues() {
|
||||||
BeginGroup(Settings::TranslateCategory(Settings::Category::DataStorage));
|
BeginGroup(Settings::TranslateCategory(Settings::Category::DataStorage));
|
||||||
|
|
||||||
WriteStringSetting(std::string("nand_directory"), FS::GetYuzuPathString(FS::YuzuPath::NANDDir),
|
WriteStringSetting(std::string("nand_directory"), FS::GetSuyuPathString(FS::SuyuPath::NANDDir),
|
||||||
std::make_optional(FS::GetYuzuPathString(FS::YuzuPath::NANDDir)));
|
std::make_optional(FS::GetSuyuPathString(FS::SuyuPath::NANDDir)));
|
||||||
WriteStringSetting(std::string("sdmc_directory"), FS::GetYuzuPathString(FS::YuzuPath::SDMCDir),
|
WriteStringSetting(std::string("sdmc_directory"), FS::GetSuyuPathString(FS::SuyuPath::SDMCDir),
|
||||||
std::make_optional(FS::GetYuzuPathString(FS::YuzuPath::SDMCDir)));
|
std::make_optional(FS::GetSuyuPathString(FS::SuyuPath::SDMCDir)));
|
||||||
WriteStringSetting(std::string("load_directory"), FS::GetYuzuPathString(FS::YuzuPath::LoadDir),
|
WriteStringSetting(std::string("load_directory"), FS::GetSuyuPathString(FS::SuyuPath::LoadDir),
|
||||||
std::make_optional(FS::GetYuzuPathString(FS::YuzuPath::LoadDir)));
|
std::make_optional(FS::GetSuyuPathString(FS::SuyuPath::LoadDir)));
|
||||||
WriteStringSetting(std::string("dump_directory"), FS::GetYuzuPathString(FS::YuzuPath::DumpDir),
|
WriteStringSetting(std::string("dump_directory"), FS::GetSuyuPathString(FS::SuyuPath::DumpDir),
|
||||||
std::make_optional(FS::GetYuzuPathString(FS::YuzuPath::DumpDir)));
|
std::make_optional(FS::GetSuyuPathString(FS::SuyuPath::DumpDir)));
|
||||||
WriteStringSetting(std::string("tas_directory"), FS::GetYuzuPathString(FS::YuzuPath::TASDir),
|
WriteStringSetting(std::string("tas_directory"), FS::GetSuyuPathString(FS::SuyuPath::TASDir),
|
||||||
std::make_optional(FS::GetYuzuPathString(FS::YuzuPath::TASDir)));
|
std::make_optional(FS::GetSuyuPathString(FS::SuyuPath::TASDir)));
|
||||||
|
|
||||||
WriteCategory(Settings::Category::DataStorage);
|
WriteCategory(Settings::Category::DataStorage);
|
||||||
|
|
||||||
|
@ -679,7 +679,7 @@ void Config::SaveScreenshotValues() {
|
||||||
BeginGroup(Settings::TranslateCategory(Settings::Category::Screenshots));
|
BeginGroup(Settings::TranslateCategory(Settings::Category::Screenshots));
|
||||||
|
|
||||||
WriteStringSetting(std::string("screenshot_path"),
|
WriteStringSetting(std::string("screenshot_path"),
|
||||||
FS::GetYuzuPathString(FS::YuzuPath::ScreenshotsDir));
|
FS::GetSuyuPathString(FS::SuyuPath::ScreenshotsDir));
|
||||||
WriteCategory(Settings::Category::Screenshots);
|
WriteCategory(Settings::Category::Screenshots);
|
||||||
|
|
||||||
EndGroup();
|
EndGroup();
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
|
@ -82,7 +82,7 @@ void Tas::LoadTasFile(size_t player_index, size_t file_index) {
|
||||||
commands[player_index].clear();
|
commands[player_index].clear();
|
||||||
|
|
||||||
std::string file = Common::FS::ReadStringFromFile(
|
std::string file = Common::FS::ReadStringFromFile(
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::TASDir) /
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::TASDir) /
|
||||||
fmt::format("script{}-{}.txt", file_index, player_index + 1),
|
fmt::format("script{}-{}.txt", file_index, player_index + 1),
|
||||||
Common::FS::FileType::BinaryFile);
|
Common::FS::FileType::BinaryFile);
|
||||||
std::istringstream command_line(file);
|
std::istringstream command_line(file);
|
||||||
|
@ -137,7 +137,7 @@ void Tas::WriteTasFile(std::u8string_view file_name) {
|
||||||
WriteCommandAxis(line.l_axis), WriteCommandAxis(line.r_axis));
|
WriteCommandAxis(line.l_axis), WriteCommandAxis(line.r_axis));
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto tas_file_name = Common::FS::GetYuzuPath(Common::FS::YuzuPath::TASDir) / file_name;
|
const auto tas_file_name = Common::FS::GetSuyuPath(Common::FS::SuyuPath::TASDir) / file_name;
|
||||||
const auto bytes_written =
|
const auto bytes_written =
|
||||||
Common::FS::WriteStringToFile(tas_file_name, Common::FS::FileType::TextFile, output_text);
|
Common::FS::WriteStringToFile(tas_file_name, Common::FS::FileType::TextFile, output_text);
|
||||||
if (bytes_written == output_text.size()) {
|
if (bytes_written == output_text.size()) {
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
|
@ -28,7 +28,7 @@ MICROPROFILE_DEFINE(MacroHLE, "GPU", "Execute macro HLE", MP_RGB(128, 192, 192))
|
||||||
namespace Tegra {
|
namespace Tegra {
|
||||||
|
|
||||||
static void Dump(u64 hash, std::span<const u32> code, bool decompiled = false) {
|
static void Dump(u64 hash, std::span<const u32> code, bool decompiled = false) {
|
||||||
const auto base_dir{Common::FS::GetYuzuPath(Common::FS::YuzuPath::DumpDir)};
|
const auto base_dir{Common::FS::GetSuyuPath(Common::FS::SuyuPath::DumpDir)};
|
||||||
const auto macro_dir{base_dir / "macros"};
|
const auto macro_dir{base_dir / "macros"};
|
||||||
if (!Common::FS::CreateDir(base_dir) || !Common::FS::CreateDir(macro_dir)) {
|
if (!Common::FS::CreateDir(base_dir) || !Common::FS::CreateDir(macro_dir)) {
|
||||||
LOG_ERROR(Common_Filesystem, "Failed to create macro dump directories");
|
LOG_ERROR(Common_Filesystem, "Failed to create macro dump directories");
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -108,14 +108,14 @@ bool IsASTCSupported() {
|
||||||
|
|
||||||
static bool HasSlowSoftwareAstc(std::string_view vendor_name, std::string_view renderer) {
|
static bool HasSlowSoftwareAstc(std::string_view vendor_name, std::string_view renderer) {
|
||||||
// ifdef for Unix reduces string comparisons for non-Windows drivers, and Intel
|
// ifdef for Unix reduces string comparisons for non-Windows drivers, and Intel
|
||||||
#ifdef YUZU_UNIX
|
#ifdef SUYU_UNIX
|
||||||
// Sorted vaguely by how likely a vendor is to appear
|
// Sorted vaguely by how likely a vendor is to appear
|
||||||
if (vendor_name == "AMD") {
|
if (vendor_name == "AMD") {
|
||||||
// RadeonSI
|
// RadeonSI
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
if (vendor_name == "Intel") {
|
if (vendor_name == "Intel") {
|
||||||
// Must be inside YUZU_UNIX ifdef as the Windows driver uses the same vendor string
|
// Must be inside SUYU_UNIX ifdef as the Windows driver uses the same vendor string
|
||||||
// iris, crocus
|
// iris, crocus
|
||||||
const bool is_intel_dg = (renderer.find("DG") != std::string_view::npos);
|
const bool is_intel_dg = (renderer.find("DG") != std::string_view::npos);
|
||||||
return is_intel_dg;
|
return is_intel_dg;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <atomic>
|
#include <atomic>
|
||||||
|
@ -260,7 +260,7 @@ void ShaderCache::LoadDiskResources(u64 title_id, std::stop_token stop_loading,
|
||||||
if (title_id == 0) {
|
if (title_id == 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const auto shader_dir{Common::FS::GetYuzuPath(Common::FS::YuzuPath::ShaderDir)};
|
const auto shader_dir{Common::FS::GetSuyuPath(Common::FS::SuyuPath::ShaderDir)};
|
||||||
const auto base_dir{shader_dir / fmt::format("{:016x}", title_id)};
|
const auto base_dir{shader_dir / fmt::format("{:016x}", title_id)};
|
||||||
if (!Common::FS::CreateDir(shader_dir) || !Common::FS::CreateDir(base_dir)) {
|
if (!Common::FS::CreateDir(shader_dir) || !Common::FS::CreateDir(base_dir)) {
|
||||||
LOG_ERROR(Common_Filesystem, "Failed to create shader cache directories");
|
LOG_ERROR(Common_Filesystem, "Failed to create shader cache directories");
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -464,7 +464,7 @@ void PipelineCache::LoadDiskResources(u64 title_id, std::stop_token stop_loading
|
||||||
if (title_id == 0) {
|
if (title_id == 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const auto shader_dir{Common::FS::GetYuzuPath(Common::FS::YuzuPath::ShaderDir)};
|
const auto shader_dir{Common::FS::GetSuyuPath(Common::FS::SuyuPath::ShaderDir)};
|
||||||
const auto base_dir{shader_dir / fmt::format("{:016x}", title_id)};
|
const auto base_dir{shader_dir / fmt::format("{:016x}", title_id)};
|
||||||
if (!Common::FS::CreateDir(shader_dir) || !Common::FS::CreateDir(base_dir)) {
|
if (!Common::FS::CreateDir(shader_dir) || !Common::FS::CreateDir(base_dir)) {
|
||||||
LOG_ERROR(Common_Filesystem, "Failed to create pipeline cache directories");
|
LOG_ERROR(Common_Filesystem, "Failed to create pipeline cache directories");
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -91,7 +91,7 @@ static std::string_view StageToPrefix(Shader::Stage stage) {
|
||||||
static void DumpImpl(u64 pipeline_hash, u64 shader_hash, std::span<const u64> code,
|
static void DumpImpl(u64 pipeline_hash, u64 shader_hash, std::span<const u64> code,
|
||||||
[[maybe_unused]] u32 read_highest, [[maybe_unused]] u32 read_lowest,
|
[[maybe_unused]] u32 read_highest, [[maybe_unused]] u32 read_lowest,
|
||||||
u32 initial_offset, Shader::Stage stage) {
|
u32 initial_offset, Shader::Stage stage) {
|
||||||
const auto shader_dir{Common::FS::GetYuzuPath(Common::FS::YuzuPath::DumpDir)};
|
const auto shader_dir{Common::FS::GetSuyuPath(Common::FS::SuyuPath::DumpDir)};
|
||||||
const auto base_dir{shader_dir / "shaders"};
|
const auto base_dir{shader_dir / "shaders"};
|
||||||
if (!Common::FS::CreateDir(shader_dir) || !Common::FS::CreateDir(base_dir)) {
|
if (!Common::FS::CreateDir(shader_dir) || !Common::FS::CreateDir(base_dir)) {
|
||||||
LOG_ERROR(Common_Filesystem, "Failed to create shader dump directories");
|
LOG_ERROR(Common_Filesystem, "Failed to create shader dump directories");
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#ifdef HAS_NSIGHT_AFTERMATH
|
#ifdef HAS_NSIGHT_AFTERMATH
|
||||||
|
@ -47,7 +47,7 @@ NsightAftermathTracker::NsightAftermathTracker() {
|
||||||
LOG_ERROR(Render_Vulkan, "Failed to load Nsight Aftermath function pointers");
|
LOG_ERROR(Render_Vulkan, "Failed to load Nsight Aftermath function pointers");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
dump_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::LogDir) / "gpucrash";
|
dump_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::LogDir) / "gpucrash";
|
||||||
|
|
||||||
Common::FS::RemoveDirRecursively(dump_dir);
|
Common::FS::RemoveDirRecursively(dump_dir);
|
||||||
if (!Common::FS::CreateDir(dump_dir)) {
|
if (!Common::FS::CreateDir(dump_dir)) {
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
# SPDX-FileCopyrightText: 2018 yuzu Emulator Project & 2024 Suyu Emulator Project
|
# SPDX-FileCopyrightText: 2018 yuzu Emulator Project & 2024 Suyu Emulator Project
|
||||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
# Modified by JuanCStar on 2024/03/06
|
|
||||||
|
|
||||||
set(CMAKE_AUTOMOC ON)
|
set(CMAKE_AUTOMOC ON)
|
||||||
set(CMAKE_AUTORCC ON)
|
set(CMAKE_AUTORCC ON)
|
||||||
set(CMAKE_AUTOUIC ON)
|
set(CMAKE_AUTOUIC ON)
|
||||||
|
@ -431,9 +429,9 @@ if (ENABLE_WEB_SERVICE)
|
||||||
target_compile_definitions(yuzu PRIVATE -DENABLE_WEB_SERVICE)
|
target_compile_definitions(yuzu PRIVATE -DENABLE_WEB_SERVICE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (YUZU_USE_QT_MULTIMEDIA)
|
if (SUYU_USE_QT_MULTIMEDIA)
|
||||||
target_link_libraries(yuzu PRIVATE Qt${QT_MAJOR_VERSION}::Multimedia)
|
target_link_libraries(yuzu PRIVATE Qt${QT_MAJOR_VERSION}::Multimedia)
|
||||||
target_compile_definitions(yuzu PRIVATE -DYUZU_USE_QT_MULTIMEDIA)
|
target_compile_definitions(yuzu PRIVATE -DSUYU_USE_QT_MULTIMEDIA)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
if (YUZU_USE_QT_WEB_ENGINE)
|
if (YUZU_USE_QT_WEB_ENGINE)
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
// Modified by JuanCStar on 2024/03/06
|
|
||||||
|
|
||||||
#include <QIcon>
|
#include <QIcon>
|
||||||
#include <fmt/format.h>
|
#include <fmt/format.h>
|
||||||
#include "common/scm_rev.h"
|
#include "common/scm_rev.h"
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
// Modified by JuanCStar on 2024/03/06
|
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <mutex>
|
#include <mutex>
|
||||||
|
@ -30,7 +30,7 @@ QString FormatUserEntryText(const QString& username, Common::UUID uuid) {
|
||||||
|
|
||||||
QString GetImagePath(Common::UUID uuid) {
|
QString GetImagePath(Common::UUID uuid) {
|
||||||
const auto path =
|
const auto path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) /
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) /
|
||||||
fmt::format("system/save/8000000000000010/su/avators/{}.jpg", uuid.FormattedString());
|
fmt::format("system/save/8000000000000010/su/avators/{}.jpg", uuid.FormattedString());
|
||||||
return QString::fromStdString(Common::FS::PathToUTF8String(path));
|
return QString::fromStdString(Common::FS::PathToUTF8String(path));
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#ifdef YUZU_USE_QT_WEB_ENGINE
|
#ifdef YUZU_USE_QT_WEB_ENGINE
|
||||||
|
@ -57,7 +57,7 @@ QtNXWebEngineView::QtNXWebEngineView(QWidget* parent, Core::System& system,
|
||||||
default_profile{QWebEngineProfile::defaultProfile()}, global_settings{
|
default_profile{QWebEngineProfile::defaultProfile()}, global_settings{
|
||||||
default_profile->settings()} {
|
default_profile->settings()} {
|
||||||
default_profile->setPersistentStoragePath(QString::fromStdString(Common::FS::PathToUTF8String(
|
default_profile->setPersistentStoragePath(QString::fromStdString(Common::FS::PathToUTF8String(
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::YuzuDir) / "qtwebengine")));
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::SuyuDir) / "qtwebengine")));
|
||||||
|
|
||||||
QWebEngineScript gamepad;
|
QWebEngineScript gamepad;
|
||||||
QWebEngineScript window_nx;
|
QWebEngineScript window_nx;
|
||||||
|
@ -336,7 +336,7 @@ void QtNXWebEngineView::LoadExtractedFonts() {
|
||||||
QWebEngineScript load_nx_font;
|
QWebEngineScript load_nx_font;
|
||||||
|
|
||||||
auto fonts_dir_str = Common::FS::PathToUTF8String(
|
auto fonts_dir_str = Common::FS::PathToUTF8String(
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) / "fonts/");
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) / "fonts/");
|
||||||
|
|
||||||
std::replace(fonts_dir_str.begin(), fonts_dir_str.end(), '\\', '/');
|
std::replace(fonts_dir_str.begin(), fonts_dir_str.end(), '\\', '/');
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2014 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2014 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -13,7 +13,7 @@
|
||||||
#include <QtCore/qglobal.h>
|
#include <QtCore/qglobal.h>
|
||||||
#include "common/settings_enums.h"
|
#include "common/settings_enums.h"
|
||||||
#include "uisettings.h"
|
#include "uisettings.h"
|
||||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && YUZU_USE_QT_MULTIMEDIA
|
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && SUYU_USE_QT_MULTIMEDIA
|
||||||
#include <QCamera>
|
#include <QCamera>
|
||||||
#include <QCameraImageCapture>
|
#include <QCameraImageCapture>
|
||||||
#include <QCameraInfo>
|
#include <QCameraInfo>
|
||||||
|
@ -286,7 +286,7 @@ GRenderWindow::GRenderWindow(GMainWindow* parent, EmuThread* emu_thread_,
|
||||||
Core::System& system_)
|
Core::System& system_)
|
||||||
: QWidget(parent),
|
: QWidget(parent),
|
||||||
emu_thread(emu_thread_), input_subsystem{std::move(input_subsystem_)}, system{system_} {
|
emu_thread(emu_thread_), input_subsystem{std::move(input_subsystem_)}, system{system_} {
|
||||||
setWindowTitle(QStringLiteral("yuzu %1 | %2-%3")
|
setWindowTitle(QStringLiteral("suyu %1 | %2-%3")
|
||||||
.arg(QString::fromUtf8(Common::g_build_name),
|
.arg(QString::fromUtf8(Common::g_build_name),
|
||||||
QString::fromUtf8(Common::g_scm_branch),
|
QString::fromUtf8(Common::g_scm_branch),
|
||||||
QString::fromUtf8(Common::g_scm_desc)));
|
QString::fromUtf8(Common::g_scm_desc)));
|
||||||
|
@ -760,7 +760,7 @@ void GRenderWindow::TouchEndEvent() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void GRenderWindow::InitializeCamera() {
|
void GRenderWindow::InitializeCamera() {
|
||||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && YUZU_USE_QT_MULTIMEDIA
|
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && SUYU_USE_QT_MULTIMEDIA
|
||||||
constexpr auto camera_update_ms = std::chrono::milliseconds{50}; // (50ms, 20Hz)
|
constexpr auto camera_update_ms = std::chrono::milliseconds{50}; // (50ms, 20Hz)
|
||||||
if (!Settings::values.enable_ir_sensor) {
|
if (!Settings::values.enable_ir_sensor) {
|
||||||
return;
|
return;
|
||||||
|
@ -821,7 +821,7 @@ void GRenderWindow::InitializeCamera() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void GRenderWindow::FinalizeCamera() {
|
void GRenderWindow::FinalizeCamera() {
|
||||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && YUZU_USE_QT_MULTIMEDIA
|
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && SUYU_USE_QT_MULTIMEDIA
|
||||||
if (camera_timer) {
|
if (camera_timer) {
|
||||||
camera_timer->stop();
|
camera_timer->stop();
|
||||||
}
|
}
|
||||||
|
@ -832,7 +832,7 @@ void GRenderWindow::FinalizeCamera() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void GRenderWindow::RequestCameraCapture() {
|
void GRenderWindow::RequestCameraCapture() {
|
||||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && YUZU_USE_QT_MULTIMEDIA
|
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && SUYU_USE_QT_MULTIMEDIA
|
||||||
if (!Settings::values.enable_ir_sensor) {
|
if (!Settings::values.enable_ir_sensor) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -853,7 +853,7 @@ void GRenderWindow::RequestCameraCapture() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void GRenderWindow::OnCameraCapture(int requestId, const QImage& img) {
|
void GRenderWindow::OnCameraCapture(int requestId, const QImage& img) {
|
||||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && YUZU_USE_QT_MULTIMEDIA
|
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && SUYU_USE_QT_MULTIMEDIA
|
||||||
// TODO: Capture directly in the format and resolution needed
|
// TODO: Capture directly in the format and resolution needed
|
||||||
const auto camera_width = input_subsystem->GetCamera()->getImageWidth();
|
const auto camera_width = input_subsystem->GetCamera()->getImageWidth();
|
||||||
const auto camera_height = input_subsystem->GetCamera()->getImageHeight();
|
const auto camera_height = input_subsystem->GetCamera()->getImageHeight();
|
||||||
|
@ -1034,7 +1034,7 @@ bool GRenderWindow::InitializeOpenGL() {
|
||||||
return true;
|
return true;
|
||||||
#else
|
#else
|
||||||
QMessageBox::warning(this, tr("OpenGL not available!"),
|
QMessageBox::warning(this, tr("OpenGL not available!"),
|
||||||
tr("yuzu has not been compiled with OpenGL support."));
|
tr("yusu has not been compiled with OpenGL support."));
|
||||||
return false;
|
return false;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2014 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2014 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
@ -261,7 +261,7 @@ private:
|
||||||
bool first_frame = false;
|
bool first_frame = false;
|
||||||
InputCommon::TasInput::TasState last_tas_state;
|
InputCommon::TasInput::TasState last_tas_state;
|
||||||
|
|
||||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && YUZU_USE_QT_MULTIMEDIA
|
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && SUYU_USE_QT_MULTIMEDIA
|
||||||
bool is_virtual_camera;
|
bool is_virtual_camera;
|
||||||
int pending_camera_snapshots;
|
int pending_camera_snapshots;
|
||||||
std::vector<u32> camera_data;
|
std::vector<u32> camera_data;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project
|
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -60,7 +60,7 @@ static void PruneDumpDirectory(const std::filesystem::path& dump_path) {
|
||||||
|
|
||||||
void InstallCrashHandler() {
|
void InstallCrashHandler() {
|
||||||
// Write crash dumps to profile directory.
|
// Write crash dumps to profile directory.
|
||||||
const auto dump_path = GetYuzuPath(Common::FS::YuzuPath::CrashDumpsDir);
|
const auto dump_path = GetSuyuPath(Common::FS::SuyuPath::CrashDumpsDir);
|
||||||
PruneDumpDirectory(dump_path);
|
PruneDumpDirectory(dump_path);
|
||||||
|
|
||||||
#if defined(_WIN32)
|
#if defined(_WIN32)
|
||||||
|
|
|
@ -33,7 +33,7 @@
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="lbl_Spiel">
|
<widget class="QLabel" name="lbl_Spiel">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string><html><head/><body><p><span style=" font-size:10pt;">Should you choose to submit a test case to the </span><a href="https://yuzu-emu.org/game/"><span style=" font-size:10pt; text-decoration: underline; color:#0000ff;">yuzu Compatibility List</span></a><span style=" font-size:10pt;">, The following information will be collected and displayed on the site:</span></p><ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Hardware Information (CPU / GPU / Operating System)</li><li style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Which version of yuzu you are running</li><li style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">The connected yuzu account</li></ul></body></html></string>
|
<string><html><head/><body><p><span style=" font-size:10pt;">Should you choose to submit a test case to the </span><a href="https://suyu-emu.org/game/"><span style=" font-size:10pt; text-decoration: underline; color:#0000ff;">suyu Compatibility List</span></a><span style=" font-size:10pt;">, The following information will be collected and displayed on the site:</span></p><ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Hardware Information (CPU / GPU / Operating System)</li><li style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Which version of suyu you are running</li><li style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">The connected suyu account</li></ul></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
<property name="wordWrap">
|
<property name="wordWrap">
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
// Text : Copyright 2022 yuzu Emulator Project
|
// Text : Copyright 2022 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-3.0-or-later
|
// SPDX-License-Identifier: GPL-3.0-or-later
|
||||||
|
|
||||||
#include <memory>
|
#include <memory>
|
||||||
#include <QtCore>
|
#include <QtCore>
|
||||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && YUZU_USE_QT_MULTIMEDIA
|
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && SUYU_USE_QT_MULTIMEDIA
|
||||||
#include <QCameraImageCapture>
|
#include <QCameraImageCapture>
|
||||||
#include <QCameraInfo>
|
#include <QCameraInfo>
|
||||||
#endif
|
#endif
|
||||||
|
@ -36,7 +36,7 @@ ConfigureCamera::ConfigureCamera(QWidget* parent, InputCommon::InputSubsystem* i
|
||||||
ConfigureCamera::~ConfigureCamera() = default;
|
ConfigureCamera::~ConfigureCamera() = default;
|
||||||
|
|
||||||
void ConfigureCamera::PreviewCamera() {
|
void ConfigureCamera::PreviewCamera() {
|
||||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && YUZU_USE_QT_MULTIMEDIA
|
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && SUYU_USE_QT_MULTIMEDIA
|
||||||
const auto index = ui->ir_sensor_combo_box->currentIndex();
|
const auto index = ui->ir_sensor_combo_box->currentIndex();
|
||||||
bool camera_found = false;
|
bool camera_found = false;
|
||||||
const QList<QCameraInfo> cameras = QCameraInfo::availableCameras();
|
const QList<QCameraInfo> cameras = QCameraInfo::availableCameras();
|
||||||
|
@ -138,7 +138,7 @@ void ConfigureCamera::LoadConfiguration() {
|
||||||
ui->ir_sensor_combo_box->clear();
|
ui->ir_sensor_combo_box->clear();
|
||||||
input_devices.push_back("Auto");
|
input_devices.push_back("Auto");
|
||||||
ui->ir_sensor_combo_box->addItem(tr("Auto"));
|
ui->ir_sensor_combo_box->addItem(tr("Auto"));
|
||||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && YUZU_USE_QT_MULTIMEDIA
|
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && SUYU_USE_QT_MULTIMEDIA
|
||||||
const auto cameras = QCameraInfo::availableCameras();
|
const auto cameras = QCameraInfo::availableCameras();
|
||||||
for (const QCameraInfo& cameraInfo : cameras) {
|
for (const QCameraInfo& cameraInfo : cameras) {
|
||||||
input_devices.push_back(cameraInfo.deviceName().toStdString());
|
input_devices.push_back(cameraInfo.deviceName().toStdString());
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// Text : Copyright 2022 yuzu Emulator Project
|
// Text : Copyright 2022 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-3.0-or-later
|
// SPDX-License-Identifier: GPL-3.0-or-later
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
@ -46,7 +46,7 @@ private:
|
||||||
|
|
||||||
bool is_virtual_camera;
|
bool is_virtual_camera;
|
||||||
int pending_snapshots;
|
int pending_snapshots;
|
||||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && YUZU_USE_QT_MULTIMEDIA
|
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0)) && SUYU_USE_QT_MULTIMEDIA
|
||||||
std::unique_ptr<QCamera> camera;
|
std::unique_ptr<QCamera> camera;
|
||||||
std::unique_ptr<QCameraImageCapture> camera_capture;
|
std::unique_ptr<QCameraImageCapture> camera_capture;
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2016 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2016 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <QDesktopServices>
|
#include <QDesktopServices>
|
||||||
|
@ -21,7 +21,7 @@ ConfigureDebug::ConfigureDebug(const Core::System& system_, QWidget* parent)
|
||||||
|
|
||||||
connect(ui->open_log_button, &QPushButton::clicked, []() {
|
connect(ui->open_log_button, &QPushButton::clicked, []() {
|
||||||
const auto path =
|
const auto path =
|
||||||
QString::fromStdString(Common::FS::GetYuzuPathString(Common::FS::YuzuPath::LogDir));
|
QString::fromStdString(Common::FS::GetSuyuPathString(Common::FS::SuyuPath::LogDir));
|
||||||
QDesktopServices::openUrl(QUrl::fromLocalFile(path));
|
QDesktopServices::openUrl(QUrl::fromLocalFile(path));
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2019 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <QFileDialog>
|
#include <QFileDialog>
|
||||||
|
@ -47,15 +47,15 @@ void ConfigureFilesystem::changeEvent(QEvent* event) {
|
||||||
|
|
||||||
void ConfigureFilesystem::SetConfiguration() {
|
void ConfigureFilesystem::SetConfiguration() {
|
||||||
ui->nand_directory_edit->setText(
|
ui->nand_directory_edit->setText(
|
||||||
QString::fromStdString(Common::FS::GetYuzuPathString(Common::FS::YuzuPath::NANDDir)));
|
QString::fromStdString(Common::FS::GetSuyuPathString(Common::FS::SuyuPath::NANDDir)));
|
||||||
ui->sdmc_directory_edit->setText(
|
ui->sdmc_directory_edit->setText(
|
||||||
QString::fromStdString(Common::FS::GetYuzuPathString(Common::FS::YuzuPath::SDMCDir)));
|
QString::fromStdString(Common::FS::GetSuyuPathString(Common::FS::SuyuPath::SDMCDir)));
|
||||||
ui->gamecard_path_edit->setText(
|
ui->gamecard_path_edit->setText(
|
||||||
QString::fromStdString(Settings::values.gamecard_path.GetValue()));
|
QString::fromStdString(Settings::values.gamecard_path.GetValue()));
|
||||||
ui->dump_path_edit->setText(
|
ui->dump_path_edit->setText(
|
||||||
QString::fromStdString(Common::FS::GetYuzuPathString(Common::FS::YuzuPath::DumpDir)));
|
QString::fromStdString(Common::FS::GetSuyuPathString(Common::FS::SuyuPath::DumpDir)));
|
||||||
ui->load_path_edit->setText(
|
ui->load_path_edit->setText(
|
||||||
QString::fromStdString(Common::FS::GetYuzuPathString(Common::FS::YuzuPath::LoadDir)));
|
QString::fromStdString(Common::FS::GetSuyuPathString(Common::FS::SuyuPath::LoadDir)));
|
||||||
|
|
||||||
ui->gamecard_inserted->setChecked(Settings::values.gamecard_inserted.GetValue());
|
ui->gamecard_inserted->setChecked(Settings::values.gamecard_inserted.GetValue());
|
||||||
ui->gamecard_current_game->setChecked(Settings::values.gamecard_current_game.GetValue());
|
ui->gamecard_current_game->setChecked(Settings::values.gamecard_current_game.GetValue());
|
||||||
|
@ -68,13 +68,13 @@ void ConfigureFilesystem::SetConfiguration() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void ConfigureFilesystem::ApplyConfiguration() {
|
void ConfigureFilesystem::ApplyConfiguration() {
|
||||||
Common::FS::SetYuzuPath(Common::FS::YuzuPath::NANDDir,
|
Common::FS::SetSuyuPath(Common::FS::SuyuPath::NANDDir,
|
||||||
ui->nand_directory_edit->text().toStdString());
|
ui->nand_directory_edit->text().toStdString());
|
||||||
Common::FS::SetYuzuPath(Common::FS::YuzuPath::SDMCDir,
|
Common::FS::SetSuyuPath(Common::FS::SuyuPath::SDMCDir,
|
||||||
ui->sdmc_directory_edit->text().toStdString());
|
ui->sdmc_directory_edit->text().toStdString());
|
||||||
Common::FS::SetYuzuPath(Common::FS::YuzuPath::DumpDir,
|
Common::FS::SetSuyuPath(Common::FS::SuyuPath::DumpDir,
|
||||||
ui->dump_path_edit->text().toStdString());
|
ui->dump_path_edit->text().toStdString());
|
||||||
Common::FS::SetYuzuPath(Common::FS::YuzuPath::LoadDir,
|
Common::FS::SetSuyuPath(Common::FS::SuyuPath::LoadDir,
|
||||||
ui->load_path_edit->text().toStdString());
|
ui->load_path_edit->text().toStdString());
|
||||||
|
|
||||||
Settings::values.gamecard_inserted = ui->gamecard_inserted->isChecked();
|
Settings::values.gamecard_inserted = ui->gamecard_inserted->isChecked();
|
||||||
|
@ -126,12 +126,12 @@ void ConfigureFilesystem::SetDirectory(DirectoryTarget target, QLineEdit* edit)
|
||||||
}
|
}
|
||||||
|
|
||||||
void ConfigureFilesystem::ResetMetadata() {
|
void ConfigureFilesystem::ResetMetadata() {
|
||||||
if (!Common::FS::Exists(Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) /
|
if (!Common::FS::Exists(Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) /
|
||||||
"game_list/")) {
|
"game_list/")) {
|
||||||
QMessageBox::information(this, tr("Reset Metadata Cache"),
|
QMessageBox::information(this, tr("Reset Metadata Cache"),
|
||||||
tr("The metadata cache is already empty."));
|
tr("The metadata cache is already empty."));
|
||||||
} else if (Common::FS::RemoveDirRecursively(
|
} else if (Common::FS::RemoveDirRecursively(
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) / "game_list")) {
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) / "game_list")) {
|
||||||
QMessageBox::information(this, tr("Reset Metadata Cache"),
|
QMessageBox::information(this, tr("Reset Metadata Cache"),
|
||||||
tr("The operation completed successfully."));
|
tr("The operation completed successfully."));
|
||||||
UISettings::values.is_game_list_reload_pending.exchange(true);
|
UISettings::values.is_game_list_reload_pending.exchange(true);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <QColorDialog>
|
#include <QColorDialog>
|
||||||
|
@ -197,7 +197,7 @@ void ConfigureInputAdvanced::UpdateUIEnabled() {
|
||||||
ui->debug_configure->setEnabled(ui->debug_enabled->isChecked());
|
ui->debug_configure->setEnabled(ui->debug_enabled->isChecked());
|
||||||
ui->touchscreen_advanced->setEnabled(ui->touchscreen_enabled->isChecked());
|
ui->touchscreen_advanced->setEnabled(ui->touchscreen_enabled->isChecked());
|
||||||
ui->ring_controller_configure->setEnabled(ui->enable_ring_controller->isChecked());
|
ui->ring_controller_configure->setEnabled(ui->enable_ring_controller->isChecked());
|
||||||
#if QT_VERSION > QT_VERSION_CHECK(6, 0, 0) || !defined(YUZU_USE_QT_MULTIMEDIA)
|
#if QT_VERSION > QT_VERSION_CHECK(6, 0, 0) || !defined(SUYU_USE_QT_MULTIMEDIA)
|
||||||
ui->enable_ir_sensor->setEnabled(false);
|
ui->enable_ir_sensor->setEnabled(false);
|
||||||
ui->camera_configure->setEnabled(false);
|
ui->camera_configure->setEnabled(false);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2016 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2016 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -80,7 +80,7 @@ void ConfigurePerGameAddons::ApplyConfiguration() {
|
||||||
std::sort(disabled_addons.begin(), disabled_addons.end());
|
std::sort(disabled_addons.begin(), disabled_addons.end());
|
||||||
std::sort(current.begin(), current.end());
|
std::sort(current.begin(), current.end());
|
||||||
if (disabled_addons != current) {
|
if (disabled_addons != current) {
|
||||||
Common::FS::RemoveFile(Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) /
|
Common::FS::RemoveFile(Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) /
|
||||||
"game_list" / fmt::format("{:016X}.pv.txt", title_id));
|
"game_list" / fmt::format("{:016X}.pv.txt", title_id));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2016 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2016 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
@ -35,7 +35,7 @@ constexpr std::array<u8, 107> backup_jpeg{
|
||||||
|
|
||||||
QString GetImagePath(const Common::UUID& uuid) {
|
QString GetImagePath(const Common::UUID& uuid) {
|
||||||
const auto path =
|
const auto path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) /
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) /
|
||||||
fmt::format("system/save/8000000000000010/su/avators/{}.jpg", uuid.FormattedString());
|
fmt::format("system/save/8000000000000010/su/avators/{}.jpg", uuid.FormattedString());
|
||||||
return QString::fromStdString(Common::FS::PathToUTF8String(path));
|
return QString::fromStdString(Common::FS::PathToUTF8String(path));
|
||||||
}
|
}
|
||||||
|
@ -288,7 +288,7 @@ void ConfigureProfileManager::SetUserImage() {
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto raw_path = QString::fromStdString(Common::FS::PathToUTF8String(
|
const auto raw_path = QString::fromStdString(Common::FS::PathToUTF8String(
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/save/8000000000000010"));
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/save/8000000000000010"));
|
||||||
const QFileInfo raw_info{raw_path};
|
const QFileInfo raw_info{raw_path};
|
||||||
if (raw_info.exists() && !raw_info.isDir() && !QFile::remove(raw_path)) {
|
if (raw_info.exists() && !raw_info.isDir() && !QFile::remove(raw_path)) {
|
||||||
QMessageBox::warning(this, tr("Error deleting file"),
|
QMessageBox::warning(this, tr("Error deleting file"),
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <QFileDialog>
|
#include <QFileDialog>
|
||||||
|
@ -28,14 +28,14 @@ ConfigureTasDialog::~ConfigureTasDialog() = default;
|
||||||
|
|
||||||
void ConfigureTasDialog::LoadConfiguration() {
|
void ConfigureTasDialog::LoadConfiguration() {
|
||||||
ui->tas_path_edit->setText(
|
ui->tas_path_edit->setText(
|
||||||
QString::fromStdString(Common::FS::GetYuzuPathString(Common::FS::YuzuPath::TASDir)));
|
QString::fromStdString(Common::FS::GetSuyuPathString(Common::FS::SuyuPath::TASDir)));
|
||||||
ui->tas_enable->setChecked(Settings::values.tas_enable.GetValue());
|
ui->tas_enable->setChecked(Settings::values.tas_enable.GetValue());
|
||||||
ui->tas_loop_script->setChecked(Settings::values.tas_loop.GetValue());
|
ui->tas_loop_script->setChecked(Settings::values.tas_loop.GetValue());
|
||||||
ui->tas_pause_on_load->setChecked(Settings::values.pause_tas_on_load.GetValue());
|
ui->tas_pause_on_load->setChecked(Settings::values.pause_tas_on_load.GetValue());
|
||||||
}
|
}
|
||||||
|
|
||||||
void ConfigureTasDialog::ApplyConfiguration() {
|
void ConfigureTasDialog::ApplyConfiguration() {
|
||||||
Common::FS::SetYuzuPath(Common::FS::YuzuPath::TASDir, ui->tas_path_edit->text().toStdString());
|
Common::FS::SetSuyuPath(Common::FS::SuyuPath::TASDir, ui->tas_path_edit->text().toStdString());
|
||||||
Settings::values.tas_enable.SetValue(ui->tas_enable->isChecked());
|
Settings::values.tas_enable.SetValue(ui->tas_enable->isChecked());
|
||||||
Settings::values.tas_loop.SetValue(ui->tas_loop_script->isChecked());
|
Settings::values.tas_loop.SetValue(ui->tas_loop_script->isChecked());
|
||||||
Settings::values.pause_tas_on_load.SetValue(ui->tas_pause_on_load->isChecked());
|
Settings::values.pause_tas_on_load.SetValue(ui->tas_pause_on_load->isChecked());
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2016 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2016 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include "yuzu/configuration/configure_ui.h"
|
#include "yuzu/configuration/configure_ui.h"
|
||||||
|
@ -144,8 +144,8 @@ ConfigureUi::ConfigureUi(Core::System& system_, QWidget* parent)
|
||||||
connect(ui->screenshot_path_button, &QToolButton::pressed, this, [this] {
|
connect(ui->screenshot_path_button, &QToolButton::pressed, this, [this] {
|
||||||
auto dir =
|
auto dir =
|
||||||
QFileDialog::getExistingDirectory(this, tr("Select Screenshots Path..."),
|
QFileDialog::getExistingDirectory(this, tr("Select Screenshots Path..."),
|
||||||
QString::fromStdString(Common::FS::GetYuzuPathString(
|
QString::fromStdString(Common::FS::GetSuyuPathString(
|
||||||
Common::FS::YuzuPath::ScreenshotsDir)));
|
Common::FS::SuyuPath::ScreenshotsDir)));
|
||||||
if (!dir.isEmpty()) {
|
if (!dir.isEmpty()) {
|
||||||
if (dir.back() != QChar::fromLatin1('/')) {
|
if (dir.back() != QChar::fromLatin1('/')) {
|
||||||
dir.append(QChar::fromLatin1('/'));
|
dir.append(QChar::fromLatin1('/'));
|
||||||
|
@ -176,7 +176,7 @@ void ConfigureUi::ApplyConfiguration() {
|
||||||
UISettings::values.row_2_text_id = ui->row_2_text_combobox->currentData().toUInt();
|
UISettings::values.row_2_text_id = ui->row_2_text_combobox->currentData().toUInt();
|
||||||
|
|
||||||
UISettings::values.enable_screenshot_save_as = ui->enable_screenshot_save_as->isChecked();
|
UISettings::values.enable_screenshot_save_as = ui->enable_screenshot_save_as->isChecked();
|
||||||
Common::FS::SetYuzuPath(Common::FS::YuzuPath::ScreenshotsDir,
|
Common::FS::SetSuyuPath(Common::FS::SuyuPath::ScreenshotsDir,
|
||||||
ui->screenshot_path_edit->text().toStdString());
|
ui->screenshot_path_edit->text().toStdString());
|
||||||
|
|
||||||
const u32 height = ScreenshotDimensionToInt(ui->screenshot_height->currentText());
|
const u32 height = ScreenshotDimensionToInt(ui->screenshot_height->currentText());
|
||||||
|
@ -208,7 +208,7 @@ void ConfigureUi::SetConfiguration() {
|
||||||
ui->enable_screenshot_save_as->setChecked(
|
ui->enable_screenshot_save_as->setChecked(
|
||||||
UISettings::values.enable_screenshot_save_as.GetValue());
|
UISettings::values.enable_screenshot_save_as.GetValue());
|
||||||
ui->screenshot_path_edit->setText(QString::fromStdString(
|
ui->screenshot_path_edit->setText(QString::fromStdString(
|
||||||
Common::FS::GetYuzuPathString(Common::FS::YuzuPath::ScreenshotsDir)));
|
Common::FS::GetSuyuPathString(Common::FS::SuyuPath::ScreenshotsDir)));
|
||||||
|
|
||||||
const auto height = UISettings::values.screenshot_height.GetValue();
|
const auto height = UISettings::values.screenshot_height.GetValue();
|
||||||
if (height == 0) {
|
if (height == 0) {
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <fmt/format.h>
|
#include <fmt/format.h>
|
||||||
|
@ -14,7 +14,7 @@ namespace FS = Common::FS;
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
bool ProfileExistsInFilesystem(std::string_view profile_name) {
|
bool ProfileExistsInFilesystem(std::string_view profile_name) {
|
||||||
return FS::Exists(FS::GetYuzuPath(FS::YuzuPath::ConfigDir) / "input" /
|
return FS::Exists(FS::GetSuyuPath(FS::SuyuPath::ConfigDir) / "input" /
|
||||||
fmt::format("{}.ini", profile_name));
|
fmt::format("{}.ini", profile_name));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -29,7 +29,7 @@ std::filesystem::path GetNameWithoutExtension(std::filesystem::path filename) {
|
||||||
} // namespace
|
} // namespace
|
||||||
|
|
||||||
InputProfiles::InputProfiles() {
|
InputProfiles::InputProfiles() {
|
||||||
const auto input_profile_loc = FS::GetYuzuPath(FS::YuzuPath::ConfigDir) / "input";
|
const auto input_profile_loc = FS::GetSuyuPath(FS::SuyuPath::ConfigDir) / "input";
|
||||||
|
|
||||||
if (!FS::IsDir(input_profile_loc)) {
|
if (!FS::IsDir(input_profile_loc)) {
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
@ -38,7 +38,7 @@ QString GetGameListCachedObject(const std::string& filename, const std::string&
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto path =
|
const auto path =
|
||||||
Common::FS::PathToUTF8String(Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) /
|
Common::FS::PathToUTF8String(Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) /
|
||||||
"game_list" / fmt::format("{}.{}", filename, ext));
|
"game_list" / fmt::format("{}.{}", filename, ext));
|
||||||
|
|
||||||
void(Common::FS::CreateParentDirs(path));
|
void(Common::FS::CreateParentDirs(path));
|
||||||
|
@ -70,7 +70,7 @@ std::pair<std::vector<u8>, std::string> GetGameListCachedObject(
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto game_list_dir =
|
const auto game_list_dir =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) / "game_list";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) / "game_list";
|
||||||
const auto jpeg_name = fmt::format("{}.jpeg", filename);
|
const auto jpeg_name = fmt::format("{}.jpeg", filename);
|
||||||
const auto app_name = fmt::format("{}.appname.txt", filename);
|
const auto app_name = fmt::format("{}.appname.txt", filename);
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
// SPDX-FileCopyrightText: 2014 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2014 Citra Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
// Modified by JuanCStar on 2024/03/06
|
|
||||||
|
|
||||||
#include <cinttypes>
|
#include <cinttypes>
|
||||||
#include <clocale>
|
#include <clocale>
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
|
@ -225,7 +223,7 @@ void GMainWindow::ShowTelemetryCallout() {
|
||||||
const int GMainWindow::max_recent_files_item;
|
const int GMainWindow::max_recent_files_item;
|
||||||
|
|
||||||
static void RemoveCachedContents() {
|
static void RemoveCachedContents() {
|
||||||
const auto cache_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir);
|
const auto cache_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir);
|
||||||
const auto offline_fonts = cache_dir / "fonts";
|
const auto offline_fonts = cache_dir / "fonts";
|
||||||
const auto offline_manual = cache_dir / "offline_web_applet_manual";
|
const auto offline_manual = cache_dir / "offline_web_applet_manual";
|
||||||
const auto offline_legal_information = cache_dir / "offline_web_applet_legal_information";
|
const auto offline_legal_information = cache_dir / "offline_web_applet_legal_information";
|
||||||
|
@ -372,13 +370,13 @@ GMainWindow::GMainWindow(std::unique_ptr<QtConfig> config_, bool has_broken_vulk
|
||||||
const auto description = std::string(Common::g_scm_desc);
|
const auto description = std::string(Common::g_scm_desc);
|
||||||
const auto build_id = std::string(Common::g_build_id);
|
const auto build_id = std::string(Common::g_build_id);
|
||||||
|
|
||||||
const auto yuzu_build = fmt::format("Suyu Development Build | {}-{}", branch_name, description);
|
const auto suyu_build = fmt::format("suyu Development Build | {}-{}", branch_name, description);
|
||||||
const auto override_build =
|
const auto override_build =
|
||||||
fmt::format(fmt::runtime(std::string(Common::g_title_bar_format_idle)), build_id);
|
fmt::format(fmt::runtime(std::string(Common::g_title_bar_format_idle)), build_id);
|
||||||
const auto yuzu_build_version = override_build.empty() ? yuzu_build : override_build;
|
const auto suyu_build_version = override_build.empty() ? suyu_build : override_build;
|
||||||
const auto processor_count = std::thread::hardware_concurrency();
|
const auto processor_count = std::thread::hardware_concurrency();
|
||||||
|
|
||||||
LOG_INFO(Frontend, "Suyu Version: {}", yuzu_build_version);
|
LOG_INFO(Frontend, "suyu Version: {}", suyu_build_version);
|
||||||
LogRuntimes();
|
LogRuntimes();
|
||||||
#ifdef ARCHITECTURE_x86_64
|
#ifdef ARCHITECTURE_x86_64
|
||||||
const auto& caps = Common::GetCPUCaps();
|
const auto& caps = Common::GetCPUCaps();
|
||||||
|
@ -1338,7 +1336,7 @@ void GMainWindow::InitializeHotkeys() {
|
||||||
|
|
||||||
LinkActionShortcut(ui->action_Load_File, QStringLiteral("Load File"));
|
LinkActionShortcut(ui->action_Load_File, QStringLiteral("Load File"));
|
||||||
LinkActionShortcut(ui->action_Load_Amiibo, QStringLiteral("Load/Remove Amiibo"));
|
LinkActionShortcut(ui->action_Load_Amiibo, QStringLiteral("Load/Remove Amiibo"));
|
||||||
LinkActionShortcut(ui->action_Exit, QStringLiteral("Exit yuzu"));
|
LinkActionShortcut(ui->action_Exit, QStringLiteral("Exit suyu"));
|
||||||
LinkActionShortcut(ui->action_Restart, QStringLiteral("Restart Emulation"));
|
LinkActionShortcut(ui->action_Restart, QStringLiteral("Restart Emulation"));
|
||||||
LinkActionShortcut(ui->action_Pause, QStringLiteral("Continue/Pause Emulation"));
|
LinkActionShortcut(ui->action_Pause, QStringLiteral("Continue/Pause Emulation"));
|
||||||
LinkActionShortcut(ui->action_Stop, QStringLiteral("Stop Emulation"));
|
LinkActionShortcut(ui->action_Stop, QStringLiteral("Stop Emulation"));
|
||||||
|
@ -2289,7 +2287,7 @@ void GMainWindow::OnGameListOpenFolder(u64 program_id, GameListOpenTarget target
|
||||||
switch (target) {
|
switch (target) {
|
||||||
case GameListOpenTarget::SaveData: {
|
case GameListOpenTarget::SaveData: {
|
||||||
open_target = tr("Save Data");
|
open_target = tr("Save Data");
|
||||||
const auto nand_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir);
|
const auto nand_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir);
|
||||||
auto vfs_nand_dir =
|
auto vfs_nand_dir =
|
||||||
vfs->OpenDirectory(Common::FS::PathToUTF8String(nand_dir), FileSys::OpenMode::Read);
|
vfs->OpenDirectory(Common::FS::PathToUTF8String(nand_dir), FileSys::OpenMode::Read);
|
||||||
|
|
||||||
|
@ -2345,7 +2343,7 @@ void GMainWindow::OnGameListOpenFolder(u64 program_id, GameListOpenTarget target
|
||||||
}
|
}
|
||||||
case GameListOpenTarget::ModData: {
|
case GameListOpenTarget::ModData: {
|
||||||
open_target = tr("Mod Data");
|
open_target = tr("Mod Data");
|
||||||
path = Common::FS::GetYuzuPath(Common::FS::YuzuPath::LoadDir) /
|
path = Common::FS::GetSuyuPath(Common::FS::SuyuPath::LoadDir) /
|
||||||
fmt::format("{:016X}", program_id);
|
fmt::format("{:016X}", program_id);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -2367,7 +2365,7 @@ void GMainWindow::OnGameListOpenFolder(u64 program_id, GameListOpenTarget target
|
||||||
}
|
}
|
||||||
|
|
||||||
void GMainWindow::OnTransferableShaderCacheOpenFile(u64 program_id) {
|
void GMainWindow::OnTransferableShaderCacheOpenFile(u64 program_id) {
|
||||||
const auto shader_cache_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::ShaderDir);
|
const auto shader_cache_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::ShaderDir);
|
||||||
const auto shader_cache_folder_path{shader_cache_dir / fmt::format("{:016x}", program_id)};
|
const auto shader_cache_folder_path{shader_cache_dir / fmt::format("{:016x}", program_id)};
|
||||||
if (!Common::FS::CreateDirs(shader_cache_folder_path)) {
|
if (!Common::FS::CreateDirs(shader_cache_folder_path)) {
|
||||||
QMessageBox::warning(this, tr("Error Opening Transferable Shader Cache"),
|
QMessageBox::warning(this, tr("Error Opening Transferable Shader Cache"),
|
||||||
|
@ -2486,7 +2484,7 @@ void GMainWindow::OnGameListRemoveInstalledEntry(u64 program_id, InstalledEntryT
|
||||||
RemoveAddOnContent(program_id, type);
|
RemoveAddOnContent(program_id, type);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
Common::FS::RemoveDirRecursively(Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) /
|
Common::FS::RemoveDirRecursively(Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) /
|
||||||
"game_list");
|
"game_list");
|
||||||
game_list->PopulateAsync(UISettings::values.game_dirs);
|
game_list->PopulateAsync(UISettings::values.game_dirs);
|
||||||
}
|
}
|
||||||
|
@ -2592,7 +2590,7 @@ void GMainWindow::RemoveTransferableShaderCache(u64 program_id, GameListRemoveTa
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
}();
|
}();
|
||||||
const auto shader_cache_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::ShaderDir);
|
const auto shader_cache_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::ShaderDir);
|
||||||
const auto shader_cache_folder_path = shader_cache_dir / fmt::format("{:016x}", program_id);
|
const auto shader_cache_folder_path = shader_cache_dir / fmt::format("{:016x}", program_id);
|
||||||
const auto target_file = shader_cache_folder_path / target_file_name;
|
const auto target_file = shader_cache_folder_path / target_file_name;
|
||||||
|
|
||||||
|
@ -2613,7 +2611,7 @@ void GMainWindow::RemoveTransferableShaderCache(u64 program_id, GameListRemoveTa
|
||||||
void GMainWindow::RemoveVulkanDriverPipelineCache(u64 program_id) {
|
void GMainWindow::RemoveVulkanDriverPipelineCache(u64 program_id) {
|
||||||
static constexpr std::string_view target_file_name = "vulkan_pipelines.bin";
|
static constexpr std::string_view target_file_name = "vulkan_pipelines.bin";
|
||||||
|
|
||||||
const auto shader_cache_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::ShaderDir);
|
const auto shader_cache_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::ShaderDir);
|
||||||
const auto shader_cache_folder_path = shader_cache_dir / fmt::format("{:016x}", program_id);
|
const auto shader_cache_folder_path = shader_cache_dir / fmt::format("{:016x}", program_id);
|
||||||
const auto target_file = shader_cache_folder_path / target_file_name;
|
const auto target_file = shader_cache_folder_path / target_file_name;
|
||||||
|
|
||||||
|
@ -2627,7 +2625,7 @@ void GMainWindow::RemoveVulkanDriverPipelineCache(u64 program_id) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void GMainWindow::RemoveAllTransferableShaderCaches(u64 program_id) {
|
void GMainWindow::RemoveAllTransferableShaderCaches(u64 program_id) {
|
||||||
const auto shader_cache_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::ShaderDir);
|
const auto shader_cache_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::ShaderDir);
|
||||||
const auto program_shader_cache_dir = shader_cache_dir / fmt::format("{:016x}", program_id);
|
const auto program_shader_cache_dir = shader_cache_dir / fmt::format("{:016x}", program_id);
|
||||||
|
|
||||||
if (!Common::FS::Exists(program_shader_cache_dir)) {
|
if (!Common::FS::Exists(program_shader_cache_dir)) {
|
||||||
|
@ -2650,7 +2648,7 @@ void GMainWindow::RemoveCustomConfiguration(u64 program_id, const std::string& g
|
||||||
program_id == 0 ? Common::FS::PathToUTF8String(file_path.filename()).append(".ini")
|
program_id == 0 ? Common::FS::PathToUTF8String(file_path.filename()).append(".ini")
|
||||||
: fmt::format("{:016X}.ini", program_id);
|
: fmt::format("{:016X}.ini", program_id);
|
||||||
const auto custom_config_file_path =
|
const auto custom_config_file_path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::ConfigDir) / "custom" / config_file_name;
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::ConfigDir) / "custom" / config_file_name;
|
||||||
|
|
||||||
if (!Common::FS::Exists(custom_config_file_path)) {
|
if (!Common::FS::Exists(custom_config_file_path)) {
|
||||||
QMessageBox::warning(this, tr("Error Removing Custom Configuration"),
|
QMessageBox::warning(this, tr("Error Removing Custom Configuration"),
|
||||||
|
@ -2668,7 +2666,7 @@ void GMainWindow::RemoveCustomConfiguration(u64 program_id, const std::string& g
|
||||||
}
|
}
|
||||||
|
|
||||||
void GMainWindow::RemoveCacheStorage(u64 program_id) {
|
void GMainWindow::RemoveCacheStorage(u64 program_id) {
|
||||||
const auto nand_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir);
|
const auto nand_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir);
|
||||||
auto vfs_nand_dir =
|
auto vfs_nand_dir =
|
||||||
vfs->OpenDirectory(Common::FS::PathToUTF8String(nand_dir), FileSys::OpenMode::Read);
|
vfs->OpenDirectory(Common::FS::PathToUTF8String(nand_dir), FileSys::OpenMode::Read);
|
||||||
|
|
||||||
|
@ -2726,8 +2724,8 @@ void GMainWindow::OnGameListDumpRomFS(u64 program_id, const std::string& game_pa
|
||||||
const auto base_romfs = base_nca->GetRomFS();
|
const auto base_romfs = base_nca->GetRomFS();
|
||||||
const auto dump_dir =
|
const auto dump_dir =
|
||||||
target == DumpRomFSTarget::Normal
|
target == DumpRomFSTarget::Normal
|
||||||
? Common::FS::GetYuzuPath(Common::FS::YuzuPath::DumpDir)
|
? Common::FS::GetSuyuPath(Common::FS::SuyuPath::DumpDir)
|
||||||
: Common::FS::GetYuzuPath(Common::FS::YuzuPath::SDMCDir) / "atmosphere" / "contents";
|
: Common::FS::GetSuyuPath(Common::FS::SuyuPath::SDMCDir) / "atmosphere" / "contents";
|
||||||
const auto romfs_dir = fmt::format("{:016X}/romfs", title_id);
|
const auto romfs_dir = fmt::format("{:016X}/romfs", title_id);
|
||||||
|
|
||||||
const auto path = Common::FS::PathToUTF8String(dump_dir / romfs_dir);
|
const auto path = Common::FS::PathToUTF8String(dump_dir / romfs_dir);
|
||||||
|
@ -2985,7 +2983,7 @@ bool GMainWindow::MakeShortcutIcoPath(const u64 program_id, const std::string_vi
|
||||||
// Get path to Yuzu icons directory & icon extension
|
// Get path to Yuzu icons directory & icon extension
|
||||||
std::string ico_extension = "png";
|
std::string ico_extension = "png";
|
||||||
#if defined(_WIN32)
|
#if defined(_WIN32)
|
||||||
out_icon_path = Common::FS::GetYuzuPath(Common::FS::YuzuPath::IconsDir);
|
out_icon_path = Common::FS::GetSuyuPath(Common::FS::SuyuPath::IconsDir);
|
||||||
ico_extension = "ico";
|
ico_extension = "ico";
|
||||||
#elif defined(__linux__) || defined(__FreeBSD__)
|
#elif defined(__linux__) || defined(__FreeBSD__)
|
||||||
out_icon_path = Common::FS::GetDataDirectory("XDG_DATA_HOME") / "icons/hicolor/256x256";
|
out_icon_path = Common::FS::GetDataDirectory("XDG_DATA_HOME") / "icons/hicolor/256x256";
|
||||||
|
@ -3108,13 +3106,13 @@ void GMainWindow::OnGameListOpenDirectory(const QString& directory) {
|
||||||
std::filesystem::path fs_path;
|
std::filesystem::path fs_path;
|
||||||
if (directory == QStringLiteral("SDMC")) {
|
if (directory == QStringLiteral("SDMC")) {
|
||||||
fs_path =
|
fs_path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::SDMCDir) / "Nintendo/Contents/registered";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::SDMCDir) / "Nintendo/Contents/registered";
|
||||||
} else if (directory == QStringLiteral("UserNAND")) {
|
} else if (directory == QStringLiteral("UserNAND")) {
|
||||||
fs_path =
|
fs_path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "user/Contents/registered";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "user/Contents/registered";
|
||||||
} else if (directory == QStringLiteral("SysNAND")) {
|
} else if (directory == QStringLiteral("SysNAND")) {
|
||||||
fs_path =
|
fs_path =
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::NANDDir) / "system/Contents/registered";
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::NANDDir) / "system/Contents/registered";
|
||||||
} else {
|
} else {
|
||||||
fs_path = directory.toStdString();
|
fs_path = directory.toStdString();
|
||||||
}
|
}
|
||||||
|
@ -3340,7 +3338,7 @@ void GMainWindow::OnMenuInstallToNAND() {
|
||||||
: tr("%n file(s) failed to install\n", "", failed_files.size()));
|
: tr("%n file(s) failed to install\n", "", failed_files.size()));
|
||||||
|
|
||||||
QMessageBox::information(this, tr("Install Results"), install_results);
|
QMessageBox::information(this, tr("Install Results"), install_results);
|
||||||
Common::FS::RemoveDirRecursively(Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) /
|
Common::FS::RemoveDirRecursively(Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) /
|
||||||
"game_list");
|
"game_list");
|
||||||
game_list->PopulateAsync(UISettings::values.game_dirs);
|
game_list->PopulateAsync(UISettings::values.game_dirs);
|
||||||
ui->action_Install_File_NAND->setEnabled(true);
|
ui->action_Install_File_NAND->setEnabled(true);
|
||||||
|
@ -3761,11 +3759,11 @@ void GMainWindow::OnConfigure() {
|
||||||
LOG_WARNING(Frontend, "Failed to remove configuration file");
|
LOG_WARNING(Frontend, "Failed to remove configuration file");
|
||||||
}
|
}
|
||||||
if (!Common::FS::RemoveDirContentsRecursively(
|
if (!Common::FS::RemoveDirContentsRecursively(
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::ConfigDir) / "custom")) {
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::ConfigDir) / "custom")) {
|
||||||
LOG_WARNING(Frontend, "Failed to remove custom configuration files");
|
LOG_WARNING(Frontend, "Failed to remove custom configuration files");
|
||||||
}
|
}
|
||||||
if (!Common::FS::RemoveDirRecursively(
|
if (!Common::FS::RemoveDirRecursively(
|
||||||
Common::FS::GetYuzuPath(Common::FS::YuzuPath::CacheDir) / "game_list")) {
|
Common::FS::GetSuyuPath(Common::FS::SuyuPath::CacheDir) / "game_list")) {
|
||||||
LOG_WARNING(Frontend, "Failed to remove game metadata cache files");
|
LOG_WARNING(Frontend, "Failed to remove game metadata cache files");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4123,7 +4121,7 @@ void GMainWindow::LoadAmiibo(const QString& filename) {
|
||||||
|
|
||||||
void GMainWindow::OnOpenYuzuFolder() {
|
void GMainWindow::OnOpenYuzuFolder() {
|
||||||
QDesktopServices::openUrl(QUrl::fromLocalFile(
|
QDesktopServices::openUrl(QUrl::fromLocalFile(
|
||||||
QString::fromStdString(Common::FS::GetYuzuPathString(Common::FS::YuzuPath::YuzuDir))));
|
QString::fromStdString(Common::FS::GetSuyuPathString(Common::FS::SuyuPath::SuyuDir))));
|
||||||
}
|
}
|
||||||
|
|
||||||
void GMainWindow::OnVerifyInstalledContents() {
|
void GMainWindow::OnVerifyInstalledContents() {
|
||||||
|
@ -4338,7 +4336,7 @@ void GMainWindow::OnInstallDecryptionKeys() {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto yuzu_keys_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::KeysDir);
|
const auto yuzu_keys_dir = Common::FS::GetSuyuPath(Common::FS::SuyuPath::KeysDir);
|
||||||
for (auto key_file : source_key_files) {
|
for (auto key_file : source_key_files) {
|
||||||
std::filesystem::path destination_key_file = yuzu_keys_dir / key_file.filename();
|
std::filesystem::path destination_key_file = yuzu_keys_dir / key_file.filename();
|
||||||
if (!std::filesystem::copy_file(key_file, destination_key_file,
|
if (!std::filesystem::copy_file(key_file, destination_key_file,
|
||||||
|
@ -4491,7 +4489,7 @@ void GMainWindow::OnCaptureScreenshot() {
|
||||||
|
|
||||||
const u64 title_id = system->GetApplicationProcessProgramID();
|
const u64 title_id = system->GetApplicationProcessProgramID();
|
||||||
const auto screenshot_path =
|
const auto screenshot_path =
|
||||||
QString::fromStdString(Common::FS::GetYuzuPathString(Common::FS::YuzuPath::ScreenshotsDir));
|
QString::fromStdString(Common::FS::GetSuyuPathString(Common::FS::SuyuPath::ScreenshotsDir));
|
||||||
const auto date =
|
const auto date =
|
||||||
QDateTime::currentDateTime().toString(QStringLiteral("yyyy-MM-dd_hh-mm-ss-zzz"));
|
QDateTime::currentDateTime().toString(QStringLiteral("yyyy-MM-dd_hh-mm-ss-zzz"));
|
||||||
QString filename = QStringLiteral("%1/%2_%3.png")
|
QString filename = QStringLiteral("%1/%2_%3.png")
|
||||||
|
@ -4519,7 +4517,7 @@ void GMainWindow::OnCaptureScreenshot() {
|
||||||
|
|
||||||
// TODO: Written 2020-10-01: Remove per-game config migration code when it is irrelevant
|
// TODO: Written 2020-10-01: Remove per-game config migration code when it is irrelevant
|
||||||
void GMainWindow::MigrateConfigFiles() {
|
void GMainWindow::MigrateConfigFiles() {
|
||||||
const auto config_dir_fs_path = Common::FS::GetYuzuPath(Common::FS::YuzuPath::ConfigDir);
|
const auto config_dir_fs_path = Common::FS::GetSuyuPath(Common::FS::SuyuPath::ConfigDir);
|
||||||
const QDir config_dir =
|
const QDir config_dir =
|
||||||
QDir(QString::fromStdString(Common::FS::PathToUTF8String(config_dir_fs_path)));
|
QDir(QString::fromStdString(Common::FS::PathToUTF8String(config_dir_fs_path)));
|
||||||
const QStringList config_dir_list = config_dir.entryList(QStringList(QStringLiteral("*.ini")));
|
const QStringList config_dir_list = config_dir.entryList(QStringList(QStringLiteral("*.ini")));
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project
|
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include "common/alignment.h"
|
#include "common/alignment.h"
|
||||||
|
@ -26,7 +26,7 @@ std::optional<std::filesystem::path> GetCurrentUserPlayTimePath(
|
||||||
if (!uuid.has_value()) {
|
if (!uuid.has_value()) {
|
||||||
return std::nullopt;
|
return std::nullopt;
|
||||||
}
|
}
|
||||||
return Common::FS::GetYuzuPath(Common::FS::YuzuPath::PlayTimeDir) /
|
return Common::FS::GetSuyuPath(Common::FS::SuyuPath::PlayTimeDir) /
|
||||||
uuid->RawString().append(".bin");
|
uuid->RawString().append(".bin");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include "video_core/vulkan_common/vulkan_wrapper.h"
|
#include "video_core/vulkan_common/vulkan_wrapper.h"
|
||||||
|
@ -7,7 +7,7 @@
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
#include <processthreadsapi.h>
|
#include <processthreadsapi.h>
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#elif defined(YUZU_UNIX)
|
#elif defined(SUYU_UNIX)
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <spawn.h>
|
#include <spawn.h>
|
||||||
|
@ -56,7 +56,7 @@ bool CheckEnvVars(bool* is_child) {
|
||||||
IS_CHILD_ENV_VAR, GetLastError());
|
IS_CHILD_ENV_VAR, GetLastError());
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
#elif defined(YUZU_UNIX)
|
#elif defined(SUYU_UNIX)
|
||||||
const char* startup_check_var = getenv(STARTUP_CHECK_ENV_VAR);
|
const char* startup_check_var = getenv(STARTUP_CHECK_ENV_VAR);
|
||||||
if (startup_check_var != nullptr &&
|
if (startup_check_var != nullptr &&
|
||||||
std::strncmp(startup_check_var, ENV_VAR_ENABLED_TEXT, 8) == 0) {
|
std::strncmp(startup_check_var, ENV_VAR_ENABLED_TEXT, 8) == 0) {
|
||||||
|
@ -110,7 +110,7 @@ bool StartupChecks(const char* arg0, bool* has_broken_vulkan, bool perform_vulka
|
||||||
STARTUP_CHECK_ENV_VAR, GetLastError());
|
STARTUP_CHECK_ENV_VAR, GetLastError());
|
||||||
}
|
}
|
||||||
|
|
||||||
#elif defined(YUZU_UNIX)
|
#elif defined(SUYU_UNIX)
|
||||||
const int env_var_set = setenv(STARTUP_CHECK_ENV_VAR, ENV_VAR_ENABLED_TEXT, 1);
|
const int env_var_set = setenv(STARTUP_CHECK_ENV_VAR, ENV_VAR_ENABLED_TEXT, 1);
|
||||||
if (env_var_set == -1) {
|
if (env_var_set == -1) {
|
||||||
const int err = errno;
|
const int err = errno;
|
||||||
|
@ -175,7 +175,7 @@ bool SpawnChild(const char* arg0, PROCESS_INFORMATION* pi, int flags) {
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
#elif defined(YUZU_UNIX)
|
#elif defined(SUYU_UNIX)
|
||||||
pid_t SpawnChild(const char* arg0) {
|
pid_t SpawnChild(const char* arg0) {
|
||||||
const pid_t pid = fork();
|
const pid_t pid = fork();
|
||||||
|
|
||||||
|
|
|
@ -1,16 +1,16 @@
|
||||||
// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#elif defined(YUZU_UNIX)
|
#elif defined(SUYU_UNIX)
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
constexpr char IS_CHILD_ENV_VAR[] = "YUZU_IS_CHILD";
|
constexpr char IS_CHILD_ENV_VAR[] = "SUYU_IS_CHILD";
|
||||||
constexpr char STARTUP_CHECK_ENV_VAR[] = "YUZU_DO_STARTUP_CHECKS";
|
constexpr char STARTUP_CHECK_ENV_VAR[] = "SUYU_DO_STARTUP_CHECKS";
|
||||||
constexpr char ENV_VAR_ENABLED_TEXT[] = "ON";
|
constexpr char ENV_VAR_ENABLED_TEXT[] = "ON";
|
||||||
|
|
||||||
void CheckVulkan();
|
void CheckVulkan();
|
||||||
|
@ -19,6 +19,6 @@ bool StartupChecks(const char* arg0, bool* has_broken_vulkan, bool perform_vulka
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
bool SpawnChild(const char* arg0, PROCESS_INFORMATION* pi, int flags);
|
bool SpawnChild(const char* arg0, PROCESS_INFORMATION* pi, int flags);
|
||||||
#elif defined(YUZU_UNIX)
|
#elif defined(SUYU_UNIX)
|
||||||
pid_t SpawnChild(const char* arg0);
|
pid_t SpawnChild(const char* arg0);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
<!--
|
<!--
|
||||||
SPDX-FileCopyrightText: 2021 yuzu Emulator Project & 2024 suyu Emulator Project
|
SPDX-FileCopyrightText: 2021 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
SPDX-License-Identifier: GPL-2.0-or-later
|
SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
Modified by JuanCStar on 2024/03/06
|
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<RCC>
|
<RCC>
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
// SPDX-FileCopyrightText: 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
// SPDX-FileCopyrightText: 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
// Modified by JuanCStar on 2024/03/06
|
|
||||||
|
|
||||||
#include "winresrc.h"
|
#include "winresrc.h"
|
||||||
/////////////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////////////
|
||||||
//
|
//
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2016 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2016 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <QSettings>
|
#include <QSettings>
|
||||||
|
@ -57,7 +57,7 @@ u32 CalculateWidth(u32 height, Settings::AspectRatio ratio) {
|
||||||
|
|
||||||
void SaveWindowState() {
|
void SaveWindowState() {
|
||||||
const auto window_state_config_loc =
|
const auto window_state_config_loc =
|
||||||
FS::PathToUTF8String(FS::GetYuzuPath(FS::YuzuPath::ConfigDir) / "window_state.ini");
|
FS::PathToUTF8String(FS::GetSuyuPath(FS::SuyuPath::ConfigDir) / "window_state.ini");
|
||||||
|
|
||||||
void(FS::CreateParentDir(window_state_config_loc));
|
void(FS::CreateParentDir(window_state_config_loc));
|
||||||
QSettings config(QString::fromStdString(window_state_config_loc), QSettings::IniFormat);
|
QSettings config(QString::fromStdString(window_state_config_loc), QSettings::IniFormat);
|
||||||
|
@ -73,12 +73,12 @@ void SaveWindowState() {
|
||||||
|
|
||||||
void RestoreWindowState(std::unique_ptr<QtConfig>& qtConfig) {
|
void RestoreWindowState(std::unique_ptr<QtConfig>& qtConfig) {
|
||||||
const auto window_state_config_loc =
|
const auto window_state_config_loc =
|
||||||
FS::PathToUTF8String(FS::GetYuzuPath(FS::YuzuPath::ConfigDir) / "window_state.ini");
|
FS::PathToUTF8String(FS::GetSuyuPath(FS::SuyuPath::ConfigDir) / "window_state.ini");
|
||||||
|
|
||||||
// Migrate window state from old location
|
// Migrate window state from old location
|
||||||
if (!FS::Exists(window_state_config_loc) && qtConfig->Exists("UI", "UILayout\\geometry")) {
|
if (!FS::Exists(window_state_config_loc) && qtConfig->Exists("UI", "UILayout\\geometry")) {
|
||||||
const auto config_loc =
|
const auto config_loc =
|
||||||
FS::PathToUTF8String(FS::GetYuzuPath(FS::YuzuPath::ConfigDir) / "qt-config.ini");
|
FS::PathToUTF8String(FS::GetSuyuPath(FS::SuyuPath::ConfigDir) / "qt-config.ini");
|
||||||
QSettings config(QString::fromStdString(config_loc), QSettings::IniFormat);
|
QSettings config(QString::fromStdString(config_loc), QSettings::IniFormat);
|
||||||
|
|
||||||
config.beginGroup(QStringLiteral("UI"));
|
config.beginGroup(QStringLiteral("UI"));
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2016 Citra Emulator Project
|
// SPDX-FileCopyrightText: 2016 Citra Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
@ -239,7 +239,7 @@ const std::array<Shortcut, 28> default_hotkeys{{
|
||||||
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Change GPU Accuracy")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("F9"), std::string("Home+R"), Qt::ApplicationShortcut, false}},
|
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Change GPU Accuracy")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("F9"), std::string("Home+R"), Qt::ApplicationShortcut, false}},
|
||||||
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Continue/Pause Emulation")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("F4"), std::string("Home+Plus"), Qt::WindowShortcut, false}},
|
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Continue/Pause Emulation")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("F4"), std::string("Home+Plus"), Qt::WindowShortcut, false}},
|
||||||
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Exit Fullscreen")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("Esc"), std::string(""), Qt::WindowShortcut, false}},
|
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Exit Fullscreen")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("Esc"), std::string(""), Qt::WindowShortcut, false}},
|
||||||
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Exit yuzu")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("Ctrl+Q"), std::string("Home+Minus"), Qt::WindowShortcut, false}},
|
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Exit suyu")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("Ctrl+Q"), std::string("Home+Minus"), Qt::WindowShortcut, false}},
|
||||||
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Fullscreen")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("F11"), std::string("Home+B"), Qt::WindowShortcut, false}},
|
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Fullscreen")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("F11"), std::string("Home+B"), Qt::WindowShortcut, false}},
|
||||||
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Load File")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("Ctrl+O"), std::string(""), Qt::WidgetWithChildrenShortcut, false}},
|
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Load File")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("Ctrl+O"), std::string(""), Qt::WidgetWithChildrenShortcut, false}},
|
||||||
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Load/Remove Amiibo")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("F2"), std::string("Home+A"), Qt::WidgetWithChildrenShortcut, false}},
|
{QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Load/Remove Amiibo")).toStdString(), QStringLiteral(QT_TRANSLATE_NOOP("Hotkeys", "Main Window")).toStdString(), {std::string("F2"), std::string("Home+A"), Qt::WidgetWithChildrenShortcut, false}},
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project
|
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project
|
// SPDX-FileCopyrightText: 2023 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
# SPDX-FileCopyrightText: 2018 yuzu Emulator Project
|
# SPDX-FileCopyrightText: 2018 yuzu Emulator Project
|
||||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
# Modified by JuanCStar on 2024/03/06
|
|
||||||
|
|
||||||
# Credits to Samantas5855 and others for this function.
|
# Credits to Samantas5855 and others for this function.
|
||||||
function(create_resource file output filename)
|
function(create_resource file output filename)
|
||||||
# Read hex data from file
|
# Read hex data from file
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
// SPDX-FileCopyrightText: 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
// SPDX-FileCopyrightText: 2018 yuzu Emulator Project & 2024 suyu Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
// Modified by JuanCStar on 2024/03/06
|
|
||||||
|
|
||||||
#include "winresrc.h"
|
#include "winresrc.h"
|
||||||
/////////////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////////////
|
||||||
//
|
//
|
||||||
|
|
Loading…
Reference in a new issue