From 4e8c178aecc2d968095a8cc3d88f4290b29b0ed3 Mon Sep 17 00:00:00 2001 From: Vinicius Rangel Date: Fri, 17 Jan 2025 16:11:37 -0300 Subject: [PATCH 01/99] imgui: central node auto-hide tab (#2174) --- src/imgui/renderer/imgui_core.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/imgui/renderer/imgui_core.cpp b/src/imgui/renderer/imgui_core.cpp index f3e4609ba..26253822c 100644 --- a/src/imgui/renderer/imgui_core.cpp +++ b/src/imgui/renderer/imgui_core.cpp @@ -186,7 +186,8 @@ ImGuiID NewFrame(bool is_reusing_frame) { Sdl::NewFrame(is_reusing_frame); ImGui::NewFrame(); - ImGuiWindowFlags flags = ImGuiDockNodeFlags_PassthruCentralNode; + ImGuiWindowFlags flags = + ImGuiDockNodeFlags_PassthruCentralNode | ImGuiDockNodeFlags_AutoHideTabBar; if (!DebugState.IsShowingDebugMenuBar()) { flags |= ImGuiDockNodeFlags_NoTabBar; } From 99a04357d139461e741c2003733e74af3ede6747 Mon Sep 17 00:00:00 2001 From: polybiusproxy <47796739+polybiusproxy@users.noreply.github.com> Date: Fri, 17 Jan 2025 21:51:33 +0100 Subject: [PATCH 02/99] don't compile cs with higher shared memory than supported (#2175) --- src/shader_recompiler/backend/spirv/spirv_emit_context.cpp | 4 ++++ src/shader_recompiler/runtime_info.h | 1 + src/video_core/renderer_vulkan/vk_instance.h | 5 +++++ src/video_core/renderer_vulkan/vk_pipeline_cache.cpp | 1 + 4 files changed, 11 insertions(+) diff --git a/src/shader_recompiler/backend/spirv/spirv_emit_context.cpp b/src/shader_recompiler/backend/spirv/spirv_emit_context.cpp index 7d492a384..295bef75d 100644 --- a/src/shader_recompiler/backend/spirv/spirv_emit_context.cpp +++ b/src/shader_recompiler/backend/spirv/spirv_emit_context.cpp @@ -847,6 +847,10 @@ void EmitContext::DefineSharedMemory() { if (shared_memory_size == 0) { shared_memory_size = DefaultSharedMemSize; } + + const u32 max_shared_memory_size = runtime_info.cs_info.max_shared_memory_size; + ASSERT(shared_memory_size <= max_shared_memory_size); + const u32 num_elements{Common::DivCeil(shared_memory_size, 4U)}; const Id type{TypeArray(U32[1], ConstU32(num_elements))}; shared_memory_u32_type = TypePointer(spv::StorageClass::Workgroup, type); diff --git a/src/shader_recompiler/runtime_info.h b/src/shader_recompiler/runtime_info.h index cf49b0879..8a5e0a1a6 100644 --- a/src/shader_recompiler/runtime_info.h +++ b/src/shader_recompiler/runtime_info.h @@ -198,6 +198,7 @@ struct FragmentRuntimeInfo { struct ComputeRuntimeInfo { u32 shared_memory_size; + u32 max_shared_memory_size; std::array workgroup_size; std::array tgid_enable; diff --git a/src/video_core/renderer_vulkan/vk_instance.h b/src/video_core/renderer_vulkan/vk_instance.h index e0d4d0b4d..1b0c276dc 100644 --- a/src/video_core/renderer_vulkan/vk_instance.h +++ b/src/video_core/renderer_vulkan/vk_instance.h @@ -239,6 +239,11 @@ public: return subgroup_size; } + /// Returns the maximum size of compute shared memory. + u32 MaxComputeSharedMemorySize() const { + return properties.limits.maxComputeSharedMemorySize; + } + /// Returns the maximum supported elements in a texel buffer u32 MaxTexelBufferElements() const { return properties.limits.maxTexelBufferElements; diff --git a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp index f93494389..86f6dcc7a 100644 --- a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp +++ b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp @@ -183,6 +183,7 @@ const Shader::RuntimeInfo& PipelineCache::BuildRuntimeInfo(Stage stage, LogicalS info.cs_info.tgid_enable = {cs_pgm.IsTgidEnabled(0), cs_pgm.IsTgidEnabled(1), cs_pgm.IsTgidEnabled(2)}; info.cs_info.shared_memory_size = cs_pgm.SharedMemSize(); + info.cs_info.max_shared_memory_size = instance.MaxComputeSharedMemorySize(); break; } default: From e134fc5f1e0492102f75e30aa3cefd512128c59c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C2=A5IGA?= <164882787+Xphalnos@users.noreply.github.com> Date: Sat, 18 Jan 2025 07:09:10 +0100 Subject: [PATCH 03/99] Qt: Open shadPS4 Folder (#2107) * Qt: Open shadPS4 Folder * clang-format * Change order * Update pt_BR.ts --- src/qt_gui/main_window.cpp | 7 +++++++ src/qt_gui/main_window_ui.h | 8 ++++++++ src/qt_gui/translations/ar.ts | 4 ++++ src/qt_gui/translations/da_DK.ts | 4 ++++ src/qt_gui/translations/de.ts | 4 ++++ src/qt_gui/translations/el.ts | 4 ++++ src/qt_gui/translations/en.ts | 4 ++++ src/qt_gui/translations/es_ES.ts | 4 ++++ src/qt_gui/translations/fa_IR.ts | 4 ++++ src/qt_gui/translations/fi.ts | 4 ++++ src/qt_gui/translations/fr.ts | 4 ++++ src/qt_gui/translations/hu_HU.ts | 4 ++++ src/qt_gui/translations/id.ts | 4 ++++ src/qt_gui/translations/it.ts | 4 ++++ src/qt_gui/translations/ja_JP.ts | 4 ++++ src/qt_gui/translations/ko_KR.ts | 4 ++++ src/qt_gui/translations/lt_LT.ts | 4 ++++ src/qt_gui/translations/nb.ts | 4 ++++ src/qt_gui/translations/nl.ts | 4 ++++ src/qt_gui/translations/pl_PL.ts | 4 ++++ src/qt_gui/translations/pt_BR.ts | 6 +++++- src/qt_gui/translations/ro_RO.ts | 4 ++++ src/qt_gui/translations/ru_RU.ts | 4 ++++ src/qt_gui/translations/sq.ts | 4 ++++ src/qt_gui/translations/sv.ts | 4 ++++ src/qt_gui/translations/tr_TR.ts | 4 ++++ src/qt_gui/translations/uk_UA.ts | 4 ++++ src/qt_gui/translations/vi_VN.ts | 4 ++++ src/qt_gui/translations/zh_CN.ts | 4 ++++ src/qt_gui/translations/zh_TW.ts | 4 ++++ 30 files changed, 128 insertions(+), 1 deletion(-) diff --git a/src/qt_gui/main_window.cpp b/src/qt_gui/main_window.cpp index bd3c27809..3ee392613 100644 --- a/src/qt_gui/main_window.cpp +++ b/src/qt_gui/main_window.cpp @@ -247,6 +247,12 @@ void MainWindow::CreateConnects() { } }); + connect(ui->shadFolderAct, &QAction::triggered, this, [this]() { + QString userPath; + Common::FS::PathToQString(userPath, Common::FS::GetUserPath(Common::FS::PathType::UserDir)); + QDesktopServices::openUrl(QUrl::fromLocalFile(userPath)); + }); + connect(ui->playButton, &QPushButton::clicked, this, &MainWindow::StartGame); connect(m_game_grid_frame.get(), &QTableWidget::cellDoubleClicked, this, &MainWindow::StartGame); @@ -982,6 +988,7 @@ QIcon MainWindow::RecolorIcon(const QIcon& icon, bool isWhite) { void MainWindow::SetUiIcons(bool isWhite) { ui->bootInstallPkgAct->setIcon(RecolorIcon(ui->bootInstallPkgAct->icon(), isWhite)); ui->bootGameAct->setIcon(RecolorIcon(ui->bootGameAct->icon(), isWhite)); + ui->shadFolderAct->setIcon(RecolorIcon(ui->shadFolderAct->icon(), isWhite)); ui->exitAct->setIcon(RecolorIcon(ui->exitAct->icon(), isWhite)); #ifdef ENABLE_UPDATER ui->updaterAct->setIcon(RecolorIcon(ui->updaterAct->icon(), isWhite)); diff --git a/src/qt_gui/main_window_ui.h b/src/qt_gui/main_window_ui.h index 0d5038d7e..7de166121 100644 --- a/src/qt_gui/main_window_ui.h +++ b/src/qt_gui/main_window_ui.h @@ -12,6 +12,7 @@ public: QAction* bootInstallPkgAct; QAction* bootGameAct; QAction* addElfFolderAct; + QAction* shadFolderAct; QAction* exitAct; QAction* showGameListAct; QAction* refreshGameListAct; @@ -89,6 +90,9 @@ public: addElfFolderAct = new QAction(MainWindow); addElfFolderAct->setObjectName("addElfFolderAct"); addElfFolderAct->setIcon(QIcon(":images/folder_icon.png")); + shadFolderAct = new QAction(MainWindow); + shadFolderAct->setObjectName("shadFolderAct"); + shadFolderAct->setIcon(QIcon(":images/folder_icon.png")); exitAct = new QAction(MainWindow); exitAct->setObjectName("exitAct"); exitAct->setIcon(QIcon(":images/exit_icon.png")); @@ -274,7 +278,9 @@ public: menuBar->addAction(menuHelp->menuAction()); menuFile->addAction(bootInstallPkgAct); menuFile->addAction(bootGameAct); + menuFile->addSeparator(); menuFile->addAction(addElfFolderAct); + menuFile->addAction(shadFolderAct); menuFile->addSeparator(); menuFile->addAction(menuRecent->menuAction()); menuFile->addSeparator(); @@ -333,6 +339,8 @@ public: "MainWindow", "Install application from a .pkg file", nullptr)); #endif // QT_CONFIG(tooltip) menuRecent->setTitle(QCoreApplication::translate("MainWindow", "Recent Games", nullptr)); + shadFolderAct->setText( + QCoreApplication::translate("MainWindow", "Open shadPS4 Folder", nullptr)); exitAct->setText(QCoreApplication::translate("MainWindow", "Exit", nullptr)); #if QT_CONFIG(tooltip) exitAct->setToolTip(QCoreApplication::translate("MainWindow", "Exit shadPS4", nullptr)); diff --git a/src/qt_gui/translations/ar.ts b/src/qt_gui/translations/ar.ts index a4dadcb1a..47bd673b2 100644 --- a/src/qt_gui/translations/ar.ts +++ b/src/qt_gui/translations/ar.ts @@ -247,6 +247,10 @@ Recent Games الألعاب الأخيرة + + Open shadPS4 Folder + Open shadPS4 Folder + Exit خروج diff --git a/src/qt_gui/translations/da_DK.ts b/src/qt_gui/translations/da_DK.ts index 70b7d3ecc..91a98abd4 100644 --- a/src/qt_gui/translations/da_DK.ts +++ b/src/qt_gui/translations/da_DK.ts @@ -247,6 +247,10 @@ Recent Games Recent Games + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Exit diff --git a/src/qt_gui/translations/de.ts b/src/qt_gui/translations/de.ts index 7f1de3afd..b1e1d2664 100644 --- a/src/qt_gui/translations/de.ts +++ b/src/qt_gui/translations/de.ts @@ -247,6 +247,10 @@ Recent Games Zuletzt gespielt + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Beenden diff --git a/src/qt_gui/translations/el.ts b/src/qt_gui/translations/el.ts index 84165536e..ecda0ede0 100644 --- a/src/qt_gui/translations/el.ts +++ b/src/qt_gui/translations/el.ts @@ -247,6 +247,10 @@ Recent Games Recent Games + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Exit diff --git a/src/qt_gui/translations/en.ts b/src/qt_gui/translations/en.ts index fad185d41..9127df7e3 100644 --- a/src/qt_gui/translations/en.ts +++ b/src/qt_gui/translations/en.ts @@ -247,6 +247,10 @@ Recent Games Recent Games + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Exit diff --git a/src/qt_gui/translations/es_ES.ts b/src/qt_gui/translations/es_ES.ts index a97d3d3c8..a47f7c577 100644 --- a/src/qt_gui/translations/es_ES.ts +++ b/src/qt_gui/translations/es_ES.ts @@ -247,6 +247,10 @@ Recent Games Juegos recientes + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Salir diff --git a/src/qt_gui/translations/fa_IR.ts b/src/qt_gui/translations/fa_IR.ts index 697e615fb..976e7614e 100644 --- a/src/qt_gui/translations/fa_IR.ts +++ b/src/qt_gui/translations/fa_IR.ts @@ -247,6 +247,10 @@ Recent Games بازی های اخیر + + Open shadPS4 Folder + Open shadPS4 Folder + Exit خروج diff --git a/src/qt_gui/translations/fi.ts b/src/qt_gui/translations/fi.ts index 51e85dfbb..abc091b7e 100644 --- a/src/qt_gui/translations/fi.ts +++ b/src/qt_gui/translations/fi.ts @@ -247,6 +247,10 @@ Recent Games Viimeisimmät Pelit + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Sulje diff --git a/src/qt_gui/translations/fr.ts b/src/qt_gui/translations/fr.ts index 35f3eb55f..d2a1c5307 100644 --- a/src/qt_gui/translations/fr.ts +++ b/src/qt_gui/translations/fr.ts @@ -247,6 +247,10 @@ Recent Games Jeux récents + + Open shadPS4 Folder + Ouvrir le dossier de shadPS4 + Exit Fermer diff --git a/src/qt_gui/translations/hu_HU.ts b/src/qt_gui/translations/hu_HU.ts index a2bd9c1da..dff6a3a18 100644 --- a/src/qt_gui/translations/hu_HU.ts +++ b/src/qt_gui/translations/hu_HU.ts @@ -247,6 +247,10 @@ Recent Games Legutóbbi Játékok + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Kilépés diff --git a/src/qt_gui/translations/id.ts b/src/qt_gui/translations/id.ts index b97914ca2..e6fb8b5aa 100644 --- a/src/qt_gui/translations/id.ts +++ b/src/qt_gui/translations/id.ts @@ -247,6 +247,10 @@ Recent Games Recent Games + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Exit diff --git a/src/qt_gui/translations/it.ts b/src/qt_gui/translations/it.ts index d4ea1c7e6..73dbdc603 100644 --- a/src/qt_gui/translations/it.ts +++ b/src/qt_gui/translations/it.ts @@ -247,6 +247,10 @@ Recent Games Giochi Recenti + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Uscita diff --git a/src/qt_gui/translations/ja_JP.ts b/src/qt_gui/translations/ja_JP.ts index 359955765..e07d4eb25 100644 --- a/src/qt_gui/translations/ja_JP.ts +++ b/src/qt_gui/translations/ja_JP.ts @@ -247,6 +247,10 @@ Recent Games 最近のゲーム + + Open shadPS4 Folder + Open shadPS4 Folder + Exit 終了 diff --git a/src/qt_gui/translations/ko_KR.ts b/src/qt_gui/translations/ko_KR.ts index 9cca0b656..560b58340 100644 --- a/src/qt_gui/translations/ko_KR.ts +++ b/src/qt_gui/translations/ko_KR.ts @@ -247,6 +247,10 @@ Recent Games Recent Games + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Exit diff --git a/src/qt_gui/translations/lt_LT.ts b/src/qt_gui/translations/lt_LT.ts index 0594bcbd2..e2ec1e5c3 100644 --- a/src/qt_gui/translations/lt_LT.ts +++ b/src/qt_gui/translations/lt_LT.ts @@ -247,6 +247,10 @@ Recent Games Recent Games + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Exit diff --git a/src/qt_gui/translations/nb.ts b/src/qt_gui/translations/nb.ts index 8ca8246ba..b94d29b23 100644 --- a/src/qt_gui/translations/nb.ts +++ b/src/qt_gui/translations/nb.ts @@ -247,6 +247,10 @@ Recent Games Nylige spill + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Avslutt diff --git a/src/qt_gui/translations/nl.ts b/src/qt_gui/translations/nl.ts index 12d644458..add27500f 100644 --- a/src/qt_gui/translations/nl.ts +++ b/src/qt_gui/translations/nl.ts @@ -247,6 +247,10 @@ Recent Games Recent Games + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Exit diff --git a/src/qt_gui/translations/pl_PL.ts b/src/qt_gui/translations/pl_PL.ts index 782db12e2..3280beea7 100644 --- a/src/qt_gui/translations/pl_PL.ts +++ b/src/qt_gui/translations/pl_PL.ts @@ -247,6 +247,10 @@ Recent Games Ostatnie gry + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Wyjdź diff --git a/src/qt_gui/translations/pt_BR.ts b/src/qt_gui/translations/pt_BR.ts index 94bbf028a..b9d889519 100644 --- a/src/qt_gui/translations/pt_BR.ts +++ b/src/qt_gui/translations/pt_BR.ts @@ -247,6 +247,10 @@ Recent Games Jogos Recentes + + Open shadPS4 Folder + Abrir pasta shadPS4 + Exit Sair @@ -1341,4 +1345,4 @@ TB - \ No newline at end of file + diff --git a/src/qt_gui/translations/ro_RO.ts b/src/qt_gui/translations/ro_RO.ts index 3bd8e38b5..00a9eb179 100644 --- a/src/qt_gui/translations/ro_RO.ts +++ b/src/qt_gui/translations/ro_RO.ts @@ -247,6 +247,10 @@ Recent Games Recent Games + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Exit diff --git a/src/qt_gui/translations/ru_RU.ts b/src/qt_gui/translations/ru_RU.ts index a38e2fd98..4c90450dd 100644 --- a/src/qt_gui/translations/ru_RU.ts +++ b/src/qt_gui/translations/ru_RU.ts @@ -247,6 +247,10 @@ Recent Games Недавние игры + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Выход diff --git a/src/qt_gui/translations/sq.ts b/src/qt_gui/translations/sq.ts index a83dc9829..768db1e75 100644 --- a/src/qt_gui/translations/sq.ts +++ b/src/qt_gui/translations/sq.ts @@ -247,6 +247,10 @@ Recent Games Lojërat e fundit + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Dil diff --git a/src/qt_gui/translations/sv.ts b/src/qt_gui/translations/sv.ts index 9a244a9df..3781ba45c 100644 --- a/src/qt_gui/translations/sv.ts +++ b/src/qt_gui/translations/sv.ts @@ -722,6 +722,10 @@ Recent Games Senaste spel + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Avsluta diff --git a/src/qt_gui/translations/tr_TR.ts b/src/qt_gui/translations/tr_TR.ts index be50f935a..5e8499073 100644 --- a/src/qt_gui/translations/tr_TR.ts +++ b/src/qt_gui/translations/tr_TR.ts @@ -247,6 +247,10 @@ Recent Games Son Oyunlar + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Çıkış diff --git a/src/qt_gui/translations/uk_UA.ts b/src/qt_gui/translations/uk_UA.ts index ff4e48e80..a1c7e97e0 100644 --- a/src/qt_gui/translations/uk_UA.ts +++ b/src/qt_gui/translations/uk_UA.ts @@ -247,6 +247,10 @@ Recent Games Нещодавні ігри + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Вихід diff --git a/src/qt_gui/translations/vi_VN.ts b/src/qt_gui/translations/vi_VN.ts index e546d955c..a579a1983 100644 --- a/src/qt_gui/translations/vi_VN.ts +++ b/src/qt_gui/translations/vi_VN.ts @@ -247,6 +247,10 @@ Recent Games Recent Games + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Exit diff --git a/src/qt_gui/translations/zh_CN.ts b/src/qt_gui/translations/zh_CN.ts index ece5f9490..5450f3dfd 100644 --- a/src/qt_gui/translations/zh_CN.ts +++ b/src/qt_gui/translations/zh_CN.ts @@ -247,6 +247,10 @@ Recent Games 最近启动的游戏 + + Open shadPS4 Folder + Open shadPS4 Folder + Exit 退出 diff --git a/src/qt_gui/translations/zh_TW.ts b/src/qt_gui/translations/zh_TW.ts index 11642d52b..0ce0b4d69 100644 --- a/src/qt_gui/translations/zh_TW.ts +++ b/src/qt_gui/translations/zh_TW.ts @@ -247,6 +247,10 @@ Recent Games Recent Games + + Open shadPS4 Folder + Open shadPS4 Folder + Exit Exit From a5440e0e43f1d91fff0b23e0c0ba4103d5e8976e Mon Sep 17 00:00:00 2001 From: Ian Maclachlan <32774670+imaclachlan@users.noreply.github.com> Date: Sat, 18 Jan 2025 06:16:07 +0000 Subject: [PATCH 04/99] Update kernel.cpp (#2125) In kernel.cpp boost io_context.reset() deprecated/discontinued in latest versions. Changed to io_context.restart() as recommended. --- src/core/libraries/kernel/kernel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/libraries/kernel/kernel.cpp b/src/core/libraries/kernel/kernel.cpp index a9d04ca38..2b7735219 100644 --- a/src/core/libraries/kernel/kernel.cpp +++ b/src/core/libraries/kernel/kernel.cpp @@ -60,7 +60,7 @@ static void KernelServiceThread(std::stop_token stoken) { } io_context.run(); - io_context.reset(); + io_context.restart(); asio_requests = 0; } From 7b8177f48e3d5dfa12b2d416fdf291572e56b905 Mon Sep 17 00:00:00 2001 From: Vladislav Mikhalin Date: Sat, 18 Jan 2025 09:20:38 +0300 Subject: [PATCH 05/99] renderer: handle disabled clipping (#2146) Co-authored-by: IndecisiveTurtle <47210458+raphaelthegreat@users.noreply.github.com> --- .../backend/spirv/emit_spirv_special.cpp | 38 +++++++++++ .../backend/spirv/spirv_emit_context.cpp | 37 ++++++---- src/shader_recompiler/info.h | 8 +++ src/shader_recompiler/profile.h | 2 + src/shader_recompiler/runtime_info.h | 4 +- .../renderer_vulkan/vk_graphics_pipeline.h | 7 +- .../renderer_vulkan/vk_instance.cpp | 6 ++ src/video_core/renderer_vulkan/vk_instance.h | 8 +++ .../renderer_vulkan/vk_pipeline_cache.cpp | 5 ++ .../renderer_vulkan/vk_rasterizer.cpp | 67 ++++++++++++++----- .../renderer_vulkan/vk_rasterizer.h | 2 +- 11 files changed, 149 insertions(+), 35 deletions(-) diff --git a/src/shader_recompiler/backend/spirv/emit_spirv_special.cpp b/src/shader_recompiler/backend/spirv/emit_spirv_special.cpp index 4a22ba09f..a0a3ed8ff 100644 --- a/src/shader_recompiler/backend/spirv/emit_spirv_special.cpp +++ b/src/shader_recompiler/backend/spirv/emit_spirv_special.cpp @@ -24,10 +24,48 @@ void ConvertDepthMode(EmitContext& ctx) { ctx.OpStore(ctx.output_position, vector); } +void ConvertPositionToClipSpace(EmitContext& ctx) { + const Id type{ctx.F32[1]}; + Id position{ctx.OpLoad(ctx.F32[4], ctx.output_position)}; + const Id x{ctx.OpCompositeExtract(type, position, 0u)}; + const Id y{ctx.OpCompositeExtract(type, position, 1u)}; + const Id z{ctx.OpCompositeExtract(type, position, 2u)}; + const Id w{ctx.OpCompositeExtract(type, position, 3u)}; + const Id xoffset_ptr{ctx.OpAccessChain(ctx.TypePointer(spv::StorageClass::PushConstant, type), + ctx.push_data_block, + ctx.ConstU32(PushData::XOffsetIndex))}; + const Id xoffset{ctx.OpLoad(type, xoffset_ptr)}; + const Id yoffset_ptr{ctx.OpAccessChain(ctx.TypePointer(spv::StorageClass::PushConstant, type), + ctx.push_data_block, + ctx.ConstU32(PushData::YOffsetIndex))}; + const Id yoffset{ctx.OpLoad(type, yoffset_ptr)}; + const Id xscale_ptr{ctx.OpAccessChain(ctx.TypePointer(spv::StorageClass::PushConstant, type), + ctx.push_data_block, + ctx.ConstU32(PushData::XScaleIndex))}; + const Id xscale{ctx.OpLoad(type, xscale_ptr)}; + const Id yscale_ptr{ctx.OpAccessChain(ctx.TypePointer(spv::StorageClass::PushConstant, type), + ctx.push_data_block, + ctx.ConstU32(PushData::YScaleIndex))}; + const Id yscale{ctx.OpLoad(type, yscale_ptr)}; + const Id vport_w = + ctx.Constant(type, float(std::min(ctx.profile.max_viewport_width / 2, 8_KB))); + const Id wnd_x = ctx.OpFAdd(type, ctx.OpFMul(type, x, xscale), xoffset); + const Id ndc_x = ctx.OpFSub(type, ctx.OpFDiv(type, wnd_x, vport_w), ctx.Constant(type, 1.f)); + const Id vport_h = + ctx.Constant(type, float(std::min(ctx.profile.max_viewport_height / 2, 8_KB))); + const Id wnd_y = ctx.OpFAdd(type, ctx.OpFMul(type, y, yscale), yoffset); + const Id ndc_y = ctx.OpFSub(type, ctx.OpFDiv(type, wnd_y, vport_h), ctx.Constant(type, 1.f)); + const Id vector{ctx.OpCompositeConstruct(ctx.F32[4], std::array({ndc_x, ndc_y, z, w}))}; + ctx.OpStore(ctx.output_position, vector); +} + void EmitEpilogue(EmitContext& ctx) { if (ctx.stage == Stage::Vertex && ctx.runtime_info.vs_info.emulate_depth_negative_one_to_one) { ConvertDepthMode(ctx); } + if (ctx.stage == Stage::Vertex && ctx.runtime_info.vs_info.clip_disable) { + ConvertPositionToClipSpace(ctx); + } } void EmitDiscard(EmitContext& ctx) { diff --git a/src/shader_recompiler/backend/spirv/spirv_emit_context.cpp b/src/shader_recompiler/backend/spirv/spirv_emit_context.cpp index 295bef75d..b0bf5aa0a 100644 --- a/src/shader_recompiler/backend/spirv/spirv_emit_context.cpp +++ b/src/shader_recompiler/backend/spirv/spirv_emit_context.cpp @@ -568,25 +568,34 @@ void EmitContext::DefineOutputs() { void EmitContext::DefinePushDataBlock() { // Create push constants block for instance steps rates - const Id struct_type{Name( - TypeStruct(U32[1], U32[1], U32[4], U32[4], U32[4], U32[4], U32[4], U32[4]), "AuxData")}; + const Id struct_type{Name(TypeStruct(U32[1], U32[1], U32[4], U32[4], U32[4], U32[4], U32[4], + U32[4], F32[1], F32[1], F32[1], F32[1]), + "AuxData")}; Decorate(struct_type, spv::Decoration::Block); MemberName(struct_type, 0, "sr0"); MemberName(struct_type, 1, "sr1"); - MemberName(struct_type, 2, "buf_offsets0"); - MemberName(struct_type, 3, "buf_offsets1"); - MemberName(struct_type, 4, "ud_regs0"); - MemberName(struct_type, 5, "ud_regs1"); - MemberName(struct_type, 6, "ud_regs2"); - MemberName(struct_type, 7, "ud_regs3"); + MemberName(struct_type, Shader::PushData::BufOffsetIndex + 0, "buf_offsets0"); + MemberName(struct_type, Shader::PushData::BufOffsetIndex + 1, "buf_offsets1"); + MemberName(struct_type, Shader::PushData::UdRegsIndex + 0, "ud_regs0"); + MemberName(struct_type, Shader::PushData::UdRegsIndex + 1, "ud_regs1"); + MemberName(struct_type, Shader::PushData::UdRegsIndex + 2, "ud_regs2"); + MemberName(struct_type, Shader::PushData::UdRegsIndex + 3, "ud_regs3"); + MemberName(struct_type, Shader::PushData::XOffsetIndex, "xoffset"); + MemberName(struct_type, Shader::PushData::YOffsetIndex, "yoffset"); + MemberName(struct_type, Shader::PushData::XScaleIndex, "xscale"); + MemberName(struct_type, Shader::PushData::YScaleIndex, "yscale"); MemberDecorate(struct_type, 0, spv::Decoration::Offset, 0U); MemberDecorate(struct_type, 1, spv::Decoration::Offset, 4U); - MemberDecorate(struct_type, 2, spv::Decoration::Offset, 8U); - MemberDecorate(struct_type, 3, spv::Decoration::Offset, 24U); - MemberDecorate(struct_type, 4, spv::Decoration::Offset, 40U); - MemberDecorate(struct_type, 5, spv::Decoration::Offset, 56U); - MemberDecorate(struct_type, 6, spv::Decoration::Offset, 72U); - MemberDecorate(struct_type, 7, spv::Decoration::Offset, 88U); + MemberDecorate(struct_type, Shader::PushData::BufOffsetIndex + 0, spv::Decoration::Offset, 8U); + MemberDecorate(struct_type, Shader::PushData::BufOffsetIndex + 1, spv::Decoration::Offset, 24U); + MemberDecorate(struct_type, Shader::PushData::UdRegsIndex + 0, spv::Decoration::Offset, 40U); + MemberDecorate(struct_type, Shader::PushData::UdRegsIndex + 1, spv::Decoration::Offset, 56U); + MemberDecorate(struct_type, Shader::PushData::UdRegsIndex + 2, spv::Decoration::Offset, 72U); + MemberDecorate(struct_type, Shader::PushData::UdRegsIndex + 3, spv::Decoration::Offset, 88U); + MemberDecorate(struct_type, Shader::PushData::XOffsetIndex, spv::Decoration::Offset, 104U); + MemberDecorate(struct_type, Shader::PushData::YOffsetIndex, spv::Decoration::Offset, 108U); + MemberDecorate(struct_type, Shader::PushData::XScaleIndex, spv::Decoration::Offset, 112U); + MemberDecorate(struct_type, Shader::PushData::YScaleIndex, spv::Decoration::Offset, 116U); push_data_block = DefineVar(struct_type, spv::StorageClass::PushConstant); Name(push_data_block, "push_data"); interfaces.push_back(push_data_block); diff --git a/src/shader_recompiler/info.h b/src/shader_recompiler/info.h index aeff346fa..2cde30629 100644 --- a/src/shader_recompiler/info.h +++ b/src/shader_recompiler/info.h @@ -96,11 +96,19 @@ using FMaskResourceList = boost::container::small_vector; struct PushData { static constexpr u32 BufOffsetIndex = 2; static constexpr u32 UdRegsIndex = 4; + static constexpr u32 XOffsetIndex = 8; + static constexpr u32 YOffsetIndex = 9; + static constexpr u32 XScaleIndex = 10; + static constexpr u32 YScaleIndex = 11; u32 step0; u32 step1; std::array buf_offsets; std::array ud_regs; + float xoffset; + float yoffset; + float xscale; + float yscale; void AddOffset(u32 binding, u32 offset) { ASSERT(offset < 256 && binding < buf_offsets.size()); diff --git a/src/shader_recompiler/profile.h b/src/shader_recompiler/profile.h index f8878d442..f8b91a283 100644 --- a/src/shader_recompiler/profile.h +++ b/src/shader_recompiler/profile.h @@ -30,6 +30,8 @@ struct Profile { bool needs_manual_interpolation{}; bool needs_lds_barriers{}; u64 min_ssbo_alignment{}; + u32 max_viewport_width{}; + u32 max_viewport_height{}; }; } // namespace Shader diff --git a/src/shader_recompiler/runtime_info.h b/src/shader_recompiler/runtime_info.h index 8a5e0a1a6..2bf5e3f0a 100644 --- a/src/shader_recompiler/runtime_info.h +++ b/src/shader_recompiler/runtime_info.h @@ -84,6 +84,7 @@ struct VertexRuntimeInfo { u32 num_outputs; std::array outputs; bool emulate_depth_negative_one_to_one{}; + bool clip_disable{}; // Domain AmdGpu::TessellationType tess_type; AmdGpu::TessellationTopology tess_topology; @@ -92,7 +93,8 @@ struct VertexRuntimeInfo { bool operator==(const VertexRuntimeInfo& other) const noexcept { return emulate_depth_negative_one_to_one == other.emulate_depth_negative_one_to_one && - tess_type == other.tess_type && tess_topology == other.tess_topology && + clip_disable == other.clip_disable && tess_type == other.tess_type && + tess_topology == other.tess_topology && tess_partitioning == other.tess_partitioning && hs_output_cp_stride == other.hs_output_cp_stride; } diff --git a/src/video_core/renderer_vulkan/vk_graphics_pipeline.h b/src/video_core/renderer_vulkan/vk_graphics_pipeline.h index f696c1f72..9a20f94c1 100644 --- a/src/video_core/renderer_vulkan/vk_graphics_pipeline.h +++ b/src/video_core/renderer_vulkan/vk_graphics_pipeline.h @@ -42,13 +42,14 @@ struct GraphicsPipelineKey { vk::Format stencil_format; struct { + bool clip_disable : 1; bool depth_test_enable : 1; bool depth_write_enable : 1; bool depth_bounds_test_enable : 1; bool depth_bias_enable : 1; bool stencil_test_enable : 1; // Must be named to be zero-initialized. - u8 _unused : 3; + u8 _unused : 2; }; vk::CompareOp depth_compare_op; @@ -94,6 +95,10 @@ public: return key.mrt_mask; } + auto IsClipDisabled() const { + return key.clip_disable; + } + [[nodiscard]] bool IsPrimitiveListTopology() const { return key.prim_type == AmdGpu::PrimitiveType::PointList || key.prim_type == AmdGpu::PrimitiveType::LineList || diff --git a/src/video_core/renderer_vulkan/vk_instance.cpp b/src/video_core/renderer_vulkan/vk_instance.cpp index 1600600b9..d9577a612 100644 --- a/src/video_core/renderer_vulkan/vk_instance.cpp +++ b/src/video_core/renderer_vulkan/vk_instance.cpp @@ -208,6 +208,7 @@ std::string Instance::GetDriverVersionName() { bool Instance::CreateDevice() { const vk::StructureChain feature_chain = physical_device.getFeatures2< vk::PhysicalDeviceFeatures2, vk::PhysicalDeviceExtendedDynamicStateFeaturesEXT, + vk::PhysicalDevicePrimitiveTopologyListRestartFeaturesEXT, vk::PhysicalDeviceExtendedDynamicState2FeaturesEXT, vk::PhysicalDeviceExtendedDynamicState3FeaturesEXT, vk::PhysicalDeviceCustomBorderColorFeaturesEXT, @@ -317,6 +318,9 @@ bool Instance::CreateDevice() { .pQueuePriorities = queue_priorities.data(), }; + const auto topology_list_restart_features = + feature_chain.get(); + const auto vk12_features = feature_chain.get(); vk::StructureChain device_chain = { vk::DeviceCreateInfo{ @@ -406,6 +410,8 @@ bool Instance::CreateDevice() { }, vk::PhysicalDevicePrimitiveTopologyListRestartFeaturesEXT{ .primitiveTopologyListRestart = true, + .primitiveTopologyPatchListRestart = + topology_list_restart_features.primitiveTopologyPatchListRestart, }, vk::PhysicalDeviceFragmentShaderBarycentricFeaturesKHR{ .fragmentShaderBarycentric = true, diff --git a/src/video_core/renderer_vulkan/vk_instance.h b/src/video_core/renderer_vulkan/vk_instance.h index 1b0c276dc..8c4752c3f 100644 --- a/src/video_core/renderer_vulkan/vk_instance.h +++ b/src/video_core/renderer_vulkan/vk_instance.h @@ -279,6 +279,14 @@ public: return min_imported_host_pointer_alignment; } + u32 GetMaxViewportWidth() const { + return properties.limits.maxViewportDimensions[0]; + } + + u32 GetMaxViewportHeight() const { + return properties.limits.maxViewportDimensions[1]; + } + /// Returns the sample count flags supported by framebuffers. vk::SampleCountFlags GetFramebufferSampleCounts() const { return properties.limits.framebufferColorSampleCounts & diff --git a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp index 86f6dcc7a..c6a56745d 100644 --- a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp +++ b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp @@ -125,6 +125,7 @@ const Shader::RuntimeInfo& PipelineCache::BuildRuntimeInfo(Stage stage, LogicalS info.vs_info.emulate_depth_negative_one_to_one = !instance.IsDepthClipControlSupported() && regs.clipper_control.clip_space == Liverpool::ClipSpace::MinusWToW; + info.vs_info.clip_disable = graphics_key.clip_disable; if (l_stage == LogicalStage::TessellationEval) { info.vs_info.tess_type = regs.tess_config.type; info.vs_info.tess_topology = regs.tess_config.topology; @@ -210,6 +211,8 @@ PipelineCache::PipelineCache(const Instance& instance_, Scheduler& scheduler_, instance.GetDriverID() == vk::DriverId::eNvidiaProprietary, .needs_lds_barriers = instance.GetDriverID() == vk::DriverId::eNvidiaProprietary || instance.GetDriverID() == vk::DriverId::eMoltenvk, + .max_viewport_width = instance.GetMaxViewportWidth(), + .max_viewport_height = instance.GetMaxViewportHeight(), }; auto [cache_result, cache] = instance.GetDevice().createPipelineCacheUnique({}); ASSERT_MSG(cache_result == vk::Result::eSuccess, "Failed to create pipeline cache: {}", @@ -262,6 +265,8 @@ bool PipelineCache::RefreshGraphicsKey() { auto& regs = liverpool->regs; auto& key = graphics_key; + key.clip_disable = + regs.clipper_control.clip_disable || regs.primitive_type == AmdGpu::PrimitiveType::RectList; key.depth_test_enable = regs.depth_control.depth_enable; key.depth_write_enable = regs.depth_control.depth_write_enable && !regs.depth_render_control.depth_clear_enable; diff --git a/src/video_core/renderer_vulkan/vk_rasterizer.cpp b/src/video_core/renderer_vulkan/vk_rasterizer.cpp index bac647125..07369c620 100644 --- a/src/video_core/renderer_vulkan/vk_rasterizer.cpp +++ b/src/video_core/renderer_vulkan/vk_rasterizer.cpp @@ -504,6 +504,17 @@ bool Rasterizer::BindResources(const Pipeline* pipeline) { } push_data.step0 = regs.vgt_instance_step_rate_0; push_data.step1 = regs.vgt_instance_step_rate_1; + + // TODO(roamic): add support for multiple viewports and geometry shaders when ViewportIndex + // is encountered and implemented in the recompiler. + if (stage->stage == Shader::Stage::Vertex) { + push_data.xoffset = + regs.viewport_control.xoffset_enable ? regs.viewports[0].xoffset : 0.f; + push_data.xscale = regs.viewport_control.xscale_enable ? regs.viewports[0].xscale : 1.f; + push_data.yoffset = + regs.viewport_control.yoffset_enable ? regs.viewports[0].yoffset : 0.f; + push_data.yscale = regs.viewport_control.yscale_enable ? regs.viewports[0].yscale : 1.f; + } stage->PushUd(binding, push_data); BindBuffers(*stage, binding, push_data, set_writes, buffer_barriers); @@ -1032,7 +1043,7 @@ void Rasterizer::UnmapMemory(VAddr addr, u64 size) { } void Rasterizer::UpdateDynamicState(const GraphicsPipeline& pipeline) { - UpdateViewportScissorState(); + UpdateViewportScissorState(pipeline); auto& regs = liverpool->regs; const auto cmdbuf = scheduler.CommandBuffer(); @@ -1112,7 +1123,7 @@ void Rasterizer::UpdateDynamicState(const GraphicsPipeline& pipeline) { } } -void Rasterizer::UpdateViewportScissorState() { +void Rasterizer::UpdateViewportScissorState(const GraphicsPipeline& pipeline) { const auto& regs = liverpool->regs; const auto combined_scissor_value_tl = [](s16 scr, s16 win, s16 gen, s16 win_offset) { @@ -1151,26 +1162,46 @@ void Rasterizer::UpdateViewportScissorState() { ? 1.0f : 0.0f; + if (regs.polygon_control.enable_window_offset) { + LOG_ERROR(Render_Vulkan, + "PA_SU_SC_MODE_CNTL.VTX_WINDOW_OFFSET_ENABLE support is not yet implemented."); + } + for (u32 i = 0; i < Liverpool::NumViewports; i++) { const auto& vp = regs.viewports[i]; const auto& vp_d = regs.viewport_depths[i]; if (vp.xscale == 0) { continue; } - const auto xoffset = vp_ctl.xoffset_enable ? vp.xoffset : 0.f; - const auto xscale = vp_ctl.xscale_enable ? vp.xscale : 1.f; - const auto yoffset = vp_ctl.yoffset_enable ? vp.yoffset : 0.f; - const auto yscale = vp_ctl.yscale_enable ? vp.yscale : 1.f; - const auto zoffset = vp_ctl.zoffset_enable ? vp.zoffset : 0.f; - const auto zscale = vp_ctl.zscale_enable ? vp.zscale : 1.f; - viewports.push_back({ - .x = xoffset - xscale, - .y = yoffset - yscale, - .width = xscale * 2.0f, - .height = yscale * 2.0f, - .minDepth = zoffset - zscale * reduce_z, - .maxDepth = zscale + zoffset, - }); + + if (pipeline.IsClipDisabled()) { + // In case if clipping is disabled we patch the shader to convert vertex position + // from screen space coordinates to NDC by defining a render space as full hardware + // window range [0..16383, 0..16383] and setting the viewport to its size. + viewports.push_back({ + .x = 0.f, + .y = 0.f, + .width = float(std::min(instance.GetMaxViewportWidth(), 16_KB)), + .height = float(std::min(instance.GetMaxViewportHeight(), 16_KB)), + .minDepth = 0.0, + .maxDepth = 1.0, + }); + } else { + const auto xoffset = vp_ctl.xoffset_enable ? vp.xoffset : 0.f; + const auto xscale = vp_ctl.xscale_enable ? vp.xscale : 1.f; + const auto yoffset = vp_ctl.yoffset_enable ? vp.yoffset : 0.f; + const auto yscale = vp_ctl.yscale_enable ? vp.yscale : 1.f; + const auto zoffset = vp_ctl.zoffset_enable ? vp.zoffset : 0.f; + const auto zscale = vp_ctl.zscale_enable ? vp.zscale : 1.f; + viewports.push_back({ + .x = xoffset - xscale, + .y = yoffset - yscale, + .width = xscale * 2.0f, + .height = yscale * 2.0f, + .minDepth = zoffset - zscale * reduce_z, + .maxDepth = zscale + zoffset, + }); + } auto vp_scsr = scsr; if (regs.mode_control.vport_scissor_enable) { @@ -1192,8 +1223,8 @@ void Rasterizer::UpdateViewportScissorState() { if (viewports.empty()) { // Vulkan requires providing at least one viewport. constexpr vk::Viewport empty_viewport = { - .x = 0.0f, - .y = 0.0f, + .x = -1.0f, + .y = -1.0f, .width = 1.0f, .height = 1.0f, .minDepth = 0.0f, diff --git a/src/video_core/renderer_vulkan/vk_rasterizer.h b/src/video_core/renderer_vulkan/vk_rasterizer.h index abf58e522..ed6cc7e71 100644 --- a/src/video_core/renderer_vulkan/vk_rasterizer.h +++ b/src/video_core/renderer_vulkan/vk_rasterizer.h @@ -76,7 +76,7 @@ private: void EliminateFastClear(); void UpdateDynamicState(const GraphicsPipeline& pipeline); - void UpdateViewportScissorState(); + void UpdateViewportScissorState(const GraphicsPipeline& pipeline); bool FilterDraw(); From 90b04e8cc0227a35aa5b01d6c361b4eaaefaee44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Quang=20Ng=C3=B4?= Date: Sat, 18 Jan 2025 13:59:38 +0700 Subject: [PATCH 06/99] input: Don't use old input state in GameController::ReadState() (#2170) --- src/core/libraries/pad/pad.cpp | 33 +++-- src/input/controller.cpp | 146 ++++++++++---------- src/input/controller.h | 36 +++-- src/sdl_window.cpp | 234 +++++++++++++++++++++++++++------ src/sdl_window.h | 22 +++- 5 files changed, 340 insertions(+), 131 deletions(-) diff --git a/src/core/libraries/pad/pad.cpp b/src/core/libraries/pad/pad.cpp index 7eb628a90..9a44f91f0 100644 --- a/src/core/libraries/pad/pad.cpp +++ b/src/core/libraries/pad/pad.cpp @@ -11,6 +11,8 @@ namespace Libraries::Pad { +using Input::GameController; + int PS4_SYSV_ABI scePadClose(s32 handle) { LOG_ERROR(Lib_Pad, "(STUBBED) called"); return ORBIS_OK; @@ -290,7 +292,8 @@ int PS4_SYSV_ABI scePadRead(s32 handle, OrbisPadData* pData, s32 num) { int connected_count = 0; bool connected = false; Input::State states[64]; - auto* controller = Common::Singleton::Instance(); + auto* controller = Common::Singleton::Instance(); + const auto* engine = controller->GetEngine(); int ret_num = controller->ReadStates(states, num, &connected, &connected_count); if (!connected) { @@ -311,9 +314,14 @@ int PS4_SYSV_ABI scePadRead(s32 handle, OrbisPadData* pData, s32 num) { pData[i].angularVelocity.x = states[i].angularVelocity.x; pData[i].angularVelocity.y = states[i].angularVelocity.y; pData[i].angularVelocity.z = states[i].angularVelocity.z; - Input::GameController::CalculateOrientation(pData[i].acceleration, pData[i].angularVelocity, - 1.0f / controller->accel_poll_rate, - pData[i].orientation); + if (engine) { + const auto accel_poll_rate = engine->GetAccelPollRate(); + if (accel_poll_rate != 0.0f) { + GameController::CalculateOrientation(pData[i].acceleration, + pData[i].angularVelocity, + 1.0f / accel_poll_rate, pData[i].orientation); + } + } pData[i].touchData.touchNum = (states[i].touchpad[0].state ? 1 : 0) + (states[i].touchpad[1].state ? 1 : 0); pData[i].touchData.touch[0].x = states[i].touchpad[0].x; @@ -356,7 +364,8 @@ int PS4_SYSV_ABI scePadReadState(s32 handle, OrbisPadData* pData) { if (handle == ORBIS_PAD_ERROR_DEVICE_NO_HANDLE) { return ORBIS_PAD_ERROR_INVALID_HANDLE; } - auto* controller = Common::Singleton::Instance(); + auto* controller = Common::Singleton::Instance(); + const auto* engine = controller->GetEngine(); int connectedCount = 0; bool isConnected = false; Input::State state; @@ -374,9 +383,13 @@ int PS4_SYSV_ABI scePadReadState(s32 handle, OrbisPadData* pData) { pData->angularVelocity.x = state.angularVelocity.x; pData->angularVelocity.y = state.angularVelocity.y; pData->angularVelocity.z = state.angularVelocity.z; - Input::GameController::CalculateOrientation(pData->acceleration, pData->angularVelocity, - 1.0f / controller->accel_poll_rate, - pData->orientation); + if (engine) { + const auto accel_poll_rate = engine->GetAccelPollRate(); + if (accel_poll_rate != 0.0f) { + GameController::CalculateOrientation(pData->acceleration, pData->angularVelocity, + 1.0f / accel_poll_rate, pData->orientation); + } + } pData->touchData.touchNum = (state.touchpad[0].state ? 1 : 0) + (state.touchpad[1].state ? 1 : 0); pData->touchData.touch[0].x = state.touchpad[0].x; @@ -468,7 +481,7 @@ int PS4_SYSV_ABI scePadSetLightBar(s32 handle, const OrbisPadLightBarParam* pPar return ORBIS_PAD_ERROR_INVALID_LIGHTBAR_SETTING; } - auto* controller = Common::Singleton::Instance(); + auto* controller = Common::Singleton::Instance(); controller->SetLightBarRGB(pParam->r, pParam->g, pParam->b); return ORBIS_OK; } @@ -536,7 +549,7 @@ int PS4_SYSV_ABI scePadSetVibration(s32 handle, const OrbisPadVibrationParam* pP if (pParam != nullptr) { LOG_DEBUG(Lib_Pad, "scePadSetVibration called handle = {} data = {} , {}", handle, pParam->smallMotor, pParam->largeMotor); - auto* controller = Common::Singleton::Instance(); + auto* controller = Common::Singleton::Instance(); controller->SetVibration(pParam->smallMotor, pParam->largeMotor); return ORBIS_OK; } diff --git a/src/input/controller.cpp b/src/input/controller.cpp index eb43e6adf..71f0b0c09 100644 --- a/src/input/controller.cpp +++ b/src/input/controller.cpp @@ -10,6 +10,55 @@ namespace Input { +using Libraries::Pad::OrbisPadButtonDataOffset; + +void State::OnButton(OrbisPadButtonDataOffset button, bool isPressed) { + if (isPressed) { + buttonsState |= button; + } else { + buttonsState &= ~button; + } +} + +void State::OnAxis(Axis axis, int value) { + const auto toggle = [&](const auto button) { + if (value > 0) { + buttonsState |= button; + } else { + buttonsState &= ~button; + } + }; + switch (axis) { + case Axis::TriggerLeft: + toggle(OrbisPadButtonDataOffset::L2); + break; + case Axis::TriggerRight: + toggle(OrbisPadButtonDataOffset::R2); + break; + default: + break; + } + axes[static_cast(axis)] = value; +} + +void State::OnTouchpad(int touchIndex, bool isDown, float x, float y) { + touchpad[touchIndex].state = isDown; + touchpad[touchIndex].x = static_cast(x * 1920); + touchpad[touchIndex].y = static_cast(y * 941); +} + +void State::OnGyro(const float gyro[3]) { + angularVelocity.x = gyro[0]; + angularVelocity.y = gyro[1]; + angularVelocity.z = gyro[2]; +} + +void State::OnAccel(const float accel[3]) { + acceleration.x = accel[0]; + acceleration.y = accel[1]; + acceleration.z = accel[2]; +} + GameController::GameController() { m_states_num = 0; m_last_state = State(); @@ -20,7 +69,7 @@ void GameController::ReadState(State* state, bool* isConnected, int* connectedCo *isConnected = m_connected; *connectedCount = m_connected_count; - *state = GetLastState(); + *state = m_engine && m_connected ? m_engine->ReadState() : GetLastState(); } int GameController::ReadStates(State* states, int states_num, bool* isConnected, @@ -75,45 +124,22 @@ void GameController::AddState(const State& state) { m_states_num++; } -void GameController::CheckButton(int id, Libraries::Pad::OrbisPadButtonDataOffset button, - bool is_pressed) { +void GameController::CheckButton(int id, OrbisPadButtonDataOffset button, bool is_pressed) { std::scoped_lock lock{m_mutex}; auto state = GetLastState(); + state.time = Libraries::Kernel::sceKernelGetProcessTime(); - if (is_pressed) { - state.buttonsState |= button; - } else { - state.buttonsState &= ~button; - } + state.OnButton(button, is_pressed); AddState(state); } void GameController::Axis(int id, Input::Axis axis, int value) { - using Libraries::Pad::OrbisPadButtonDataOffset; - std::scoped_lock lock{m_mutex}; auto state = GetLastState(); state.time = Libraries::Kernel::sceKernelGetProcessTime(); - int axis_id = static_cast(axis); - state.axes[axis_id] = value; - - if (axis == Input::Axis::TriggerLeft) { - if (value > 0) { - state.buttonsState |= OrbisPadButtonDataOffset::L2; - } else { - state.buttonsState &= ~OrbisPadButtonDataOffset::L2; - } - } - - if (axis == Input::Axis::TriggerRight) { - if (value > 0) { - state.buttonsState |= OrbisPadButtonDataOffset::R2; - } else { - state.buttonsState &= ~OrbisPadButtonDataOffset::R2; - } - } + state.OnAxis(axis, value); AddState(state); } @@ -124,9 +150,7 @@ void GameController::Gyro(int id, const float gyro[3]) { state.time = Libraries::Kernel::sceKernelGetProcessTime(); // Update the angular velocity (gyro data) - state.angularVelocity.x = gyro[0]; // X-axis - state.angularVelocity.y = gyro[1]; // Y-axis - state.angularVelocity.z = gyro[2]; // Z-axis + state.OnGyro(gyro); AddState(state); } @@ -136,9 +160,7 @@ void GameController::Acceleration(int id, const float acceleration[3]) { state.time = Libraries::Kernel::sceKernelGetProcessTime(); // Update the acceleration values - state.acceleration.x = acceleration[0]; // X-axis - state.acceleration.y = acceleration[1]; // Y-axis - state.acceleration.z = acceleration[2]; // Z-axis + state.OnAccel(acceleration); AddState(state); } @@ -211,62 +233,48 @@ void GameController::CalculateOrientation(Libraries::Pad::OrbisFVector3& acceler } void GameController::SetLightBarRGB(u8 r, u8 g, u8 b) { - if (m_sdl_gamepad != nullptr) { - SDL_SetGamepadLED(m_sdl_gamepad, r, g, b); + if (!m_engine) { + return; } + std::scoped_lock _{m_mutex}; + m_engine->SetLightBarRGB(r, g, b); } -bool GameController::SetVibration(u8 smallMotor, u8 largeMotor) { - if (m_sdl_gamepad != nullptr) { - return SDL_RumbleGamepad(m_sdl_gamepad, (smallMotor / 255.0f) * 0xFFFF, - (largeMotor / 255.0f) * 0xFFFF, -1); +void GameController::SetVibration(u8 smallMotor, u8 largeMotor) { + if (!m_engine) { + return; } - return true; + std::scoped_lock _{m_mutex}; + m_engine->SetVibration(smallMotor, largeMotor); } void GameController::SetTouchpadState(int touchIndex, bool touchDown, float x, float y) { if (touchIndex < 2) { std::scoped_lock lock{m_mutex}; auto state = GetLastState(); - state.time = Libraries::Kernel::sceKernelGetProcessTime(); - state.touchpad[touchIndex].state = touchDown; - state.touchpad[touchIndex].x = static_cast(x * 1920); - state.touchpad[touchIndex].y = static_cast(y * 941); + state.time = Libraries::Kernel::sceKernelGetProcessTime(); + state.OnTouchpad(touchIndex, touchDown, x, y); AddState(state); } } -void GameController::TryOpenSDLController() { - if (m_sdl_gamepad == nullptr || !SDL_GamepadConnected(m_sdl_gamepad)) { - int gamepad_count; - SDL_JoystickID* gamepads = SDL_GetGamepads(&gamepad_count); - m_sdl_gamepad = gamepad_count > 0 ? SDL_OpenGamepad(gamepads[0]) : nullptr; - if (Config::getIsMotionControlsEnabled()) { - if (SDL_SetGamepadSensorEnabled(m_sdl_gamepad, SDL_SENSOR_GYRO, true)) { - gyro_poll_rate = SDL_GetGamepadSensorDataRate(m_sdl_gamepad, SDL_SENSOR_GYRO); - LOG_INFO(Input, "Gyro initialized, poll rate: {}", gyro_poll_rate); - } else { - LOG_ERROR(Input, "Failed to initialize gyro controls for gamepad"); - } - if (SDL_SetGamepadSensorEnabled(m_sdl_gamepad, SDL_SENSOR_ACCEL, true)) { - accel_poll_rate = SDL_GetGamepadSensorDataRate(m_sdl_gamepad, SDL_SENSOR_ACCEL); - LOG_INFO(Input, "Accel initialized, poll rate: {}", accel_poll_rate); - } else { - LOG_ERROR(Input, "Failed to initialize accel controls for gamepad"); - } - } - - SDL_free(gamepads); - - SetLightBarRGB(0, 0, 255); +void GameController::SetEngine(std::unique_ptr engine) { + std::scoped_lock _{m_mutex}; + m_engine = std::move(engine); + if (m_engine) { + m_engine->Init(); } } +Engine* GameController::GetEngine() { + return m_engine.get(); +} + u32 GameController::Poll() { - std::scoped_lock lock{m_mutex}; if (m_connected) { + std::scoped_lock lock{m_mutex}; auto time = Libraries::Kernel::sceKernelGetProcessTime(); if (m_states_num == 0) { auto diff = (time - m_last_state.time) / 1000; diff --git a/src/input/controller.h b/src/input/controller.h index c6fc02c24..a45e71d77 100644 --- a/src/input/controller.h +++ b/src/input/controller.h @@ -3,12 +3,12 @@ #pragma once +#include +#include #include #include "common/types.h" #include "core/libraries/pad/pad.h" -struct SDL_Gamepad; - namespace Input { enum class Axis { @@ -28,7 +28,14 @@ struct TouchpadEntry { u16 y{}; }; -struct State { +class State { +public: + void OnButton(Libraries::Pad::OrbisPadButtonDataOffset, bool); + void OnAxis(Axis, int); + void OnTouchpad(int touchIndex, bool isDown, float x, float y); + void OnGyro(const float[3]); + void OnAccel(const float[3]); + Libraries::Pad::OrbisPadButtonDataOffset buttonsState{}; u64 time = 0; int axes[static_cast(Axis::AxisMax)] = {128, 128, 128, 128, 0, 0}; @@ -38,9 +45,19 @@ struct State { Libraries::Pad::OrbisFQuaternion orientation = {0.0f, 0.0f, 0.0f, 1.0f}; }; +class Engine { +public: + virtual ~Engine() = default; + virtual void Init() = 0; + virtual void SetLightBarRGB(u8 r, u8 g, u8 b) = 0; + virtual void SetVibration(u8 smallMotor, u8 largeMotor) = 0; + virtual State ReadState() = 0; + virtual float GetAccelPollRate() const = 0; + virtual float GetGyroPollRate() const = 0; +}; + inline int GetAxis(int min, int max, int value) { - int v = (255 * (value - min)) / (max - min); - return (v < 0 ? 0 : (v > 255 ? 255 : v)); + return std::clamp((255 * (value - min)) / (max - min), 0, 255); } constexpr u32 MAX_STATES = 64; @@ -59,13 +76,12 @@ public: void Gyro(int id, const float gyro[3]); void Acceleration(int id, const float acceleration[3]); void SetLightBarRGB(u8 r, u8 g, u8 b); - bool SetVibration(u8 smallMotor, u8 largeMotor); + void SetVibration(u8 smallMotor, u8 largeMotor); void SetTouchpadState(int touchIndex, bool touchDown, float x, float y); - void TryOpenSDLController(); + void SetEngine(std::unique_ptr); + Engine* GetEngine(); u32 Poll(); - float gyro_poll_rate; - float accel_poll_rate; static void CalculateOrientation(Libraries::Pad::OrbisFVector3& acceleration, Libraries::Pad::OrbisFVector3& angularVelocity, float deltaTime, @@ -85,7 +101,7 @@ private: std::array m_states; std::array m_private; - SDL_Gamepad* m_sdl_gamepad = nullptr; + std::unique_ptr m_engine = nullptr; }; } // namespace Input diff --git a/src/sdl_window.cpp b/src/sdl_window.cpp index b0126def2..d1fe6bbab 100644 --- a/src/sdl_window.cpp +++ b/src/sdl_window.cpp @@ -10,6 +10,7 @@ #include "common/assert.h" #include "common/config.h" +#include "core/libraries/kernel/time.h" #include "core/libraries/pad/pad.h" #include "imgui/renderer/imgui_core.h" #include "input/controller.h" @@ -20,47 +21,200 @@ #include #endif +namespace Input { + +using Libraries::Pad::OrbisPadButtonDataOffset; + +static OrbisPadButtonDataOffset SDLGamepadToOrbisButton(u8 button) { + using OPBDO = OrbisPadButtonDataOffset; + + switch (button) { + case SDL_GAMEPAD_BUTTON_DPAD_DOWN: + return OPBDO::Down; + case SDL_GAMEPAD_BUTTON_DPAD_UP: + return OPBDO::Up; + case SDL_GAMEPAD_BUTTON_DPAD_LEFT: + return OPBDO::Left; + case SDL_GAMEPAD_BUTTON_DPAD_RIGHT: + return OPBDO::Right; + case SDL_GAMEPAD_BUTTON_SOUTH: + return OPBDO::Cross; + case SDL_GAMEPAD_BUTTON_NORTH: + return OPBDO::Triangle; + case SDL_GAMEPAD_BUTTON_WEST: + return OPBDO::Square; + case SDL_GAMEPAD_BUTTON_EAST: + return OPBDO::Circle; + case SDL_GAMEPAD_BUTTON_START: + return OPBDO::Options; + case SDL_GAMEPAD_BUTTON_TOUCHPAD: + return OPBDO::TouchPad; + case SDL_GAMEPAD_BUTTON_BACK: + return OPBDO::TouchPad; + case SDL_GAMEPAD_BUTTON_LEFT_SHOULDER: + return OPBDO::L1; + case SDL_GAMEPAD_BUTTON_RIGHT_SHOULDER: + return OPBDO::R1; + case SDL_GAMEPAD_BUTTON_LEFT_STICK: + return OPBDO::L3; + case SDL_GAMEPAD_BUTTON_RIGHT_STICK: + return OPBDO::R3; + default: + return OPBDO::None; + } +} + +static SDL_GamepadAxis InputAxisToSDL(Axis axis) { + switch (axis) { + case Axis::LeftX: + return SDL_GAMEPAD_AXIS_LEFTX; + case Axis::LeftY: + return SDL_GAMEPAD_AXIS_LEFTY; + case Axis::RightX: + return SDL_GAMEPAD_AXIS_RIGHTX; + case Axis::RightY: + return SDL_GAMEPAD_AXIS_RIGHTY; + case Axis::TriggerLeft: + return SDL_GAMEPAD_AXIS_LEFT_TRIGGER; + case Axis::TriggerRight: + return SDL_GAMEPAD_AXIS_RIGHT_TRIGGER; + default: + UNREACHABLE(); + } +} + +SDLInputEngine::~SDLInputEngine() { + if (m_gamepad) { + SDL_CloseGamepad(m_gamepad); + } +} + +void SDLInputEngine::Init() { + if (m_gamepad) { + SDL_CloseGamepad(m_gamepad); + m_gamepad = nullptr; + } + int gamepad_count; + SDL_JoystickID* gamepads = SDL_GetGamepads(&gamepad_count); + if (!gamepads) { + LOG_ERROR(Input, "Cannot get gamepad list: {}", SDL_GetError()); + return; + } + if (gamepad_count == 0) { + LOG_INFO(Input, "No gamepad found!"); + SDL_free(gamepads); + return; + } + LOG_INFO(Input, "Got {} gamepads. Opening the first one.", gamepad_count); + if (!(m_gamepad = SDL_OpenGamepad(gamepads[0]))) { + LOG_ERROR(Input, "Failed to open gamepad 0: {}", SDL_GetError()); + SDL_free(gamepads); + return; + } + if (Config::getIsMotionControlsEnabled()) { + if (SDL_SetGamepadSensorEnabled(m_gamepad, SDL_SENSOR_GYRO, true)) { + m_gyro_poll_rate = SDL_GetGamepadSensorDataRate(m_gamepad, SDL_SENSOR_GYRO); + LOG_INFO(Input, "Gyro initialized, poll rate: {}", m_gyro_poll_rate); + } else { + LOG_ERROR(Input, "Failed to initialize gyro controls for gamepad"); + } + if (SDL_SetGamepadSensorEnabled(m_gamepad, SDL_SENSOR_ACCEL, true)) { + m_accel_poll_rate = SDL_GetGamepadSensorDataRate(m_gamepad, SDL_SENSOR_ACCEL); + LOG_INFO(Input, "Accel initialized, poll rate: {}", m_accel_poll_rate); + } else { + LOG_ERROR(Input, "Failed to initialize accel controls for gamepad"); + }; + } + SDL_free(gamepads); + SetLightBarRGB(0, 0, 255); +} + +void SDLInputEngine::SetLightBarRGB(u8 r, u8 g, u8 b) { + if (m_gamepad) { + SDL_SetGamepadLED(m_gamepad, r, g, b); + } +} + +void SDLInputEngine::SetVibration(u8 smallMotor, u8 largeMotor) { + if (m_gamepad) { + const auto low_freq = (smallMotor / 255.0f) * 0xFFFF; + const auto high_freq = (largeMotor / 255.0f) * 0xFFFF; + SDL_RumbleGamepad(m_gamepad, low_freq, high_freq, -1); + } +} + +State SDLInputEngine::ReadState() { + State state{}; + state.time = Libraries::Kernel::sceKernelGetProcessTime(); + + // Buttons + for (u8 i = 0; i < SDL_GAMEPAD_BUTTON_COUNT; ++i) { + auto orbisButton = SDLGamepadToOrbisButton(i); + if (orbisButton == OrbisPadButtonDataOffset::None) { + continue; + } + state.OnButton(orbisButton, SDL_GetGamepadButton(m_gamepad, (SDL_GamepadButton)i)); + } + + // Axes + for (int i = 0; i < static_cast(Axis::AxisMax); ++i) { + const auto axis = static_cast(i); + const auto value = SDL_GetGamepadAxis(m_gamepad, InputAxisToSDL(axis)); + switch (axis) { + case Axis::TriggerLeft: + case Axis::TriggerRight: + state.OnAxis(axis, GetAxis(0, 0x8000, value)); + break; + default: + state.OnAxis(axis, GetAxis(-0x8000, 0x8000, value)); + break; + } + } + + // Touchpad + if (SDL_GetNumGamepadTouchpads(m_gamepad) > 0) { + for (int finger = 0; finger < 2; ++finger) { + bool down; + float x, y; + if (SDL_GetGamepadTouchpadFinger(m_gamepad, 0, finger, &down, &x, &y, NULL)) { + state.OnTouchpad(finger, down, x, y); + } + } + } + + // Gyro + if (SDL_GamepadHasSensor(m_gamepad, SDL_SENSOR_GYRO)) { + float gyro[3]; + if (SDL_GetGamepadSensorData(m_gamepad, SDL_SENSOR_GYRO, gyro, 3)) { + state.OnGyro(gyro); + } + } + + // Accel + if (SDL_GamepadHasSensor(m_gamepad, SDL_SENSOR_ACCEL)) { + float accel[3]; + if (SDL_GetGamepadSensorData(m_gamepad, SDL_SENSOR_ACCEL, accel, 3)) { + state.OnAccel(accel); + } + } + + return state; +} + +float SDLInputEngine::GetGyroPollRate() const { + return m_gyro_poll_rate; +} + +float SDLInputEngine::GetAccelPollRate() const { + return m_accel_poll_rate; +} + +} // namespace Input + namespace Frontend { using namespace Libraries::Pad; -static OrbisPadButtonDataOffset SDLGamepadToOrbisButton(u8 button) { - switch (button) { - case SDL_GAMEPAD_BUTTON_DPAD_DOWN: - return OrbisPadButtonDataOffset::Down; - case SDL_GAMEPAD_BUTTON_DPAD_UP: - return OrbisPadButtonDataOffset::Up; - case SDL_GAMEPAD_BUTTON_DPAD_LEFT: - return OrbisPadButtonDataOffset::Left; - case SDL_GAMEPAD_BUTTON_DPAD_RIGHT: - return OrbisPadButtonDataOffset::Right; - case SDL_GAMEPAD_BUTTON_SOUTH: - return OrbisPadButtonDataOffset::Cross; - case SDL_GAMEPAD_BUTTON_NORTH: - return OrbisPadButtonDataOffset::Triangle; - case SDL_GAMEPAD_BUTTON_WEST: - return OrbisPadButtonDataOffset::Square; - case SDL_GAMEPAD_BUTTON_EAST: - return OrbisPadButtonDataOffset::Circle; - case SDL_GAMEPAD_BUTTON_START: - return OrbisPadButtonDataOffset::Options; - case SDL_GAMEPAD_BUTTON_TOUCHPAD: - return OrbisPadButtonDataOffset::TouchPad; - case SDL_GAMEPAD_BUTTON_BACK: - return OrbisPadButtonDataOffset::TouchPad; - case SDL_GAMEPAD_BUTTON_LEFT_SHOULDER: - return OrbisPadButtonDataOffset::L1; - case SDL_GAMEPAD_BUTTON_RIGHT_SHOULDER: - return OrbisPadButtonDataOffset::R1; - case SDL_GAMEPAD_BUTTON_LEFT_STICK: - return OrbisPadButtonDataOffset::L3; - case SDL_GAMEPAD_BUTTON_RIGHT_STICK: - return OrbisPadButtonDataOffset::R3; - default: - return OrbisPadButtonDataOffset::None; - } -} - static Uint32 SDLCALL PollController(void* userdata, SDL_TimerID timer_id, Uint32 interval) { auto* controller = reinterpret_cast(userdata); return controller->Poll(); @@ -112,7 +266,7 @@ WindowSDL::WindowSDL(s32 width_, s32 height_, Input::GameController* controller_ SDL_SetWindowFullscreen(window, Config::getIsFullscreen()); SDL_InitSubSystem(SDL_INIT_GAMEPAD); - controller->TryOpenSDLController(); + controller->SetEngine(std::make_unique()); #if defined(SDL_PLATFORM_WIN32) window_info.type = WindowSystemType::Windows; @@ -422,7 +576,7 @@ void WindowSDL::OnGamepadEvent(const SDL_Event* event) { switch (event->type) { case SDL_EVENT_GAMEPAD_ADDED: case SDL_EVENT_GAMEPAD_REMOVED: - controller->TryOpenSDLController(); + controller->SetEngine(std::make_unique()); break; case SDL_EVENT_GAMEPAD_TOUCHPAD_DOWN: case SDL_EVENT_GAMEPAD_TOUCHPAD_UP: @@ -433,7 +587,7 @@ void WindowSDL::OnGamepadEvent(const SDL_Event* event) { break; case SDL_EVENT_GAMEPAD_BUTTON_DOWN: case SDL_EVENT_GAMEPAD_BUTTON_UP: { - button = SDLGamepadToOrbisButton(event->gbutton.button); + button = Input::SDLGamepadToOrbisButton(event->gbutton.button); if (button == OrbisPadButtonDataOffset::None) { break; } diff --git a/src/sdl_window.h b/src/sdl_window.h index 78d4bbc39..3ab3c3613 100644 --- a/src/sdl_window.h +++ b/src/sdl_window.h @@ -5,14 +5,32 @@ #include #include "common/types.h" +#include "input/controller.h" struct SDL_Window; struct SDL_Gamepad; union SDL_Event; namespace Input { -class GameController; -} + +class SDLInputEngine : public Engine { +public: + ~SDLInputEngine() override; + void Init() override; + void SetLightBarRGB(u8 r, u8 g, u8 b) override; + void SetVibration(u8 smallMotor, u8 largeMotor) override; + float GetGyroPollRate() const override; + float GetAccelPollRate() const override; + State ReadState() override; + +private: + SDL_Gamepad* m_gamepad = nullptr; + + float m_gyro_poll_rate{}; + float m_accel_poll_rate{}; +}; + +} // namespace Input namespace Frontend { From 40385e13e7ca96f19e004a0c21b718d9bf701570 Mon Sep 17 00:00:00 2001 From: tomboylover93 <95257311+tomboylover93@users.noreply.github.com> Date: Fri, 17 Jan 2025 23:08:20 -0800 Subject: [PATCH 07/99] qt: Improve user experience on Steam Deck and window managers (#2103) --- src/qt_gui/cheats_patches.cpp | 6 + src/qt_gui/settings_dialog.cpp | 16 - src/qt_gui/settings_dialog.ui | 629 ++++++++++++++++----------------- 3 files changed, 310 insertions(+), 341 deletions(-) diff --git a/src/qt_gui/cheats_patches.cpp b/src/qt_gui/cheats_patches.cpp index 2fea0b6ea..13157aa3a 100644 --- a/src/qt_gui/cheats_patches.cpp +++ b/src/qt_gui/cheats_patches.cpp @@ -188,8 +188,12 @@ void CheatsPatches::setupUI() { } }); + QPushButton* closeButton = new QPushButton(tr("Close")); + connect(closeButton, &QPushButton::clicked, [this]() { QWidget::close(); }); + controlLayout->addWidget(downloadButton); controlLayout->addWidget(deleteCheatButton); + controlLayout->addWidget(closeButton); cheatsLayout->addLayout(controlLayout); cheatsTab->setLayout(cheatsLayout); @@ -464,6 +468,8 @@ void CheatsPatches::onSaveButtonClicked() { } else { QMessageBox::information(this, tr("Success"), tr("Options saved successfully.")); } + + QWidget::close(); } QCheckBox* CheatsPatches::findCheckBoxByName(const QString& name) { diff --git a/src/qt_gui/settings_dialog.cpp b/src/qt_gui/settings_dialog.cpp index a4b584294..175c8c51d 100644 --- a/src/qt_gui/settings_dialog.cpp +++ b/src/qt_gui/settings_dialog.cpp @@ -522,22 +522,6 @@ bool SettingsDialog::eventFilter(QObject* obj, QEvent* event) { } else { ui->descriptionText->setText(defaultTextEdit); } - - // if the text exceeds the size of the box, it will increase the size - QRect currentGeometry = this->geometry(); - int newWidth = currentGeometry.width(); - - int documentHeight = ui->descriptionText->document()->size().height(); - int visibleHeight = ui->descriptionText->viewport()->height(); - if (documentHeight > visibleHeight) { - ui->descriptionText->setMaximumSize(16777215, 110); - this->setGeometry(currentGeometry.x(), currentGeometry.y(), newWidth, - currentGeometry.height() + 40); - } else { - ui->descriptionText->setMaximumSize(16777215, 70); - this->setGeometry(currentGeometry.x(), currentGeometry.y(), newWidth, - initialHeight); - } return true; } } diff --git a/src/qt_gui/settings_dialog.ui b/src/qt_gui/settings_dialog.ui index 8d68d1c90..c084d4849 100644 --- a/src/qt_gui/settings_dialog.ui +++ b/src/qt_gui/settings_dialog.ui @@ -12,7 +12,7 @@ 0 0 970 - 750 + 820 @@ -68,7 +68,7 @@ 0 0 946 - 586 + 611 @@ -77,43 +77,6 @@ 0 - - - - - - System - - - - - - Console Language - - - - - - - - - - - - Emulator Language - - - - - - - - - - - - - @@ -217,246 +180,6 @@ - - - - 6 - - - QLayout::SizeConstraint::SetDefaultConstraint - - - 0 - - - 0 - - - 0 - - - 0 - - - - - - 0 - 0 - - - - - 0 - 0 - - - - - 16777215 - 16777215 - - - - Update - - - - 10 - - - 1 - - - 11 - - - 11 - - - - - - 0 - 0 - - - - - 0 - 0 - - - - - 16777215 - 16777215 - - - - Update Channel - - - - 7 - - - 11 - - - 11 - - - 11 - - - 11 - - - - - - 0 - 0 - - - - - Release - - - - - Nightly - - - - - - - - - - - - 0 - 0 - - - - - 0 - 0 - - - - - 16777215 - 16777215 - - - - Check for Updates - - - - - - - - 0 - 0 - - - - - 11 - false - - - - Check for Updates at Startup - - - - - - - - - - - - - - - 0 - 0 - - - - - 0 - 0 - - - - Game Compatibility - - - - 10 - - - 1 - - - 11 - - - - - Display Compatibility Data - - - - - - - Update Compatibility Database On Startup - - - - - - - - 0 - 0 - - - - - 0 - 0 - - - - - 16777215 - 16777215 - - - - Update Compatibility Database - - - - - - - - @@ -627,6 +350,283 @@ + + + + + + System + + + + + + Console Language + + + + + + + + + + + + Emulator Language + + + + + + + + + + + + + + + + + 6 + + + QLayout::SizeConstraint::SetDefaultConstraint + + + 0 + + + 0 + + + 0 + + + 0 + + + + + + 0 + 0 + + + + + 0 + 0 + + + + + 16777215 + 16777215 + + + + Update + + + + 10 + + + 1 + + + 11 + + + 190 + + + + + + 0 + 0 + + + + + 0 + 0 + + + + + 16777215 + 16777215 + + + + Update Channel + + + + 7 + + + 11 + + + 11 + + + 11 + + + 11 + + + + + + 0 + 0 + + + + + Release + + + + + Nightly + + + + + + + + + + + + 0 + 0 + + + + + 0 + 0 + + + + + 16777215 + 16777215 + + + + Check for Updates + + + + + + + + 0 + 0 + + + + + 11 + false + + + + Check for Updates at Startup + + + + + + + + + + + + + + + 0 + 0 + + + + + 0 + 0 + + + + Game Compatibility + + + + 10 + + + 1 + + + 11 + + + + + Display Compatibility Data + + + + + + + Update Compatibility Database On Startup + + + + + + + + 0 + 0 + + + + + 0 + 0 + + + + + 16777215 + 16777215 + + + + Update Compatibility Database + + + + + + + + @@ -645,12 +645,12 @@ 0 0 946 - 586 + 605 - + @@ -664,17 +664,14 @@ Cursor - - - 0 - + 11 11 - + true @@ -701,7 +698,7 @@ - + true @@ -836,7 +833,7 @@ true - + 0 0 @@ -872,6 +869,12 @@ true + + + 0 + 0 + + 0 @@ -885,23 +888,6 @@ - - - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - @@ -943,7 +929,7 @@ 0 0 946 - 586 + 605 @@ -1124,11 +1110,14 @@ + + true + Advanced - Qt::AlignmentFlag::AlignLeading|Qt::AlignmentFlag::AlignLeft|Qt::AlignmentFlag::AlignVCenter + Qt::AlignmentFlag::AlignLeading|Qt::AlignmentFlag::AlignLeft|Qt::AlignmentFlag::AlignTop @@ -1194,7 +1183,7 @@ 0 0 946 - 586 + 605 @@ -1233,22 +1222,6 @@ - - - - Qt::Orientation::Horizontal - - - QSizePolicy::Policy::Preferred - - - - 40 - 20 - - - - @@ -1445,10 +1418,16 @@ + + + 0 + 0 + + 16777215 - 70 + 120 From 9a956f5ed00584cbdf70240826c01445ee083f1a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Quang=20Ng=C3=B4?= Date: Sat, 18 Jan 2025 14:08:45 +0700 Subject: [PATCH 08/99] renderer_vulkan: Clear blank frame (#2095) * renderer_vulkan: Clear blank frame Fix display of garbage images on startup on some drivers. * Remove duplicated attachment declarations * Remove duplicated rendering_info declarations --- .../renderer_vulkan/vk_presenter.cpp | 38 ++++++++++--------- 1 file changed, 21 insertions(+), 17 deletions(-) diff --git a/src/video_core/renderer_vulkan/vk_presenter.cpp b/src/video_core/renderer_vulkan/vk_presenter.cpp index 0f45574bc..fcdb84676 100644 --- a/src/video_core/renderer_vulkan/vk_presenter.cpp +++ b/src/video_core/renderer_vulkan/vk_presenter.cpp @@ -602,6 +602,23 @@ Frame* Presenter::PrepareFrameInternal(VideoCore::ImageId image_id, bool is_eop) .pImageMemoryBarriers = &pre_barrier, }); + const std::array attachments = {vk::RenderingAttachmentInfo{ + .imageView = frame->image_view, + .imageLayout = vk::ImageLayout::eColorAttachmentOptimal, + .loadOp = vk::AttachmentLoadOp::eClear, + .storeOp = vk::AttachmentStoreOp::eStore, + }}; + const vk::RenderingInfo rendering_info{ + .renderArea = + vk::Rect2D{ + .offset = {0, 0}, + .extent = {frame->width, frame->height}, + }, + .layerCount = 1, + .colorAttachmentCount = attachments.size(), + .pColorAttachments = attachments.data(), + }; + if (image_id != VideoCore::NULL_IMAGE_ID) { auto& image = texture_cache.GetImage(image_id); image.Transit(vk::ImageLayout::eShaderReadOnlyOptimal, vk::AccessFlagBits2::eShaderRead, {}, @@ -662,26 +679,13 @@ Frame* Presenter::PrepareFrameInternal(VideoCore::ImageId image_id, bool is_eop) cmdbuf.pushConstants(*pp_pipeline_layout, vk::ShaderStageFlagBits::eFragment, 0, sizeof(PostProcessSettings), &pp_settings); - const std::array attachments = {vk::RenderingAttachmentInfo{ - .imageView = frame->image_view, - .imageLayout = vk::ImageLayout::eColorAttachmentOptimal, - .loadOp = vk::AttachmentLoadOp::eClear, - .storeOp = vk::AttachmentStoreOp::eStore, - }}; - - vk::RenderingInfo rendering_info{ - .renderArea = - vk::Rect2D{ - .offset = {0, 0}, - .extent = {frame->width, frame->height}, - }, - .layerCount = 1, - .colorAttachmentCount = attachments.size(), - .pColorAttachments = attachments.data(), - }; cmdbuf.beginRendering(rendering_info); cmdbuf.draw(3, 1, 0, 0); cmdbuf.endRendering(); + } else { + // Fix display of garbage images on startup on some drivers + cmdbuf.beginRendering(rendering_info); + cmdbuf.endRendering(); } const auto post_barrier = From 81ad575b2294224194a365d087b2a6240a0b9161 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Quang=20Ng=C3=B4?= Date: Sat, 18 Jan 2025 14:47:38 +0700 Subject: [PATCH 09/99] video_core: Use adaptive mutex on Linux (#2105) Fix performance regression with #1973 on SteamDeck --- src/common/adaptive_mutex.h | 27 ++++++++++++++++++++++ src/video_core/buffer_cache/word_manager.h | 7 ++++++ src/video_core/page_manager.h | 7 ++++++ 3 files changed, 41 insertions(+) create mode 100644 src/common/adaptive_mutex.h diff --git a/src/common/adaptive_mutex.h b/src/common/adaptive_mutex.h new file mode 100644 index 000000000..f174f5996 --- /dev/null +++ b/src/common/adaptive_mutex.h @@ -0,0 +1,27 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#ifdef __linux__ +#include +#endif + +namespace Common { + +#ifdef PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP +class AdaptiveMutex { +public: + void lock() { + pthread_mutex_lock(&mutex); + } + void unlock() { + pthread_mutex_unlock(&mutex); + } + +private: + pthread_mutex_t mutex = PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP; +}; +#endif // PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP + +} // namespace Common diff --git a/src/video_core/buffer_cache/word_manager.h b/src/video_core/buffer_cache/word_manager.h index 7ad33d7a6..5ad724f96 100644 --- a/src/video_core/buffer_cache/word_manager.h +++ b/src/video_core/buffer_cache/word_manager.h @@ -8,6 +8,9 @@ #include #include +#ifdef __linux__ +#include "common/adaptive_mutex.h" +#endif #include "common/spin_lock.h" #include "common/types.h" #include "video_core/page_manager.h" @@ -272,7 +275,11 @@ private: } } +#ifdef PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP + Common::AdaptiveMutex lock; +#else Common::SpinLock lock; +#endif PageManager* tracker; VAddr cpu_addr = 0; WordsArray cpu; diff --git a/src/video_core/page_manager.h b/src/video_core/page_manager.h index f44307f92..f6bae9641 100644 --- a/src/video_core/page_manager.h +++ b/src/video_core/page_manager.h @@ -5,6 +5,9 @@ #include #include +#ifdef __linux__ +#include "common/adaptive_mutex.h" +#endif #include "common/spin_lock.h" #include "common/types.h" @@ -36,7 +39,11 @@ private: std::unique_ptr impl; Vulkan::Rasterizer* rasterizer; boost::icl::interval_map cached_pages; +#ifdef PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP + Common::AdaptiveMutex lock; +#else Common::SpinLock lock; +#endif }; } // namespace VideoCore From 12364b197a87ec79cd476eb0e73d1015ef02cac0 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sat, 18 Jan 2025 01:13:16 -0800 Subject: [PATCH 10/99] renderer_vulkan: Remove swapchain image reinterpretation. (#2176) --- .../renderer_vulkan/vk_instance.cpp | 1 - .../renderer_vulkan/vk_presenter.cpp | 2 +- .../renderer_vulkan/vk_swapchain.cpp | 20 ++++--------------- src/video_core/renderer_vulkan/vk_swapchain.h | 15 -------------- 4 files changed, 5 insertions(+), 33 deletions(-) diff --git a/src/video_core/renderer_vulkan/vk_instance.cpp b/src/video_core/renderer_vulkan/vk_instance.cpp index d9577a612..15bd573ef 100644 --- a/src/video_core/renderer_vulkan/vk_instance.cpp +++ b/src/video_core/renderer_vulkan/vk_instance.cpp @@ -271,7 +271,6 @@ bool Instance::CreateDevice() { legacy_vertex_attributes = add_extension(VK_EXT_LEGACY_VERTEX_ATTRIBUTES_EXTENSION_NAME); image_load_store_lod = add_extension(VK_AMD_SHADER_IMAGE_LOAD_STORE_LOD_EXTENSION_NAME); amd_gcn_shader = add_extension(VK_AMD_GCN_SHADER_EXTENSION_NAME); - add_extension(VK_KHR_SWAPCHAIN_MUTABLE_FORMAT_EXTENSION_NAME); // These extensions are promoted by Vulkan 1.3, but for greater compatibility we use Vulkan 1.2 // with extensions. diff --git a/src/video_core/renderer_vulkan/vk_presenter.cpp b/src/video_core/renderer_vulkan/vk_presenter.cpp index fcdb84676..ce2e02a43 100644 --- a/src/video_core/renderer_vulkan/vk_presenter.cpp +++ b/src/video_core/renderer_vulkan/vk_presenter.cpp @@ -380,7 +380,7 @@ void Presenter::RecreateFrame(Frame* frame, u32 width, u32 height) { const vk::ImageViewCreateInfo view_info = { .image = frame->image, .viewType = vk::ImageViewType::e2D, - .format = swapchain.GetViewFormat(), + .format = format, .subresourceRange{ .aspectMask = vk::ImageAspectFlagBits::eColor, .baseMipLevel = 0, diff --git a/src/video_core/renderer_vulkan/vk_swapchain.cpp b/src/video_core/renderer_vulkan/vk_swapchain.cpp index 438fe30ce..5467a5733 100644 --- a/src/video_core/renderer_vulkan/vk_swapchain.cpp +++ b/src/video_core/renderer_vulkan/vk_swapchain.cpp @@ -17,7 +17,7 @@ Swapchain::Swapchain(const Instance& instance_, const Frontend::WindowSDL& windo FindPresentFormat(); Create(window.GetWidth(), window.GetHeight()); - ImGui::Core::Initialize(instance, window, image_count, view_format); + ImGui::Core::Initialize(instance, window, image_count, surface_format.format); } Swapchain::~Swapchain() { @@ -57,17 +57,7 @@ void Swapchain::Create(u32 width_, u32 height_) { const u32 queue_family_indices_count = exclusive ? 1u : 2u; const vk::SharingMode sharing_mode = exclusive ? vk::SharingMode::eExclusive : vk::SharingMode::eConcurrent; - const vk::Format view_formats[2] = { - surface_format.format, - view_format, - }; - const vk::ImageFormatListCreateInfo format_list = { - .viewFormatCount = 2, - .pViewFormats = view_formats, - }; const vk::SwapchainCreateInfoKHR swapchain_info = { - .pNext = &format_list, - .flags = vk::SwapchainCreateFlagBitsKHR::eMutableFormat, .surface = surface, .minImageCount = image_count, .imageFormat = surface_format.format, @@ -157,22 +147,20 @@ void Swapchain::FindPresentFormat() { // If there is a single undefined surface format, the device doesn't care, so we'll just use // RGBA sRGB. if (formats[0].format == vk::Format::eUndefined) { - surface_format.format = vk::Format::eR8G8B8A8Srgb; + surface_format.format = vk::Format::eR8G8B8A8Unorm; surface_format.colorSpace = vk::ColorSpaceKHR::eSrgbNonlinear; - view_format = FormatToUnorm(surface_format.format); return; } // Try to find a suitable format. for (const vk::SurfaceFormatKHR& sformat : formats) { vk::Format format = sformat.format; - if (format != vk::Format::eR8G8B8A8Srgb && format != vk::Format::eB8G8R8A8Srgb) { + if (format != vk::Format::eR8G8B8A8Unorm && format != vk::Format::eB8G8R8A8Unorm) { continue; } surface_format.format = format; surface_format.colorSpace = sformat.colorSpace; - view_format = FormatToUnorm(surface_format.format); return; } @@ -274,7 +262,7 @@ void Swapchain::SetupImages() { auto [im_view_result, im_view] = device.createImageView(vk::ImageViewCreateInfo{ .image = images[i], .viewType = vk::ImageViewType::e2D, - .format = FormatToUnorm(surface_format.format), + .format = surface_format.format, .subresourceRange = { .aspectMask = vk::ImageAspectFlagBits::eColor, diff --git a/src/video_core/renderer_vulkan/vk_swapchain.h b/src/video_core/renderer_vulkan/vk_swapchain.h index 9da75c758..f5cf9f0d2 100644 --- a/src/video_core/renderer_vulkan/vk_swapchain.h +++ b/src/video_core/renderer_vulkan/vk_swapchain.h @@ -17,17 +17,6 @@ namespace Vulkan { class Instance; class Scheduler; -inline vk::Format FormatToUnorm(vk::Format fmt) { - switch (fmt) { - case vk::Format::eR8G8B8A8Srgb: - return vk::Format::eR8G8B8A8Unorm; - case vk::Format::eB8G8R8A8Srgb: - return vk::Format::eB8G8R8A8Unorm; - default: - UNREACHABLE(); - } -} - class Swapchain { public: explicit Swapchain(const Instance& instance, const Frontend::WindowSDL& window); @@ -61,10 +50,6 @@ public: return surface_format; } - vk::Format GetViewFormat() const { - return view_format; - } - vk::SwapchainKHR GetHandle() const { return swapchain; } From d3615796186b44902599ca2a41c61dd0b73b3eb5 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sat, 18 Jan 2025 01:35:44 -0800 Subject: [PATCH 11/99] texture_cache: Fix image mip overlap. (#2177) --- src/video_core/renderer_vulkan/vk_rasterizer.cpp | 2 -- src/video_core/texture_cache/image_info.cpp | 2 +- src/video_core/texture_cache/image_view.cpp | 9 ++++++--- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/video_core/renderer_vulkan/vk_rasterizer.cpp b/src/video_core/renderer_vulkan/vk_rasterizer.cpp index 07369c620..88b510eca 100644 --- a/src/video_core/renderer_vulkan/vk_rasterizer.cpp +++ b/src/video_core/renderer_vulkan/vk_rasterizer.cpp @@ -802,8 +802,6 @@ void Rasterizer::BeginRendering(const GraphicsPipeline& pipeline, RenderState& s const auto mip = view.info.range.base.level; state.width = std::min(state.width, std::max(image.info.size.width >> mip, 1u)); state.height = std::min(state.height, std::max(image.info.size.height >> mip, 1u)); - ASSERT(old_img.info.size.width == state.width); - ASSERT(old_img.info.size.height == state.height); } auto& image = texture_cache.GetImage(image_id); if (image.binding.force_general) { diff --git a/src/video_core/texture_cache/image_info.cpp b/src/video_core/texture_cache/image_info.cpp index 07a0488f3..a9ed76960 100644 --- a/src/video_core/texture_cache/image_info.cpp +++ b/src/video_core/texture_cache/image_info.cpp @@ -219,7 +219,7 @@ int ImageInfo::IsMipOf(const ImageInfo& info) const { return -1; } - if (IsTilingCompatible(info.tiling_idx, tiling_idx)) { + if (!IsTilingCompatible(info.tiling_idx, tiling_idx)) { return -1; } diff --git a/src/video_core/texture_cache/image_view.cpp b/src/video_core/texture_cache/image_view.cpp index 6b1349386..7befb5259 100644 --- a/src/video_core/texture_cache/image_view.cpp +++ b/src/video_core/texture_cache/image_view.cpp @@ -114,9 +114,12 @@ ImageView::ImageView(const Vulkan::Instance& instance, const ImageViewInfo& info const auto view_aspect = aspect & vk::ImageAspectFlagBits::eDepth ? "Depth" : aspect & vk::ImageAspectFlagBits::eStencil ? "Stencil" : "Color"; - Vulkan::SetObjectName(instance.GetDevice(), *image_view, "ImageView {}x{}x{} {:#x}:{:#x} ({})", - image.info.size.width, image.info.size.height, image.info.size.depth, - image.info.guest_address, image.info.guest_size, view_aspect); + Vulkan::SetObjectName( + instance.GetDevice(), *image_view, "ImageView {}x{}x{} {:#x}:{:#x} {}:{} {}:{} ({})", + image.info.size.width, image.info.size.height, image.info.size.depth, + image.info.guest_address, image.info.guest_size, info.range.base.level, + info.range.base.level + info.range.extent.levels - 1, info.range.base.layer, + info.range.base.layer + info.range.extent.layers - 1, view_aspect); } ImageView::~ImageView() = default; From c80151addedf25f497ad1064f5b3ab36bdcca28d Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sat, 18 Jan 2025 02:29:19 -0800 Subject: [PATCH 12/99] vk_presenter: Fix splash issues. (#2180) --- src/video_core/renderer_vulkan/vk_presenter.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/video_core/renderer_vulkan/vk_presenter.cpp b/src/video_core/renderer_vulkan/vk_presenter.cpp index ce2e02a43..36d64a5d5 100644 --- a/src/video_core/renderer_vulkan/vk_presenter.cpp +++ b/src/video_core/renderer_vulkan/vk_presenter.cpp @@ -476,7 +476,7 @@ bool Presenter::ShowSplash(Frame* frame /*= nullptr*/) { if (!frame) { if (!splash_img.has_value()) { VideoCore::ImageInfo info{}; - info.pixel_format = vk::Format::eR8G8B8A8Srgb; + info.pixel_format = vk::Format::eR8G8B8A8Unorm; info.type = vk::ImageType::e2D; info.size = VideoCore::Extent3D{splash->GetImageInfo().width, splash->GetImageInfo().height, 1}; @@ -487,6 +487,7 @@ bool Presenter::ShowSplash(Frame* frame /*= nullptr*/) { splash->GetImageInfo().width, splash->GetImageInfo().height, 0); splash_img.emplace(instance, present_scheduler, info); + splash_img->flags &= ~VideoCore::GpuDirty; texture_cache.RefreshImage(*splash_img); splash_img->Transit(vk::ImageLayout::eTransferSrcOptimal, From 1ea5f8f09243b958ff64d879116c89dd24a627ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Quang=20Ng=C3=B4?= Date: Sat, 18 Jan 2025 17:48:39 +0700 Subject: [PATCH 13/99] input: Unbroke KBM-only input (#2179) --- src/input/controller.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/input/controller.cpp b/src/input/controller.cpp index 71f0b0c09..ae54553f4 100644 --- a/src/input/controller.cpp +++ b/src/input/controller.cpp @@ -69,7 +69,7 @@ void GameController::ReadState(State* state, bool* isConnected, int* connectedCo *isConnected = m_connected; *connectedCount = m_connected_count; - *state = m_engine && m_connected ? m_engine->ReadState() : GetLastState(); + *state = GetLastState(); } int GameController::ReadStates(State* states, int states_num, bool* isConnected, From 3b92cd1c1a68f18b3f68afb58860d3c2e828aff2 Mon Sep 17 00:00:00 2001 From: kalaposfos13 <153381648+kalaposfos13@users.noreply.github.com> Date: Sat, 18 Jan 2025 13:21:08 +0100 Subject: [PATCH 14/99] CLI: Add argument to pass an argument to the game (#2135) --- src/core/linker.cpp | 10 ++++++++-- src/core/linker.h | 4 ++-- src/emulator.cpp | 13 +++++++++++-- src/emulator.h | 2 +- src/main.cpp | 21 ++++++++++++++++++++- src/qt_gui/main.cpp | 20 +++++++++++++++++++- 6 files changed, 61 insertions(+), 9 deletions(-) diff --git a/src/core/linker.cpp b/src/core/linker.cpp index 28d2eea7b..2461edcb2 100644 --- a/src/core/linker.cpp +++ b/src/core/linker.cpp @@ -52,7 +52,7 @@ Linker::Linker() : memory{Memory::Instance()} {} Linker::~Linker() = default; -void Linker::Execute() { +void Linker::Execute(const std::vector args) { if (Config::debugDump()) { DebugDump(); } @@ -101,7 +101,7 @@ void Linker::Execute() { memory->SetupMemoryRegions(fmem_size, use_extended_mem1, use_extended_mem2); - main_thread.Run([this, module](std::stop_token) { + main_thread.Run([this, module, args](std::stop_token) { Common::SetCurrentThreadName("GAME_MainThread"); LoadSharedLibraries(); @@ -109,6 +109,12 @@ void Linker::Execute() { EntryParams params{}; params.argc = 1; params.argv[0] = "eboot.bin"; + if (!args.empty()) { + params.argc = args.size() + 1; + for (int i = 0; i < args.size() && i < 32; i++) { + params.argv[i + 1] = args[i].c_str(); + } + } params.entry_addr = module->GetEntryAddress(); RunMainEntry(¶ms); }); diff --git a/src/core/linker.h b/src/core/linker.h index 7ef13ae56..00da3a08c 100644 --- a/src/core/linker.h +++ b/src/core/linker.h @@ -49,7 +49,7 @@ class Linker; struct EntryParams { int argc; u32 padding; - const char* argv[3]; + const char* argv[33]; VAddr entry_addr; }; @@ -143,7 +143,7 @@ public: void Relocate(Module* module); bool Resolve(const std::string& name, Loader::SymbolType type, Module* module, Loader::SymbolRecord* return_info); - void Execute(); + void Execute(const std::vector args = {}); void DebugDump(); private: diff --git a/src/emulator.cpp b/src/emulator.cpp index 61d6d3862..e77c2b87f 100644 --- a/src/emulator.cpp +++ b/src/emulator.cpp @@ -99,7 +99,7 @@ Emulator::~Emulator() { Config::saveMainWindow(config_dir / "config.toml"); } -void Emulator::Run(const std::filesystem::path& file) { +void Emulator::Run(const std::filesystem::path& file, const std::vector args) { // Applications expect to be run from /app0 so mount the file's parent path as app0. auto* mnt = Common::Singleton::Instance(); const auto game_folder = file.parent_path(); @@ -152,6 +152,15 @@ void Emulator::Run(const std::filesystem::path& file) { if (const auto raw_attributes = param_sfo->GetInteger("ATTRIBUTE")) { psf_attributes.raw = *raw_attributes; } + if (!args.empty()) { + int argc = std::min(args.size(), 32); + for (int i = 0; i < argc; i++) { + LOG_INFO(Loader, "Game argument {}: {}", i, args[i]); + } + if (args.size() > 32) { + LOG_ERROR(Loader, "Too many game arguments, only passing the first 32"); + } + } } const auto pic1_path = mnt->GetHostPath("/app0/sce_sys/pic1.png"); @@ -239,7 +248,7 @@ void Emulator::Run(const std::filesystem::path& file) { } #endif - linker->Execute(); + linker->Execute(args); window->InitTimers(); while (window->IsOpen()) { diff --git a/src/emulator.h b/src/emulator.h index a08ab43c3..08c2807a1 100644 --- a/src/emulator.h +++ b/src/emulator.h @@ -25,7 +25,7 @@ public: Emulator(); ~Emulator(); - void Run(const std::filesystem::path& file); + void Run(const std::filesystem::path& file, const std::vector args = {}); void UpdatePlayTime(const std::string& serial); private: diff --git a/src/main.cpp b/src/main.cpp index 54772870c..fad3b1f53 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -29,6 +29,7 @@ int main(int argc, char* argv[]) { bool has_game_argument = false; std::string game_path; + std::vector game_args{}; // Map of argument strings to lambda functions std::unordered_map> arg_map = { @@ -37,6 +38,9 @@ int main(int argc, char* argv[]) { std::cout << "Usage: shadps4 [options] \n" "Options:\n" " -g, --game Specify game path to launch\n" + " -- ... Parameters passed to the game ELF. " + "Needs to be at the end of the line, and everything after \"--\" is a " + "game argument.\n" " -p, --patch Apply specified patch file\n" " -f, --fullscreen Specify window initial fullscreen " "state. Does not overwrite the config file.\n" @@ -126,6 +130,21 @@ int main(int argc, char* argv[]) { // Assume the last argument is the game file if not specified via -g/--game game_path = argv[i]; has_game_argument = true; + } else if (std::string(argv[i]) == "--") { + if (i + 1 == argc) { + std::cerr << "Warning: -- is set, but no game arguments are added!\n"; + break; + } + for (int j = i + 1; j < argc; j++) { + game_args.push_back(argv[j]); + } + break; + } else if (i + 1 < argc && std::string(argv[i + 1]) == "--") { + if (!has_game_argument) { + game_path = argv[i]; + has_game_argument = true; + } + break; } else { std::cerr << "Unknown argument: " << cur_arg << ", see --help for info.\n"; return 1; @@ -166,7 +185,7 @@ int main(int argc, char* argv[]) { // Run the emulator with the resolved eboot path Core::Emulator emulator; - emulator.Run(eboot_path); + emulator.Run(eboot_path, game_args); return 0; } diff --git a/src/qt_gui/main.cpp b/src/qt_gui/main.cpp index 2d524e199..8babadc35 100644 --- a/src/qt_gui/main.cpp +++ b/src/qt_gui/main.cpp @@ -33,6 +33,7 @@ int main(int argc, char* argv[]) { bool has_command_line_argument = argc > 1; bool show_gui = false, has_game_argument = false; std::string game_path; + std::vector game_args{}; // Map of argument strings to lambda functions std::unordered_map> arg_map = { @@ -43,6 +44,9 @@ int main(int argc, char* argv[]) { " No arguments: Opens the GUI.\n" " -g, --game Specify or " " to launch\n" + " -- ... Parameters passed to the game ELF. " + "Needs to be at the end of the line, and everything after \"--\" is a " + "game argument.\n" " -p, --patch Apply specified patch file\n" " -s, --show-gui Show the GUI\n" " -f, --fullscreen Specify window initial fullscreen " @@ -131,6 +135,20 @@ int main(int argc, char* argv[]) { // Assume the last argument is the game file if not specified via -g/--game game_path = argv[i]; has_game_argument = true; + } else if (std::string(argv[i]) == "--") { + if (i + 1 == argc) { + std::cerr << "Warning: -- is set, but no game arguments are added!\n"; + break; + } + for (int j = i + 1; j < argc; j++) { + game_args.push_back(argv[j]); + } + break; + } else if (i + 1 < argc && std::string(argv[i + 1]) == "--") { + if (!has_game_argument) { + game_path = argv[i]; + has_game_argument = true; + } } else { std::cerr << "Unknown argument: " << cur_arg << ", see --help for info.\n"; return 1; @@ -181,7 +199,7 @@ int main(int argc, char* argv[]) { // Run the emulator with the resolved game path Core::Emulator emulator; - emulator.Run(game_file_path.string()); + emulator.Run(game_file_path.string(), game_args); if (!show_gui) { return 0; // Exit after running the emulator without showing the GUI } From 388548ba470aa68c5fff4e5737e03031e5783f8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C2=A5IGA?= <164882787+Xphalnos@users.noreply.github.com> Date: Sat, 18 Jan 2025 14:02:02 +0100 Subject: [PATCH 15/99] pad: Configurable DeadZone (#2030) --- src/common/config.cpp | 14 ++++++++++++++ src/common/config.h | 2 ++ src/core/libraries/pad/pad.cpp | 8 ++++---- 3 files changed, 20 insertions(+), 4 deletions(-) diff --git a/src/common/config.cpp b/src/common/config.cpp index 9c842f8b7..ed9af5a72 100644 --- a/src/common/config.cpp +++ b/src/common/config.cpp @@ -45,6 +45,8 @@ static std::string logFilter; static std::string logType = "async"; static std::string userName = "shadPS4"; static std::string updateChannel; +static u16 deadZoneLeft = 2.0; +static u16 deadZoneRight = 2.0; static std::string backButtonBehavior = "left"; static bool useSpecialPad = false; static int specialPadClass = 1; @@ -140,6 +142,14 @@ bool getEnableDiscordRPC() { return enableDiscordRPC; } +u16 leftDeadZone() { + return deadZoneLeft; +} + +u16 rightDeadZone() { + return deadZoneRight; +} + s16 getCursorState() { return cursorState; } @@ -620,6 +630,8 @@ void load(const std::filesystem::path& path) { if (data.contains("Input")) { const toml::value& input = data.at("Input"); + deadZoneLeft = toml::find_or(input, "deadZoneLeft", 2.0); + deadZoneRight = toml::find_or(input, "deadZoneRight", 2.0); cursorState = toml::find_or(input, "cursorState", HideCursorState::Idle); cursorHideTimeout = toml::find_or(input, "cursorHideTimeout", 5); backButtonBehavior = toml::find_or(input, "backButtonBehavior", "left"); @@ -739,6 +751,8 @@ void save(const std::filesystem::path& path) { data["General"]["separateUpdateEnabled"] = separateupdatefolder; data["General"]["compatibilityEnabled"] = compatibilityData; data["General"]["checkCompatibilityOnStartup"] = checkCompatibilityOnStartup; + data["Input"]["deadZoneLeft"] = deadZoneLeft; + data["Input"]["deadZoneRight"] = deadZoneRight; data["Input"]["cursorState"] = cursorState; data["Input"]["cursorHideTimeout"] = cursorHideTimeout; data["Input"]["backButtonBehavior"] = backButtonBehavior; diff --git a/src/common/config.h b/src/common/config.h index f9e4c2815..cb56f99c7 100644 --- a/src/common/config.h +++ b/src/common/config.h @@ -35,6 +35,8 @@ std::string getLogType(); std::string getUserName(); std::string getUpdateChannel(); +u16 leftDeadZone(); +u16 rightDeadZone(); s16 getCursorState(); int getCursorHideTimeout(); std::string getBackButtonBehavior(); diff --git a/src/core/libraries/pad/pad.cpp b/src/core/libraries/pad/pad.cpp index 9a44f91f0..f2b81fbe0 100644 --- a/src/core/libraries/pad/pad.cpp +++ b/src/core/libraries/pad/pad.cpp @@ -95,8 +95,8 @@ int PS4_SYSV_ABI scePadGetControllerInformation(s32 handle, OrbisPadControllerIn pInfo->touchPadInfo.pixelDensity = 1; pInfo->touchPadInfo.resolution.x = 1920; pInfo->touchPadInfo.resolution.y = 950; - pInfo->stickInfo.deadZoneLeft = 2; - pInfo->stickInfo.deadZoneRight = 2; + pInfo->stickInfo.deadZoneLeft = Config::leftDeadZone(); + pInfo->stickInfo.deadZoneRight = Config::rightDeadZone(); pInfo->connectionType = ORBIS_PAD_PORT_TYPE_STANDARD; pInfo->connectedCount = 1; pInfo->connected = false; @@ -106,8 +106,8 @@ int PS4_SYSV_ABI scePadGetControllerInformation(s32 handle, OrbisPadControllerIn pInfo->touchPadInfo.pixelDensity = 1; pInfo->touchPadInfo.resolution.x = 1920; pInfo->touchPadInfo.resolution.y = 950; - pInfo->stickInfo.deadZoneLeft = 2; - pInfo->stickInfo.deadZoneRight = 2; + pInfo->stickInfo.deadZoneLeft = Config::leftDeadZone(); + pInfo->stickInfo.deadZoneRight = Config::rightDeadZone(); pInfo->connectionType = ORBIS_PAD_PORT_TYPE_STANDARD; pInfo->connectedCount = 1; pInfo->connected = true; From 269ce126149700ba340d7014a04faa215ddf64f9 Mon Sep 17 00:00:00 2001 From: Vladislav Mikhalin Date: Sat, 18 Jan 2025 16:54:06 +0300 Subject: [PATCH 16/99] fix build on arch --- src/video_core/renderer_vulkan/vk_instance.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/video_core/renderer_vulkan/vk_instance.cpp b/src/video_core/renderer_vulkan/vk_instance.cpp index 15bd573ef..5efdf4127 100644 --- a/src/video_core/renderer_vulkan/vk_instance.cpp +++ b/src/video_core/renderer_vulkan/vk_instance.cpp @@ -566,7 +566,8 @@ void Instance::CollectToolingInfo() { return; } for (const vk::PhysicalDeviceToolProperties& tool : tools) { - LOG_INFO(Render_Vulkan, "Attached debugging tool: {}", tool.name); + const std::string_view name = tool.name; + LOG_INFO(Render_Vulkan, "Attached debugging tool: {}", name); } } From 746f2e091d3aa1c56cf56e0a16c858d01eaf31cd Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sun, 19 Jan 2025 03:06:31 -0800 Subject: [PATCH 17/99] tile: Account for thickness in micro tiled size calculation. (#2185) --- src/video_core/texture_cache/image_info.cpp | 10 ++++++---- src/video_core/texture_cache/tile.h | 10 +++++----- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/src/video_core/texture_cache/image_info.cpp b/src/video_core/texture_cache/image_info.cpp index a9ed76960..8068aae2f 100644 --- a/src/video_core/texture_cache/image_info.cpp +++ b/src/video_core/texture_cache/image_info.cpp @@ -166,6 +166,7 @@ void ImageInfo::UpdateSize() { mip_w = std::max(mip_w, 1u); mip_h = std::max(mip_h, 1u); auto mip_d = std::max(size.depth >> mip, 1u); + auto thickness = 1; if (props.is_pow2) { mip_w = std::bit_ceil(mip_w); @@ -181,12 +182,13 @@ void ImageInfo::UpdateSize() { break; } case AmdGpu::TilingMode::Texture_Volume: - mip_d += (-mip_d) & 3u; + thickness = 4; + mip_d += (-mip_d) & (thickness - 1); [[fallthrough]]; case AmdGpu::TilingMode::Display_MicroTiled: case AmdGpu::TilingMode::Texture_MicroTiled: { std::tie(mip_info.pitch, mip_info.size) = - ImageSizeMicroTiled(mip_w, mip_h, bpp, num_samples); + ImageSizeMicroTiled(mip_w, mip_h, bpp, thickness, num_samples); mip_info.height = std::max(mip_h, 8u); if (props.is_block) { mip_info.pitch = std::max(mip_info.pitch * 4, 32u); @@ -198,8 +200,8 @@ void ImageInfo::UpdateSize() { case AmdGpu::TilingMode::Texture_MacroTiled: case AmdGpu::TilingMode::Depth_MacroTiled: { ASSERT(!props.is_block); - std::tie(mip_info.pitch, mip_info.size) = - ImageSizeMacroTiled(mip_w, mip_h, bpp, num_samples, tiling_idx, mip, alt_tile); + std::tie(mip_info.pitch, mip_info.size) = ImageSizeMacroTiled( + mip_w, mip_h, thickness, bpp, num_samples, tiling_idx, mip, alt_tile); break; } default: { diff --git a/src/video_core/texture_cache/tile.h b/src/video_core/texture_cache/tile.h index 532bf3d88..c111e6aca 100644 --- a/src/video_core/texture_cache/tile.h +++ b/src/video_core/texture_cache/tile.h @@ -308,20 +308,20 @@ constexpr std::pair ImageSizeLinearAligned(u32 pitch, u32 height, u return {pitch_aligned, (log_sz * bpp + 7) / 8}; } -constexpr std::pair ImageSizeMicroTiled(u32 pitch, u32 height, u32 bpp, +constexpr std::pair ImageSizeMicroTiled(u32 pitch, u32 height, u32 thickness, u32 bpp, u32 num_samples) { const auto& [pitch_align, height_align] = micro_tile_extent; auto pitch_aligned = (pitch + pitch_align - 1) & ~(pitch_align - 1); const auto height_aligned = (height + height_align - 1) & ~(height_align - 1); - size_t log_sz = (pitch_aligned * height_aligned * bpp * num_samples + 7) / 8; + size_t log_sz = (pitch_aligned * height_aligned * bpp * num_samples * thickness + 7) / 8; while (log_sz % 256) { - pitch_aligned += 8; + pitch_aligned += pitch_align; log_sz = (pitch_aligned * height_aligned * bpp * num_samples + 7) / 8; } return {pitch_aligned, log_sz}; } -constexpr std::pair ImageSizeMacroTiled(u32 pitch, u32 height, u32 bpp, +constexpr std::pair ImageSizeMacroTiled(u32 pitch, u32 height, u32 thickness, u32 bpp, u32 num_samples, u32 tiling_idx, u32 mip_n, bool alt) { const auto& [pitch_align, height_align] = @@ -335,7 +335,7 @@ constexpr std::pair ImageSizeMacroTiled(u32 pitch, u32 height, u32 } if (downgrade_to_micro) { - return ImageSizeMicroTiled(pitch, height, bpp, num_samples); + return ImageSizeMicroTiled(pitch, height, thickness, bpp, num_samples); } const auto pitch_aligned = (pitch + pitch_align - 1) & ~(pitch_align - 1); From ec0dfb32b532fe2ddc28b3a1e65343e71cfcd92f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Quang=20Ng=C3=B4?= Date: Sun, 19 Jan 2025 19:03:15 +0700 Subject: [PATCH 18/99] Some ImGui tweaks for the game window (#2183) * Remove window border * Remove window rounding * Set background color to black --- src/video_core/renderer_vulkan/vk_presenter.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/video_core/renderer_vulkan/vk_presenter.cpp b/src/video_core/renderer_vulkan/vk_presenter.cpp index 36d64a5d5..35ab4318a 100644 --- a/src/video_core/renderer_vulkan/vk_presenter.cpp +++ b/src/video_core/renderer_vulkan/vk_presenter.cpp @@ -825,6 +825,9 @@ void Presenter::Present(Frame* frame, bool is_reusing_frame) { { // Draw the game ImGui::PushStyleVar(ImGuiStyleVar_WindowPadding, ImVec2{0.0f}); + ImGui::PushStyleVar(ImGuiStyleVar_WindowRounding, 0.0f); + ImGui::PushStyleVar(ImGuiStyleVar_WindowBorderSize, 0.0f); + ImGui::PushStyleColor(ImGuiCol_WindowBg, ImVec4(0.0f, 0.0f, 0.0f, 1.0f)); ImGui::SetNextWindowDockID(dockId, ImGuiCond_Once); ImGui::Begin("Display##game_display", nullptr, ImGuiWindowFlags_NoNav); @@ -840,7 +843,8 @@ void Presenter::Present(Frame* frame, bool is_reusing_frame) { static_cast(imgRect.extent.height), }); ImGui::End(); - ImGui::PopStyleVar(); + ImGui::PopStyleVar(3); + ImGui::PopStyleColor(); } ImGui::Core::Render(cmdbuf, swapchain_image_view, swapchain.GetExtent()); From a7d45231b77633361862ef82cfafeb4d2a4669ac Mon Sep 17 00:00:00 2001 From: georgemoralis Date: Sun, 19 Jan 2025 15:44:57 +0200 Subject: [PATCH 19/99] Filesystem devices (#2184) * added dummy devices * More WIP * added urandom,srandom,random,console,deci_tty6 devices * small fix * macOS fix --- CMakeLists.txt | 10 ++++ src/core/devices/deci_tty6.cpp | 66 +++++++++++++++++++++ src/core/devices/deci_tty6.h | 33 +++++++++++ src/core/devices/dev_console.cpp | 67 +++++++++++++++++++++ src/core/devices/dev_console.h | 33 +++++++++++ src/core/devices/random.cpp | 68 ++++++++++++++++++++++ src/core/devices/random.h | 33 +++++++++++ src/core/devices/srandom.cpp | 69 ++++++++++++++++++++++ src/core/devices/srandom.h | 33 +++++++++++ src/core/devices/urandom.cpp | 71 +++++++++++++++++++++++ src/core/devices/urandom.h | 33 +++++++++++ src/core/libraries/kernel/file_system.cpp | 33 ++++------- 12 files changed, 527 insertions(+), 22 deletions(-) create mode 100644 src/core/devices/deci_tty6.cpp create mode 100644 src/core/devices/deci_tty6.h create mode 100644 src/core/devices/dev_console.cpp create mode 100644 src/core/devices/dev_console.h create mode 100644 src/core/devices/random.cpp create mode 100644 src/core/devices/random.h create mode 100644 src/core/devices/srandom.cpp create mode 100644 src/core/devices/srandom.h create mode 100644 src/core/devices/urandom.cpp create mode 100644 src/core/devices/urandom.h diff --git a/CMakeLists.txt b/CMakeLists.txt index 30cb033ed..e5c16bd1b 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -557,6 +557,16 @@ set(CORE src/core/aerolib/stubs.cpp src/core/devices/logger.cpp src/core/devices/logger.h src/core/devices/nop_device.h + src/core/devices/dev_console.cpp + src/core/devices/dev_console.h + src/core/devices/deci_tty6.cpp + src/core/devices/deci_tty6.h + src/core/devices/random.cpp + src/core/devices/random.h + src/core/devices/urandom.cpp + src/core/devices/urandom.h + src/core/devices/srandom.cpp + src/core/devices/srandom.h src/core/file_format/pfs.h src/core/file_format/pkg.cpp src/core/file_format/pkg.h diff --git a/src/core/devices/deci_tty6.cpp b/src/core/devices/deci_tty6.cpp new file mode 100644 index 000000000..20423de61 --- /dev/null +++ b/src/core/devices/deci_tty6.cpp @@ -0,0 +1,66 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "common/logging/log.h" +#include "deci_tty6.h" + +namespace Core::Devices { +std::shared_ptr DeciTty6Device::Create(u32 handle, const char*, int, u16) { + return std::shared_ptr( + reinterpret_cast(new DeciTty6Device(handle))); +} +int DeciTty6Device::ioctl(u64 cmd, Common::VaCtx* args) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 DeciTty6Device::write(const void* buf, size_t nbytes) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +size_t DeciTty6Device::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +size_t DeciTty6Device::readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 DeciTty6Device::preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 DeciTty6Device::lseek(s64 offset, int whence) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s64 DeciTty6Device::read(void* buf, size_t nbytes) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int DeciTty6Device::fstat(Libraries::Kernel::OrbisKernelStat* sb) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s32 DeciTty6Device::fsync() { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int DeciTty6Device::ftruncate(s64 length) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int DeciTty6Device::getdents(void* buf, u32 nbytes, s64* basep) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s64 DeciTty6Device::pwrite(const void* buf, size_t nbytes, u64 offset) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +} // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/deci_tty6.h b/src/core/devices/deci_tty6.h new file mode 100644 index 000000000..71cbfba6b --- /dev/null +++ b/src/core/devices/deci_tty6.h @@ -0,0 +1,33 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once +#include +#include "base_device.h" + +namespace Core::Devices { + +class DeciTty6Device final : BaseDevice { + u32 handle; + +public: + static std::shared_ptr Create(u32 handle, const char*, int, u16); + explicit DeciTty6Device(u32 handle) : handle(handle) {} + + ~DeciTty6Device() override = default; + + int ioctl(u64 cmd, Common::VaCtx* args) override; + s64 write(const void* buf, size_t nbytes) override; + size_t readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override; + size_t writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override; + s64 preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) override; + s64 lseek(s64 offset, int whence) override; + s64 read(void* buf, size_t nbytes) override; + int fstat(Libraries::Kernel::OrbisKernelStat* sb) override; + s32 fsync() override; + int ftruncate(s64 length) override; + int getdents(void* buf, u32 nbytes, s64* basep) override; + s64 pwrite(const void* buf, size_t nbytes, u64 offset) override; +}; + +} // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/dev_console.cpp b/src/core/devices/dev_console.cpp new file mode 100644 index 000000000..0ddcfd040 --- /dev/null +++ b/src/core/devices/dev_console.cpp @@ -0,0 +1,67 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "common/logging/log.h" +#include "dev_console.h" + +namespace Core::Devices { +std::shared_ptr ConsoleDevice::Create(u32 handle, const char*, int, u16) { + return std::shared_ptr( + reinterpret_cast(new ConsoleDevice(handle))); +} +int ConsoleDevice::ioctl(u64 cmd, Common::VaCtx* args) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 ConsoleDevice::write(const void* buf, size_t nbytes) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +size_t ConsoleDevice::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +size_t ConsoleDevice::readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 ConsoleDevice::preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 ConsoleDevice::lseek(s64 offset, int whence) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s64 ConsoleDevice::read(void* buf, size_t nbytes) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int ConsoleDevice::fstat(Libraries::Kernel::OrbisKernelStat* sb) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s32 ConsoleDevice::fsync() { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int ConsoleDevice::ftruncate(s64 length) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int ConsoleDevice::getdents(void* buf, u32 nbytes, s64* basep) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s64 ConsoleDevice::pwrite(const void* buf, size_t nbytes, u64 offset) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +} // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/dev_console.h b/src/core/devices/dev_console.h new file mode 100644 index 000000000..f280200e2 --- /dev/null +++ b/src/core/devices/dev_console.h @@ -0,0 +1,33 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once +#include +#include "base_device.h" + +namespace Core::Devices { + +class ConsoleDevice final : BaseDevice { + u32 handle; + +public: + static std::shared_ptr Create(u32 handle, const char*, int, u16); + explicit ConsoleDevice(u32 handle) : handle(handle) {} + + ~ConsoleDevice() override = default; + + int ioctl(u64 cmd, Common::VaCtx* args) override; + s64 write(const void* buf, size_t nbytes) override; + size_t readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override; + size_t writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override; + s64 preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) override; + s64 lseek(s64 offset, int whence) override; + s64 read(void* buf, size_t nbytes) override; + int fstat(Libraries::Kernel::OrbisKernelStat* sb) override; + s32 fsync() override; + int ftruncate(s64 length) override; + int getdents(void* buf, u32 nbytes, s64* basep) override; + s64 pwrite(const void* buf, size_t nbytes, u64 offset) override; +}; + +} // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/random.cpp b/src/core/devices/random.cpp new file mode 100644 index 000000000..705449423 --- /dev/null +++ b/src/core/devices/random.cpp @@ -0,0 +1,68 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later +#include +#include "common/logging/log.h" +#include "random.h" + +namespace Core::Devices { +std::shared_ptr RandomDevice::Create(u32 handle, const char*, int, u16) { + std::srand(std::time(nullptr)); + return std::shared_ptr( + reinterpret_cast(new RandomDevice(handle))); +} +int RandomDevice::ioctl(u64 cmd, Common::VaCtx* args) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 RandomDevice::write(const void* buf, size_t nbytes) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +size_t RandomDevice::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +size_t RandomDevice::readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 RandomDevice::preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 RandomDevice::lseek(s64 offset, int whence) { + return 0; +} + +s64 RandomDevice::read(void* buf, size_t nbytes) { + auto rbuf = static_cast(buf); + for (size_t i = 0; i < nbytes; i++) + rbuf[i] = std::rand() & 0xFF; + return nbytes; +} + +int RandomDevice::fstat(Libraries::Kernel::OrbisKernelStat* sb) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s32 RandomDevice::fsync() { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int RandomDevice::ftruncate(s64 length) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int RandomDevice::getdents(void* buf, u32 nbytes, s64* basep) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s64 RandomDevice::pwrite(const void* buf, size_t nbytes, u64 offset) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +} // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/random.h b/src/core/devices/random.h new file mode 100644 index 000000000..3bbed1ca2 --- /dev/null +++ b/src/core/devices/random.h @@ -0,0 +1,33 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once +#include +#include "base_device.h" + +namespace Core::Devices { + +class RandomDevice final : BaseDevice { + u32 handle; + +public: + static std::shared_ptr Create(u32 handle, const char*, int, u16); + explicit RandomDevice(u32 handle) : handle(handle) {} + + ~RandomDevice() override = default; + + int ioctl(u64 cmd, Common::VaCtx* args) override; + s64 write(const void* buf, size_t nbytes) override; + size_t readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override; + size_t writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override; + s64 preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) override; + s64 lseek(s64 offset, int whence) override; + s64 read(void* buf, size_t nbytes) override; + int fstat(Libraries::Kernel::OrbisKernelStat* sb) override; + s32 fsync() override; + int ftruncate(s64 length) override; + int getdents(void* buf, u32 nbytes, s64* basep) override; + s64 pwrite(const void* buf, size_t nbytes, u64 offset) override; +}; + +} // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/srandom.cpp b/src/core/devices/srandom.cpp new file mode 100644 index 000000000..ff80adeaf --- /dev/null +++ b/src/core/devices/srandom.cpp @@ -0,0 +1,69 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later +#include +#include "common/logging/log.h" +#include "srandom.h" + +namespace Core::Devices { +std::shared_ptr SRandomDevice::Create(u32 handle, const char*, int, u16) { + std::srand(std::time(nullptr)); + return std::shared_ptr( + reinterpret_cast(new SRandomDevice(handle))); +} +int SRandomDevice::ioctl(u64 cmd, Common::VaCtx* args) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 SRandomDevice::write(const void* buf, size_t nbytes) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +size_t SRandomDevice::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +size_t SRandomDevice::readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 SRandomDevice::preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 SRandomDevice::lseek(s64 offset, int whence) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s64 SRandomDevice::read(void* buf, size_t nbytes) { + auto rbuf = static_cast(buf); + for (size_t i = 0; i < nbytes; i++) + rbuf[i] = std::rand(); + return nbytes; +} + +int SRandomDevice::fstat(Libraries::Kernel::OrbisKernelStat* sb) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s32 SRandomDevice::fsync() { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return s32(); +} + +int SRandomDevice::ftruncate(s64 length) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int SRandomDevice::getdents(void* buf, u32 nbytes, s64* basep) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s64 SRandomDevice::pwrite(const void* buf, size_t nbytes, u64 offset) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +} // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/srandom.h b/src/core/devices/srandom.h new file mode 100644 index 000000000..3a3b02571 --- /dev/null +++ b/src/core/devices/srandom.h @@ -0,0 +1,33 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once +#include +#include "base_device.h" + +namespace Core::Devices { + +class SRandomDevice final : BaseDevice { + u32 handle; + +public: + static std::shared_ptr Create(u32 handle, const char*, int, u16); + explicit SRandomDevice(u32 handle) : handle(handle) {} + + ~SRandomDevice() override = default; + + int ioctl(u64 cmd, Common::VaCtx* args) override; + s64 write(const void* buf, size_t nbytes) override; + size_t readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override; + size_t writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override; + s64 preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) override; + s64 lseek(s64 offset, int whence) override; + s64 read(void* buf, size_t nbytes) override; + int fstat(Libraries::Kernel::OrbisKernelStat* sb) override; + s32 fsync() override; + int ftruncate(s64 length) override; + int getdents(void* buf, u32 nbytes, s64* basep) override; + s64 pwrite(const void* buf, size_t nbytes, u64 offset) override; +}; + +} // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/urandom.cpp b/src/core/devices/urandom.cpp new file mode 100644 index 000000000..8917caea5 --- /dev/null +++ b/src/core/devices/urandom.cpp @@ -0,0 +1,71 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later +#include +#include "common/logging/log.h" +#include "urandom.h" + +namespace Core::Devices { + +std::shared_ptr URandomDevice::Create(u32 handle, const char*, int, u16) { + std::srand(std::time(nullptr)); + return std::shared_ptr( + reinterpret_cast(new URandomDevice(handle))); +} + +int URandomDevice::ioctl(u64 cmd, Common::VaCtx* args) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 URandomDevice::write(const void* buf, size_t nbytes) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +size_t URandomDevice::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +size_t URandomDevice::readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 URandomDevice::preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +s64 URandomDevice::lseek(s64 offset, int whence) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s64 URandomDevice::read(void* buf, size_t nbytes) { + auto rbuf = static_cast(buf); + for (size_t i = 0; i < nbytes; i++) + rbuf[i] = std::rand() & 0xFF; + return nbytes; +} + +int URandomDevice::fstat(Libraries::Kernel::OrbisKernelStat* sb) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s32 URandomDevice::fsync() { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int URandomDevice::ftruncate(s64 length) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +int URandomDevice::getdents(void* buf, u32 nbytes, s64* basep) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} + +s64 URandomDevice::pwrite(const void* buf, size_t nbytes, u64 offset) { + LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); + return 0; +} +} // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/urandom.h b/src/core/devices/urandom.h new file mode 100644 index 000000000..9370017d5 --- /dev/null +++ b/src/core/devices/urandom.h @@ -0,0 +1,33 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once +#include +#include "base_device.h" + +namespace Core::Devices { + +class URandomDevice final : BaseDevice { + u32 handle; + +public: + static std::shared_ptr Create(u32 handle, const char*, int, u16); + explicit URandomDevice(u32 handle) : handle(handle) {} + + ~URandomDevice() override = default; + + int ioctl(u64 cmd, Common::VaCtx* args) override; + s64 write(const void* buf, size_t nbytes) override; + size_t readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override; + size_t writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override; + s64 preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) override; + s64 lseek(s64 offset, int whence) override; + s64 read(void* buf, size_t nbytes) override; + int fstat(Libraries::Kernel::OrbisKernelStat* sb) override; + s32 fsync() override; + int ftruncate(s64 length) override; + int getdents(void* buf, u32 nbytes, s64* basep) override; + s64 pwrite(const void* buf, size_t nbytes, u64 offset) override; +}; + +} // namespace Core::Devices \ No newline at end of file diff --git a/src/core/libraries/kernel/file_system.cpp b/src/core/libraries/kernel/file_system.cpp index 2eb5d1621..ce91fe192 100644 --- a/src/core/libraries/kernel/file_system.cpp +++ b/src/core/libraries/kernel/file_system.cpp @@ -8,8 +8,13 @@ #include "common/logging/log.h" #include "common/scope_exit.h" #include "common/singleton.h" +#include "core/devices/deci_tty6.h" +#include "core/devices/dev_console.h" #include "core/devices/logger.h" #include "core/devices/nop_device.h" +#include "core/devices/random.h" +#include "core/devices/srandom.h" +#include "core/devices/urandom.h" #include "core/file_sys/fs.h" #include "core/libraries/kernel/file_system.h" #include "core/libraries/kernel/orbis_error.h" @@ -41,6 +46,12 @@ static std::map available_device = { {"/dev/deci_stderr", GET_DEVICE_FD(2)}, {"/dev/null", GET_DEVICE_FD(0)}, // fd0 (stdin) is a nop device + + {"/dev/urandom", &D::URandomDevice::Create }, + {"/dev/random", &D::RandomDevice::Create }, + {"/dev/srandom", &D::SRandomDevice::Create }, + {"/dev/console", &D::ConsoleDevice::Create }, + {"/dev/deci_tty6",&D::DeciTty6Device::Create } // clang-format on }; @@ -67,17 +78,6 @@ int PS4_SYSV_ABI sceKernelOpen(const char* raw_path, int flags, u16 mode) { bool directory = (flags & ORBIS_KERNEL_O_DIRECTORY) != 0; std::string_view path{raw_path}; - - if (path == "/dev/console") { - return 2000; - } - if (path == "/dev/deci_tty6") { - return 2001; - } - if (path == "/dev/urandom") { - return 2003; - } - u32 handle = h->CreateHandle(); auto* file = h->GetFile(handle); @@ -167,9 +167,6 @@ int PS4_SYSV_ABI sceKernelClose(int d) { if (d < 3) { // d probably hold an error code return ORBIS_KERNEL_ERROR_EPERM; } - if (d == 2003) { // dev/urandom case - return ORBIS_OK; - } auto* h = Common::Singleton::Instance(); auto* file = h->GetFile(d); if (file == nullptr) { @@ -337,13 +334,6 @@ s64 PS4_SYSV_ABI posix_lseek(int d, s64 offset, int whence) { } s64 PS4_SYSV_ABI sceKernelRead(int d, void* buf, size_t nbytes) { - if (d == 2003) // dev urandom case - { - auto rbuf = static_cast(buf); - for (size_t i = 0; i < nbytes; i++) - rbuf[i] = std::rand() & 0xFF; - return nbytes; - } auto* h = Common::Singleton::Instance(); auto* file = h->GetFile(d); if (file == nullptr) { @@ -757,7 +747,6 @@ s32 PS4_SYSV_ABI sceKernelRename(const char* from, const char* to) { } void RegisterFileSystem(Core::Loader::SymbolsResolver* sym) { - std::srand(std::time(nullptr)); LIB_FUNCTION("1G3lF1Gg1k8", "libkernel", 1, "libkernel", 1, 1, sceKernelOpen); LIB_FUNCTION("wuCroIGjt2g", "libScePosix", 1, "libkernel", 1, 1, posix_open); LIB_FUNCTION("wuCroIGjt2g", "libkernel", 1, "libkernel", 1, 1, open); From c8bbecda2654e4cb0825cfce396942142ab3d19f Mon Sep 17 00:00:00 2001 From: DanielSvoboda Date: Sun, 19 Jan 2025 12:45:24 -0300 Subject: [PATCH 20/99] Devtools: Close Button ( X ) (#2187) --- src/core/devtools/layer.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/core/devtools/layer.cpp b/src/core/devtools/layer.cpp index c652849e7..a6d99b49b 100644 --- a/src/core/devtools/layer.cpp +++ b/src/core/devtools/layer.cpp @@ -93,6 +93,12 @@ void L::DrawMenuBar() { } ImGui::EndMenu(); } + + SameLine(ImGui::GetWindowWidth() - 30.0f); + if (Button("X", ImVec2(25, 25))) { + DebugState.IsShowingDebugMenuBar() = false; + } + EndMainMenuBar(); } From 17ac63d23a4abd046854a852642bd093a28108d7 Mon Sep 17 00:00:00 2001 From: DanielSvoboda Date: Sun, 19 Jan 2025 12:47:40 -0300 Subject: [PATCH 21/99] Fix SurfaceFormat (#2188) --- src/video_core/renderer_vulkan/liverpool_to_vk.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/video_core/renderer_vulkan/liverpool_to_vk.cpp b/src/video_core/renderer_vulkan/liverpool_to_vk.cpp index 9695e127f..4ac8d5cc8 100644 --- a/src/video_core/renderer_vulkan/liverpool_to_vk.cpp +++ b/src/video_core/renderer_vulkan/liverpool_to_vk.cpp @@ -612,7 +612,7 @@ std::span SurfaceFormats() { vk::Format::eB5G6R5UnormPack16), // 1_5_5_5 CreateSurfaceFormatInfo(AmdGpu::DataFormat::Format1_5_5_5, AmdGpu::NumberFormat::Unorm, - vk::Format::eR5G5B5A1UnormPack16), + vk::Format::eA1B5G5R5UnormPack16), // 5_5_5_1 - Remapped to 1_5_5_5. // 4_4_4_4 CreateSurfaceFormatInfo(AmdGpu::DataFormat::Format4_4_4_4, AmdGpu::NumberFormat::Unorm, From 201f2817ca929d54460bfd5e18d3a23b0cad65c5 Mon Sep 17 00:00:00 2001 From: DanielSvoboda Date: Sun, 19 Jan 2025 18:55:27 -0300 Subject: [PATCH 22/99] Fix SurfaceFormat Format1_5_5_5 - Format5_5_5_1 (#2191) * Fix SurfaceFormat Format1_5_5_5 - again * Fix Format5_5_5_1 --- src/video_core/amdgpu/types.h | 11 +++++++++-- src/video_core/renderer_vulkan/liverpool_to_vk.cpp | 6 ++++-- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/src/video_core/amdgpu/types.h b/src/video_core/amdgpu/types.h index 57f97418a..63e184cc5 100644 --- a/src/video_core/amdgpu/types.h +++ b/src/video_core/amdgpu/types.h @@ -283,8 +283,7 @@ inline CompMapping RemapSwizzle(const DataFormat format, const CompMapping swizz result.a = swizzle.a; return result; } - case DataFormat::Format10_10_10_2: - case DataFormat::Format5_5_5_1: { + case DataFormat::Format10_10_10_2: { CompMapping result; result.r = swizzle.a; result.g = swizzle.b; @@ -292,6 +291,14 @@ inline CompMapping RemapSwizzle(const DataFormat format, const CompMapping swizz result.a = swizzle.r; return result; } + case DataFormat::Format1_5_5_5: { + CompMapping result; + result.r = swizzle.b; + result.g = swizzle.g; + result.b = swizzle.r; + result.a = swizzle.a; + return result; + } default: return swizzle; } diff --git a/src/video_core/renderer_vulkan/liverpool_to_vk.cpp b/src/video_core/renderer_vulkan/liverpool_to_vk.cpp index 4ac8d5cc8..35585edb7 100644 --- a/src/video_core/renderer_vulkan/liverpool_to_vk.cpp +++ b/src/video_core/renderer_vulkan/liverpool_to_vk.cpp @@ -612,8 +612,10 @@ std::span SurfaceFormats() { vk::Format::eB5G6R5UnormPack16), // 1_5_5_5 CreateSurfaceFormatInfo(AmdGpu::DataFormat::Format1_5_5_5, AmdGpu::NumberFormat::Unorm, - vk::Format::eA1B5G5R5UnormPack16), - // 5_5_5_1 - Remapped to 1_5_5_5. + vk::Format::eA1R5G5B5UnormPack16), + // 5_5_5_1 + CreateSurfaceFormatInfo(AmdGpu::DataFormat::Format5_5_5_1, AmdGpu::NumberFormat::Unorm, + vk::Format::eR5G5B5A1UnormPack16), // 4_4_4_4 CreateSurfaceFormatInfo(AmdGpu::DataFormat::Format4_4_4_4, AmdGpu::NumberFormat::Unorm, vk::Format::eR4G4B4A4UnormPack16), From 80092b6367e1aa230fb6e72fb304a0828061d409 Mon Sep 17 00:00:00 2001 From: DanielSvoboda Date: Sun, 19 Jan 2025 20:09:10 -0300 Subject: [PATCH 23/99] Fix SurfaceFormat Format4_4_4_4 (#2193) * Fix SurfaceFormat Format4_4_4_4 Pac-Man 256 * add_extension --- src/video_core/renderer_vulkan/liverpool_to_vk.cpp | 2 +- src/video_core/renderer_vulkan/vk_instance.cpp | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/video_core/renderer_vulkan/liverpool_to_vk.cpp b/src/video_core/renderer_vulkan/liverpool_to_vk.cpp index 35585edb7..f2fbc6530 100644 --- a/src/video_core/renderer_vulkan/liverpool_to_vk.cpp +++ b/src/video_core/renderer_vulkan/liverpool_to_vk.cpp @@ -618,7 +618,7 @@ std::span SurfaceFormats() { vk::Format::eR5G5B5A1UnormPack16), // 4_4_4_4 CreateSurfaceFormatInfo(AmdGpu::DataFormat::Format4_4_4_4, AmdGpu::NumberFormat::Unorm, - vk::Format::eR4G4B4A4UnormPack16), + vk::Format::eA4B4G4R4UnormPack16), // 8_24 // 24_8 // X24_8_32 diff --git a/src/video_core/renderer_vulkan/vk_instance.cpp b/src/video_core/renderer_vulkan/vk_instance.cpp index 5efdf4127..d183d6b09 100644 --- a/src/video_core/renderer_vulkan/vk_instance.cpp +++ b/src/video_core/renderer_vulkan/vk_instance.cpp @@ -283,6 +283,7 @@ bool Instance::CreateDevice() { add_extension(VK_EXT_SHADER_DEMOTE_TO_HELPER_INVOCATION_EXTENSION_NAME); add_extension(VK_KHR_SYNCHRONIZATION_2_EXTENSION_NAME); add_extension(VK_EXT_EXTENDED_DYNAMIC_STATE_EXTENSION_NAME); + add_extension(VK_EXT_4444_FORMATS_EXTENSION_NAME); #ifdef __APPLE__ // Required by Vulkan spec if supported. From d14e57f6a8bf327db8a032382fcaefa0b441fd1c Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sun, 19 Jan 2025 18:45:34 -0800 Subject: [PATCH 24/99] hotfix: Move some command buffer references down. Prevents references becoming stale due to stream buffer flushes. --- src/video_core/buffer_cache/buffer_cache.cpp | 2 +- src/video_core/texture_cache/texture_cache.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/video_core/buffer_cache/buffer_cache.cpp b/src/video_core/buffer_cache/buffer_cache.cpp index 487544a21..11ad0e96f 100644 --- a/src/video_core/buffer_cache/buffer_cache.cpp +++ b/src/video_core/buffer_cache/buffer_cache.cpp @@ -210,7 +210,6 @@ void BufferCache::InlineData(VAddr address, const void* value, u32 num_bytes, bo return; } scheduler.EndRendering(); - const auto cmdbuf = scheduler.CommandBuffer(); const Buffer* buffer = [&] { if (is_gds) { return &gds_buffer; @@ -218,6 +217,7 @@ void BufferCache::InlineData(VAddr address, const void* value, u32 num_bytes, bo const BufferId buffer_id = FindBuffer(address, num_bytes); return &slot_buffers[buffer_id]; }(); + const auto cmdbuf = scheduler.CommandBuffer(); const vk::BufferMemoryBarrier2 pre_barrier = { .srcStageMask = vk::PipelineStageFlagBits2::eAllCommands, .srcAccessMask = vk::AccessFlagBits2::eMemoryRead, diff --git a/src/video_core/texture_cache/texture_cache.cpp b/src/video_core/texture_cache/texture_cache.cpp index a281b89c9..5947db864 100644 --- a/src/video_core/texture_cache/texture_cache.cpp +++ b/src/video_core/texture_cache/texture_cache.cpp @@ -545,12 +545,12 @@ void TextureCache::RefreshImage(Image& image, Vulkan::Scheduler* custom_schedule auto* sched_ptr = custom_scheduler ? custom_scheduler : &scheduler; sched_ptr->EndRendering(); - const auto cmdbuf = sched_ptr->CommandBuffer(); const VAddr image_addr = image.info.guest_address; const size_t image_size = image.info.guest_size; const auto [vk_buffer, buf_offset] = buffer_cache.ObtainViewBuffer(image_addr, image_size, is_gpu_dirty); + const auto cmdbuf = sched_ptr->CommandBuffer(); // The obtained buffer may be written by a shader so we need to emit a barrier to prevent RAW // hazard if (auto barrier = vk_buffer->GetBarrier(vk::AccessFlagBits2::eTransferRead, From 4fa501c8d525a6afa3ae36134b26e2dc8007a24e Mon Sep 17 00:00:00 2001 From: Stephen Miller <56742918+StevenMiller123@users.noreply.github.com> Date: Sun, 19 Jan 2025 21:12:42 -0600 Subject: [PATCH 25/99] Additional libSceNpManager functions and cleanup (#2195) * Error return on sceNpGetAccountIdA Confirmed through hardware testing, this returns ORBIS_NP_ERROR_SIGNED_OUT on a signed out console. Parameters are based on fpPS4 code. * Fix compile * Move errors to separate file * Cleanup function headers Swaps user_ids to use our OrbisUserServiceUserId type, and fixes parameter names to align with our coding standards. * Add proper parameter checks * Implement sceNpGetAccountId This function takes an online_id, uses an NpManager function to get the user_id, then uses that user_id to perform the same internal functions as sceNpGetAccountIdA. * Implement sceNpHasSignedUp * Fix sceNpGetAccountId Further hardware testing shows that these always write 0 to account_id when failing. * Update np_manager.cpp --- src/core/libraries/np_manager/np_manager.cpp | 42 ++++++++++++++----- src/core/libraries/np_manager/np_manager.h | 14 +++---- .../libraries/np_manager/np_manager_error.h | 9 ++++ 3 files changed, 47 insertions(+), 18 deletions(-) create mode 100644 src/core/libraries/np_manager/np_manager_error.h diff --git a/src/core/libraries/np_manager/np_manager.cpp b/src/core/libraries/np_manager/np_manager.cpp index e26c5a830..a60dcd86f 100644 --- a/src/core/libraries/np_manager/np_manager.cpp +++ b/src/core/libraries/np_manager/np_manager.cpp @@ -5,6 +5,7 @@ #include "core/libraries/error_codes.h" #include "core/libraries/libs.h" #include "core/libraries/np_manager/np_manager.h" +#include "core/libraries/np_manager/np_manager_error.h" #include "core/tls.h" namespace Libraries::NpManager { @@ -935,14 +936,22 @@ int PS4_SYSV_ABI sceNpGetAccountDateOfBirthA() { return ORBIS_OK; } -int PS4_SYSV_ABI sceNpGetAccountId() { - LOG_ERROR(Lib_NpManager, "(STUBBED) called"); - return ORBIS_OK; +int PS4_SYSV_ABI sceNpGetAccountId(OrbisNpOnlineId* online_id, u64* account_id) { + LOG_DEBUG(Lib_NpManager, "called"); + if (online_id == nullptr || account_id == nullptr) { + return ORBIS_NP_ERROR_INVALID_ARGUMENT; + } + *account_id = 0; + return ORBIS_NP_ERROR_SIGNED_OUT; } -int PS4_SYSV_ABI sceNpGetAccountIdA() { - LOG_ERROR(Lib_NpManager, "(STUBBED) called"); - return ORBIS_OK; +int PS4_SYSV_ABI sceNpGetAccountIdA(OrbisUserServiceUserId user_id, u64* account_id) { + LOG_DEBUG(Lib_NpManager, "user_id {}", user_id); + if (account_id == nullptr) { + return ORBIS_NP_ERROR_INVALID_ARGUMENT; + } + *account_id = 0; + return ORBIS_NP_ERROR_SIGNED_OUT; } int PS4_SYSV_ABI sceNpGetAccountLanguage() { @@ -972,6 +981,9 @@ int PS4_SYSV_ABI sceNpGetGamePresenceStatusA() { int PS4_SYSV_ABI sceNpGetNpId(OrbisUserServiceUserId user_id, OrbisNpId* np_id) { LOG_DEBUG(Lib_NpManager, "user_id {}", user_id); + if (np_id == nullptr) { + return ORBIS_NP_ERROR_INVALID_ARGUMENT; + } return ORBIS_NP_ERROR_SIGNED_OUT; } @@ -980,8 +992,11 @@ int PS4_SYSV_ABI sceNpGetNpReachabilityState() { return ORBIS_OK; } -int PS4_SYSV_ABI sceNpGetOnlineId(s32 user_id, OrbisNpOnlineId* online_id) { +int PS4_SYSV_ABI sceNpGetOnlineId(OrbisUserServiceUserId user_id, OrbisNpOnlineId* online_id) { LOG_DEBUG(Lib_NpManager, "user_id {}", user_id); + if (online_id == nullptr) { + return ORBIS_NP_ERROR_INVALID_ARGUMENT; + } return ORBIS_NP_ERROR_SIGNED_OUT; } @@ -995,7 +1010,10 @@ int PS4_SYSV_ABI sceNpGetParentalControlInfoA() { return ORBIS_OK; } -int PS4_SYSV_ABI sceNpGetState(s32 userId, OrbisNpState* state) { +int PS4_SYSV_ABI sceNpGetState(OrbisUserServiceUserId user_id, OrbisNpState* state) { + if (state == nullptr) { + return ORBIS_NP_ERROR_INVALID_ARGUMENT; + } *state = OrbisNpState::SignedOut; LOG_DEBUG(Lib_NpManager, "Signed out"); return ORBIS_OK; @@ -1011,8 +1029,12 @@ int PS4_SYSV_ABI sceNpGetUserIdByOnlineId() { return ORBIS_OK; } -int PS4_SYSV_ABI sceNpHasSignedUp() { - LOG_ERROR(Lib_NpManager, "(STUBBED) called"); +int PS4_SYSV_ABI sceNpHasSignedUp(OrbisUserServiceUserId user_id, bool* has_signed_up) { + LOG_DEBUG(Lib_NpManager, "called"); + if (has_signed_up == nullptr) { + return ORBIS_NP_ERROR_INVALID_ARGUMENT; + } + *has_signed_up = false; return ORBIS_OK; } diff --git a/src/core/libraries/np_manager/np_manager.h b/src/core/libraries/np_manager/np_manager.h index 6ba588e5e..02a1a32f6 100644 --- a/src/core/libraries/np_manager/np_manager.h +++ b/src/core/libraries/np_manager/np_manager.h @@ -11,8 +11,6 @@ class SymbolsResolver; namespace Libraries::NpManager { -constexpr int ORBIS_NP_ERROR_SIGNED_OUT = 0x80550006; - enum class OrbisNpState : u32 { Unknown = 0, SignedOut, SignedIn }; using OrbisNpStateCallbackForNpToolkit = PS4_SYSV_ABI void (*)(s32 userId, OrbisNpState state, @@ -220,22 +218,22 @@ int PS4_SYSV_ABI sceNpGetAccountCountry(); int PS4_SYSV_ABI sceNpGetAccountCountryA(); int PS4_SYSV_ABI sceNpGetAccountDateOfBirth(); int PS4_SYSV_ABI sceNpGetAccountDateOfBirthA(); -int PS4_SYSV_ABI sceNpGetAccountId(); -int PS4_SYSV_ABI sceNpGetAccountIdA(); +int PS4_SYSV_ABI sceNpGetAccountId(OrbisNpOnlineId* online_id, u64* account_id); +int PS4_SYSV_ABI sceNpGetAccountIdA(OrbisUserServiceUserId user_id, u64* account_id); int PS4_SYSV_ABI sceNpGetAccountLanguage(); int PS4_SYSV_ABI sceNpGetAccountLanguage2(); int PS4_SYSV_ABI sceNpGetAccountLanguageA(); int PS4_SYSV_ABI sceNpGetGamePresenceStatus(); int PS4_SYSV_ABI sceNpGetGamePresenceStatusA(); -int PS4_SYSV_ABI sceNpGetNpId(OrbisUserServiceUserId userId, OrbisNpId* npId); +int PS4_SYSV_ABI sceNpGetNpId(OrbisUserServiceUserId user_id, OrbisNpId* np_id); int PS4_SYSV_ABI sceNpGetNpReachabilityState(); -int PS4_SYSV_ABI sceNpGetOnlineId(s32 userId, OrbisNpOnlineId* onlineId); +int PS4_SYSV_ABI sceNpGetOnlineId(OrbisUserServiceUserId user_id, OrbisNpOnlineId* online_id); int PS4_SYSV_ABI sceNpGetParentalControlInfo(); int PS4_SYSV_ABI sceNpGetParentalControlInfoA(); -int PS4_SYSV_ABI sceNpGetState(s32 userId, OrbisNpState* state); +int PS4_SYSV_ABI sceNpGetState(OrbisUserServiceUserId user_id, OrbisNpState* state); int PS4_SYSV_ABI sceNpGetUserIdByAccountId(); int PS4_SYSV_ABI sceNpGetUserIdByOnlineId(); -int PS4_SYSV_ABI sceNpHasSignedUp(); +int PS4_SYSV_ABI sceNpHasSignedUp(OrbisUserServiceUserId user_id, bool* has_signed_up); int PS4_SYSV_ABI sceNpIdMapperAbortRequest(); int PS4_SYSV_ABI sceNpIdMapperAccountIdToNpId(); int PS4_SYSV_ABI sceNpIdMapperAccountIdToOnlineId(); diff --git a/src/core/libraries/np_manager/np_manager_error.h b/src/core/libraries/np_manager/np_manager_error.h new file mode 100644 index 000000000..4af0d08ef --- /dev/null +++ b/src/core/libraries/np_manager/np_manager_error.h @@ -0,0 +1,9 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#include "core/libraries/error_codes.h" + +constexpr int ORBIS_NP_ERROR_INVALID_ARGUMENT = 0x80550003; +constexpr int ORBIS_NP_ERROR_SIGNED_OUT = 0x80550006; \ No newline at end of file From 0f93edb377f50dcb462427cdda0eb9939f37de31 Mon Sep 17 00:00:00 2001 From: Stephen Miller <56742918+StevenMiller123@users.noreply.github.com> Date: Sun, 19 Jan 2025 21:20:51 -0600 Subject: [PATCH 26/99] Implement IMAGE_ATOMIC_SWAP (#2194) We already handle everything for this opcode in our IMAGE_ATOMIC function, so implementing this is fairly simple. Should improve Wipeout 3. --- src/shader_recompiler/frontend/format.cpp | 4 ++-- src/shader_recompiler/frontend/translate/vector_memory.cpp | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/shader_recompiler/frontend/format.cpp b/src/shader_recompiler/frontend/format.cpp index 9677be3e5..2fcac7c10 100644 --- a/src/shader_recompiler/frontend/format.cpp +++ b/src/shader_recompiler/frontend/format.cpp @@ -3420,8 +3420,8 @@ constexpr std::array InstructionFormatMIMG = {{ {InstClass::VectorMemImgUt, InstCategory::VectorMemory, 4, 1, ScalarType::Uint32, ScalarType::Uint32}, // 15 = IMAGE_ATOMIC_SWAP - {InstClass::VectorMemImgNoSmp, InstCategory::VectorMemory, 4, 1, ScalarType::Undefined, - ScalarType::Undefined}, + {InstClass::VectorMemImgNoSmp, InstCategory::VectorMemory, 4, 1, ScalarType::Uint32, + ScalarType::Uint32}, // 16 = IMAGE_ATOMIC_CMPSWAP {InstClass::VectorMemImgNoSmp, InstCategory::VectorMemory, 4, 1, ScalarType::Undefined, ScalarType::Undefined}, diff --git a/src/shader_recompiler/frontend/translate/vector_memory.cpp b/src/shader_recompiler/frontend/translate/vector_memory.cpp index 8fa0f3f87..685785af1 100644 --- a/src/shader_recompiler/frontend/translate/vector_memory.cpp +++ b/src/shader_recompiler/frontend/translate/vector_memory.cpp @@ -107,6 +107,8 @@ void Translator::EmitVectorMemory(const GcnInst& inst) { return IMAGE_GET_RESINFO(inst); // Image atomic operations + case Opcode::IMAGE_ATOMIC_SWAP: + return IMAGE_ATOMIC(AtomicOp::Swap, inst); case Opcode::IMAGE_ATOMIC_ADD: return IMAGE_ATOMIC(AtomicOp::Add, inst); case Opcode::IMAGE_ATOMIC_SMIN: From e1132db197def956132f08870258a1f8c21e9c99 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sun, 19 Jan 2025 23:33:37 -0800 Subject: [PATCH 27/99] texture_cache: Prevent unregistered images from being tracked. (#2196) --- src/video_core/texture_cache/texture_cache.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/video_core/texture_cache/texture_cache.cpp b/src/video_core/texture_cache/texture_cache.cpp index 5947db864..798ecf030 100644 --- a/src/video_core/texture_cache/texture_cache.cpp +++ b/src/video_core/texture_cache/texture_cache.cpp @@ -643,6 +643,9 @@ void TextureCache::UnregisterImage(ImageId image_id) { void TextureCache::TrackImage(ImageId image_id) { auto& image = slot_images[image_id]; + if (!(image.flags & ImageFlagBits::Registered)) { + return; + } const auto image_begin = image.info.guest_address; const auto image_end = image.info.guest_address + image.info.guest_size; if (image_begin == image.track_addr && image_end == image.track_addr_end) { @@ -666,6 +669,9 @@ void TextureCache::TrackImage(ImageId image_id) { void TextureCache::TrackImageHead(ImageId image_id) { auto& image = slot_images[image_id]; + if (!(image.flags & ImageFlagBits::Registered)) { + return; + } const auto image_begin = image.info.guest_address; if (image_begin == image.track_addr) { return; @@ -678,6 +684,9 @@ void TextureCache::TrackImageHead(ImageId image_id) { void TextureCache::TrackImageTail(ImageId image_id) { auto& image = slot_images[image_id]; + if (!(image.flags & ImageFlagBits::Registered)) { + return; + } const auto image_end = image.info.guest_address + image.info.guest_size; if (image_end == image.track_addr_end) { return; From a3967ccdb43ebe5c8005dd35e72825497abbbb3d Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Mon, 20 Jan 2025 04:48:32 -0800 Subject: [PATCH 28/99] externals: Update vulkan-headers (#2197) --- CMakeLists.txt | 2 +- externals/vulkan-headers | 2 +- src/video_core/renderer_vulkan/vk_platform.cpp | 12 ++++++------ 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e5c16bd1b..918a1acb7 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -120,7 +120,7 @@ find_package(SDL3 3.1.2 CONFIG) find_package(stb MODULE) find_package(toml11 4.2.0 CONFIG) find_package(tsl-robin-map 1.3.0 CONFIG) -find_package(VulkanHeaders 1.4.303 CONFIG) +find_package(VulkanHeaders 1.4.305 CONFIG) find_package(VulkanMemoryAllocator 3.1.0 CONFIG) find_package(xbyak 7.07 CONFIG) find_package(xxHash 0.8.2 MODULE) diff --git a/externals/vulkan-headers b/externals/vulkan-headers index 6a74a7d65..a03d2f6d5 160000 --- a/externals/vulkan-headers +++ b/externals/vulkan-headers @@ -1 +1 @@ -Subproject commit 6a74a7d65cafa19e38ec116651436cce6efd5b2e +Subproject commit a03d2f6d5753b365d704d58161825890baad0755 diff --git a/src/video_core/renderer_vulkan/vk_platform.cpp b/src/video_core/renderer_vulkan/vk_platform.cpp index fdd590e9d..07ebfbda6 100644 --- a/src/video_core/renderer_vulkan/vk_platform.cpp +++ b/src/video_core/renderer_vulkan/vk_platform.cpp @@ -28,19 +28,19 @@ static const char* const VALIDATION_LAYER_NAME = "VK_LAYER_KHRONOS_validation"; static const char* const CRASH_DIAGNOSTIC_LAYER_NAME = "VK_LAYER_LUNARG_crash_diagnostic"; static VKAPI_ATTR VkBool32 VKAPI_CALL DebugUtilsCallback( - VkDebugUtilsMessageSeverityFlagBitsEXT severity, VkDebugUtilsMessageTypeFlagsEXT type, - const VkDebugUtilsMessengerCallbackDataEXT* callback_data, void* user_data) { + vk::DebugUtilsMessageSeverityFlagBitsEXT severity, vk::DebugUtilsMessageTypeFlagsEXT type, + const vk::DebugUtilsMessengerCallbackDataEXT* callback_data, void* user_data) { Common::Log::Level level{}; switch (severity) { - case VK_DEBUG_UTILS_MESSAGE_SEVERITY_ERROR_BIT_EXT: + case vk::DebugUtilsMessageSeverityFlagBitsEXT::eError: level = Common::Log::Level::Error; break; - case VK_DEBUG_UTILS_MESSAGE_SEVERITY_WARNING_BIT_EXT: + case vk::DebugUtilsMessageSeverityFlagBitsEXT::eWarning: level = Common::Log::Level::Info; break; - case VK_DEBUG_UTILS_MESSAGE_SEVERITY_INFO_BIT_EXT: - case VK_DEBUG_UTILS_MESSAGE_SEVERITY_VERBOSE_BIT_EXT: + case vk::DebugUtilsMessageSeverityFlagBitsEXT::eInfo: + case vk::DebugUtilsMessageSeverityFlagBitsEXT::eVerbose: level = Common::Log::Level::Debug; break; default: From 95a30b2b3e1aa4e20c3db632955cc67bbded0fb1 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Mon, 20 Jan 2025 13:38:09 -0800 Subject: [PATCH 29/99] texture_cache: Lock when updating image. (#2198) --- src/video_core/texture_cache/texture_cache.cpp | 6 ++---- src/video_core/texture_cache/texture_cache.h | 1 + 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/video_core/texture_cache/texture_cache.cpp b/src/video_core/texture_cache/texture_cache.cpp index 798ecf030..04711539c 100644 --- a/src/video_core/texture_cache/texture_cache.cpp +++ b/src/video_core/texture_cache/texture_cache.cpp @@ -60,15 +60,13 @@ void TextureCache::MarkAsMaybeDirty(ImageId image_id, Image& image) { void TextureCache::InvalidateMemory(VAddr addr, size_t size) { std::scoped_lock lock{mutex}; - const auto end = addr + size; const auto pages_start = PageManager::GetPageAddr(addr); const auto pages_end = PageManager::GetNextPageAddr(addr + size - 1); ForEachImageInRegion(pages_start, pages_end - pages_start, [&](ImageId image_id, Image& image) { const auto image_begin = image.info.guest_address; const auto image_end = image.info.guest_address + image.info.guest_size; - if (image_begin < end && addr < image_end) { - // Start or end of the modified region is in the image, or the image is entirely within - // the modified region, so the image was definitely accessed by this page fault. + if (image.Overlaps(addr, size)) { + // Modified region overlaps image, so the image was definitely accessed by this fault. // Untrack the image, so that the range is unprotected and the guest can write freely. image.flags |= ImageFlagBits::CpuDirty; UntrackImage(image_id); diff --git a/src/video_core/texture_cache/texture_cache.h b/src/video_core/texture_cache/texture_cache.h index 343a510e6..f262768ea 100644 --- a/src/video_core/texture_cache/texture_cache.h +++ b/src/video_core/texture_cache/texture_cache.h @@ -118,6 +118,7 @@ public: /// Updates image contents if it was modified by CPU. void UpdateImage(ImageId image_id, Vulkan::Scheduler* custom_scheduler = nullptr) { + std::scoped_lock lock{mutex}; Image& image = slot_images[image_id]; TrackImage(image_id); RefreshImage(image, custom_scheduler); From 3563b88d8c9b72474460233b13e4b28ac93e8bc1 Mon Sep 17 00:00:00 2001 From: polyproxy <47796739+polybiusproxy@users.noreply.github.com> Date: Tue, 21 Jan 2025 19:28:39 +0100 Subject: [PATCH 30/99] hotfix: use logger device on stdin --- CMakeLists.txt | 20 +++++++++---------- src/core/devices/base_device.cpp | 4 ++-- src/core/devices/base_device.h | 4 ++-- .../{dev_console.cpp => console_device.cpp} | 13 +++++++++--- .../{dev_console.h => console_device.h} | 4 ++-- .../{deci_tty6.cpp => deci_tty6_device.cpp} | 14 ++++++++++--- .../{deci_tty6.h => deci_tty6_device.h} | 4 ++-- src/core/devices/ioccom.h | 4 ++-- src/core/devices/logger.cpp | 8 +++++--- src/core/devices/logger.h | 4 ++-- src/core/devices/nop_device.h | 17 +++++++++++++--- .../devices/{random.cpp => random_device.cpp} | 18 +++++++++++++---- .../devices/{random.h => random_device.h} | 4 ++-- .../{srandom.cpp => srandom_device.cpp} | 18 +++++++++++++---- .../devices/{srandom.h => srandom_device.h} | 4 ++-- .../{urandom.cpp => urandom_device.cpp} | 16 +++++++++++---- .../devices/{urandom.h => urandom_device.h} | 4 ++-- src/core/file_sys/fs.cpp | 2 +- src/core/libraries/kernel/file_system.cpp | 17 +++++----------- 19 files changed, 114 insertions(+), 65 deletions(-) rename src/core/devices/{dev_console.cpp => console_device.cpp} (92%) rename src/core/devices/{dev_console.h => console_device.h} (90%) rename src/core/devices/{deci_tty6.cpp => deci_tty6_device.cpp} (92%) rename src/core/devices/{deci_tty6.h => deci_tty6_device.h} (90%) rename src/core/devices/{random.cpp => random_device.cpp} (90%) rename src/core/devices/{random.h => random_device.h} (90%) rename src/core/devices/{srandom.cpp => srandom_device.cpp} (90%) rename src/core/devices/{srandom.h => srandom_device.h} (90%) rename src/core/devices/{urandom.cpp => urandom_device.cpp} (90%) rename src/core/devices/{urandom.h => urandom_device.h} (90%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 918a1acb7..131809c8e 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -557,16 +557,16 @@ set(CORE src/core/aerolib/stubs.cpp src/core/devices/logger.cpp src/core/devices/logger.h src/core/devices/nop_device.h - src/core/devices/dev_console.cpp - src/core/devices/dev_console.h - src/core/devices/deci_tty6.cpp - src/core/devices/deci_tty6.h - src/core/devices/random.cpp - src/core/devices/random.h - src/core/devices/urandom.cpp - src/core/devices/urandom.h - src/core/devices/srandom.cpp - src/core/devices/srandom.h + src/core/devices/console_device.cpp + src/core/devices/console_device.h + src/core/devices/deci_tty6_device.cpp + src/core/devices/deci_tty6_device.h + src/core/devices/random_device.cpp + src/core/devices/random_device.h + src/core/devices/urandom_device.cpp + src/core/devices/urandom_device.h + src/core/devices/srandom_device.cpp + src/core/devices/srandom_device.h src/core/file_format/pfs.h src/core/file_format/pkg.cpp src/core/file_format/pkg.h diff --git a/src/core/devices/base_device.cpp b/src/core/devices/base_device.cpp index 4f91c81c7..fc2a98a29 100644 --- a/src/core/devices/base_device.cpp +++ b/src/core/devices/base_device.cpp @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #include "base_device.h" diff --git a/src/core/devices/base_device.h b/src/core/devices/base_device.h index 351af82b4..36614b8f4 100644 --- a/src/core/devices/base_device.h +++ b/src/core/devices/base_device.h @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once diff --git a/src/core/devices/dev_console.cpp b/src/core/devices/console_device.cpp similarity index 92% rename from src/core/devices/dev_console.cpp rename to src/core/devices/console_device.cpp index 0ddcfd040..f109cadb9 100644 --- a/src/core/devices/dev_console.cpp +++ b/src/core/devices/console_device.cpp @@ -1,34 +1,41 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #include "common/logging/log.h" -#include "dev_console.h" +#include "console_device.h" namespace Core::Devices { + std::shared_ptr ConsoleDevice::Create(u32 handle, const char*, int, u16) { return std::shared_ptr( reinterpret_cast(new ConsoleDevice(handle))); } + int ConsoleDevice::ioctl(u64 cmd, Common::VaCtx* args) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 ConsoleDevice::write(const void* buf, size_t nbytes) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + size_t ConsoleDevice::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + size_t ConsoleDevice::readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 ConsoleDevice::preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 ConsoleDevice::lseek(s64 offset, int whence) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; diff --git a/src/core/devices/dev_console.h b/src/core/devices/console_device.h similarity index 90% rename from src/core/devices/dev_console.h rename to src/core/devices/console_device.h index f280200e2..d4b590ba0 100644 --- a/src/core/devices/dev_console.h +++ b/src/core/devices/console_device.h @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once #include diff --git a/src/core/devices/deci_tty6.cpp b/src/core/devices/deci_tty6_device.cpp similarity index 92% rename from src/core/devices/deci_tty6.cpp rename to src/core/devices/deci_tty6_device.cpp index 20423de61..e7a5fd4fc 100644 --- a/src/core/devices/deci_tty6.cpp +++ b/src/core/devices/deci_tty6_device.cpp @@ -1,34 +1,41 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #include "common/logging/log.h" -#include "deci_tty6.h" +#include "deci_tty6_device.h" namespace Core::Devices { + std::shared_ptr DeciTty6Device::Create(u32 handle, const char*, int, u16) { return std::shared_ptr( reinterpret_cast(new DeciTty6Device(handle))); } + int DeciTty6Device::ioctl(u64 cmd, Common::VaCtx* args) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 DeciTty6Device::write(const void* buf, size_t nbytes) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + size_t DeciTty6Device::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + size_t DeciTty6Device::readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 DeciTty6Device::preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 DeciTty6Device::lseek(s64 offset, int whence) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; @@ -63,4 +70,5 @@ s64 DeciTty6Device::pwrite(const void* buf, size_t nbytes, u64 offset) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + } // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/deci_tty6.h b/src/core/devices/deci_tty6_device.h similarity index 90% rename from src/core/devices/deci_tty6.h rename to src/core/devices/deci_tty6_device.h index 71cbfba6b..b8bd48556 100644 --- a/src/core/devices/deci_tty6.h +++ b/src/core/devices/deci_tty6_device.h @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once #include diff --git a/src/core/devices/ioccom.h b/src/core/devices/ioccom.h index 671ee33d4..2ded90bd8 100644 --- a/src/core/devices/ioccom.h +++ b/src/core/devices/ioccom.h @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once diff --git a/src/core/devices/logger.cpp b/src/core/devices/logger.cpp index 6f104509c..8dcb24a3b 100644 --- a/src/core/devices/logger.cpp +++ b/src/core/devices/logger.cpp @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #include "common/logging/log.h" #include "core/libraries/kernel/file_system.h" @@ -17,10 +17,12 @@ s64 Logger::write(const void* buf, size_t nbytes) { } size_t Logger::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { + size_t total_written = 0; for (int i = 0; i < iovcnt; i++) { log(static_cast(iov[i].iov_base), iov[i].iov_len); + total_written += iov[i].iov_len; } - return iovcnt; + return total_written; } s64 Logger::pwrite(const void* buf, size_t nbytes, u64 offset) { diff --git a/src/core/devices/logger.h b/src/core/devices/logger.h index bfb07f337..eef17bc4b 100644 --- a/src/core/devices/logger.h +++ b/src/core/devices/logger.h @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once diff --git a/src/core/devices/nop_device.h b/src/core/devices/nop_device.h index a75b92f1b..5518b1de1 100644 --- a/src/core/devices/nop_device.h +++ b/src/core/devices/nop_device.h @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once #include "base_device.h" @@ -17,36 +17,47 @@ public: int ioctl(u64 cmd, Common::VaCtx* args) override { return 0; } + s64 write(const void* buf, size_t nbytes) override { return 0; } + size_t readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override { return 0; } + size_t writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override { - return 0; + return ORBIS_KERNEL_ERROR_EBADF; } + s64 preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) override { return 0; } + s64 lseek(s64 offset, int whence) override { return 0; } + s64 read(void* buf, size_t nbytes) override { return 0; } + int fstat(Libraries::Kernel::OrbisKernelStat* sb) override { return 0; } + s32 fsync() override { return 0; } + int ftruncate(s64 length) override { return 0; } + int getdents(void* buf, u32 nbytes, s64* basep) override { return 0; } + s64 pwrite(const void* buf, size_t nbytes, u64 offset) override { return 0; } diff --git a/src/core/devices/random.cpp b/src/core/devices/random_device.cpp similarity index 90% rename from src/core/devices/random.cpp rename to src/core/devices/random_device.cpp index 705449423..50934e3b8 100644 --- a/src/core/devices/random.cpp +++ b/src/core/devices/random_device.cpp @@ -1,43 +1,52 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + #include #include "common/logging/log.h" -#include "random.h" +#include "random_device.h" namespace Core::Devices { + std::shared_ptr RandomDevice::Create(u32 handle, const char*, int, u16) { std::srand(std::time(nullptr)); return std::shared_ptr( reinterpret_cast(new RandomDevice(handle))); } + int RandomDevice::ioctl(u64 cmd, Common::VaCtx* args) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 RandomDevice::write(const void* buf, size_t nbytes) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + size_t RandomDevice::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + size_t RandomDevice::readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 RandomDevice::preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 RandomDevice::lseek(s64 offset, int whence) { return 0; } s64 RandomDevice::read(void* buf, size_t nbytes) { auto rbuf = static_cast(buf); - for (size_t i = 0; i < nbytes; i++) + for (size_t i = 0; i < nbytes; i++) { rbuf[i] = std::rand() & 0xFF; + } return nbytes; } @@ -65,4 +74,5 @@ s64 RandomDevice::pwrite(const void* buf, size_t nbytes, u64 offset) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + } // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/random.h b/src/core/devices/random_device.h similarity index 90% rename from src/core/devices/random.h rename to src/core/devices/random_device.h index 3bbed1ca2..a5c8e9845 100644 --- a/src/core/devices/random.h +++ b/src/core/devices/random_device.h @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once #include diff --git a/src/core/devices/srandom.cpp b/src/core/devices/srandom_device.cpp similarity index 90% rename from src/core/devices/srandom.cpp rename to src/core/devices/srandom_device.cpp index ff80adeaf..ab78ddbe2 100644 --- a/src/core/devices/srandom.cpp +++ b/src/core/devices/srandom_device.cpp @@ -1,35 +1,43 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + #include #include "common/logging/log.h" -#include "srandom.h" +#include "srandom_device.h" namespace Core::Devices { + std::shared_ptr SRandomDevice::Create(u32 handle, const char*, int, u16) { std::srand(std::time(nullptr)); return std::shared_ptr( reinterpret_cast(new SRandomDevice(handle))); } + int SRandomDevice::ioctl(u64 cmd, Common::VaCtx* args) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 SRandomDevice::write(const void* buf, size_t nbytes) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + size_t SRandomDevice::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + size_t SRandomDevice::readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 SRandomDevice::preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 SRandomDevice::lseek(s64 offset, int whence) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; @@ -37,8 +45,9 @@ s64 SRandomDevice::lseek(s64 offset, int whence) { s64 SRandomDevice::read(void* buf, size_t nbytes) { auto rbuf = static_cast(buf); - for (size_t i = 0; i < nbytes; i++) + for (size_t i = 0; i < nbytes; i++) { rbuf[i] = std::rand(); + } return nbytes; } @@ -66,4 +75,5 @@ s64 SRandomDevice::pwrite(const void* buf, size_t nbytes, u64 offset) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + } // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/srandom.h b/src/core/devices/srandom_device.h similarity index 90% rename from src/core/devices/srandom.h rename to src/core/devices/srandom_device.h index 3a3b02571..cd32f7289 100644 --- a/src/core/devices/srandom.h +++ b/src/core/devices/srandom_device.h @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once #include diff --git a/src/core/devices/urandom.cpp b/src/core/devices/urandom_device.cpp similarity index 90% rename from src/core/devices/urandom.cpp rename to src/core/devices/urandom_device.cpp index 8917caea5..c001aab83 100644 --- a/src/core/devices/urandom.cpp +++ b/src/core/devices/urandom_device.cpp @@ -1,8 +1,9 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + #include #include "common/logging/log.h" -#include "urandom.h" +#include "urandom_device.h" namespace Core::Devices { @@ -16,22 +17,27 @@ int URandomDevice::ioctl(u64 cmd, Common::VaCtx* args) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 URandomDevice::write(const void* buf, size_t nbytes) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + size_t URandomDevice::writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + size_t URandomDevice::readv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 URandomDevice::preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + s64 URandomDevice::lseek(s64 offset, int whence) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; @@ -39,8 +45,9 @@ s64 URandomDevice::lseek(s64 offset, int whence) { s64 URandomDevice::read(void* buf, size_t nbytes) { auto rbuf = static_cast(buf); - for (size_t i = 0; i < nbytes; i++) + for (size_t i = 0; i < nbytes; i++) { rbuf[i] = std::rand() & 0xFF; + } return nbytes; } @@ -68,4 +75,5 @@ s64 URandomDevice::pwrite(const void* buf, size_t nbytes, u64 offset) { LOG_ERROR(Kernel_Pthread, "(STUBBED) called"); return 0; } + } // namespace Core::Devices \ No newline at end of file diff --git a/src/core/devices/urandom.h b/src/core/devices/urandom_device.h similarity index 90% rename from src/core/devices/urandom.h rename to src/core/devices/urandom_device.h index 9370017d5..b8a854cc0 100644 --- a/src/core/devices/urandom.h +++ b/src/core/devices/urandom_device.h @@ -1,5 +1,5 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later #pragma once #include diff --git a/src/core/file_sys/fs.cpp b/src/core/file_sys/fs.cpp index 7d456780b..8a191e666 100644 --- a/src/core/file_sys/fs.cpp +++ b/src/core/file_sys/fs.cpp @@ -233,7 +233,7 @@ void HandleTable::CreateStdHandles() { std::shared_ptr{reinterpret_cast(device)}; }; // order matters - setup("/dev/stdin", new Devices::NopDevice(0)); // stdin + setup("/dev/stdin", new Devices::Logger("stdin", false)); // stdin setup("/dev/stdout", new Devices::Logger("stdout", false)); // stdout setup("/dev/stderr", new Devices::Logger("stderr", true)); // stderr } diff --git a/src/core/libraries/kernel/file_system.cpp b/src/core/libraries/kernel/file_system.cpp index ce91fe192..b0f7fdafe 100644 --- a/src/core/libraries/kernel/file_system.cpp +++ b/src/core/libraries/kernel/file_system.cpp @@ -8,13 +8,13 @@ #include "common/logging/log.h" #include "common/scope_exit.h" #include "common/singleton.h" -#include "core/devices/deci_tty6.h" -#include "core/devices/dev_console.h" +#include "core/devices/deci_tty6_device.h" +#include "core/devices/console_device.h" #include "core/devices/logger.h" #include "core/devices/nop_device.h" -#include "core/devices/random.h" -#include "core/devices/srandom.h" -#include "core/devices/urandom.h" +#include "core/devices/random_device.h" +#include "core/devices/srandom_device.h" +#include "core/devices/urandom_device.h" #include "core/file_sys/fs.h" #include "core/libraries/kernel/file_system.h" #include "core/libraries/kernel/orbis_error.h" @@ -270,13 +270,6 @@ size_t PS4_SYSV_ABI _readv(int d, const SceKernelIovec* iov, int iovcnt) { } size_t PS4_SYSV_ABI _writev(int fd, const SceKernelIovec* iov, int iovcn) { - if (fd == 1) { - size_t total_written = 0; - for (int i = 0; i < iovcn; i++) { - total_written += ::fwrite(iov[i].iov_base, 1, iov[i].iov_len, stdout); - } - return total_written; - } auto* h = Common::Singleton::Instance(); auto* file = h->GetFile(fd); if (file == nullptr) { From 84a341dce570c4a070d07bc023a757652247fb6f Mon Sep 17 00:00:00 2001 From: polyproxy <47796739+polybiusproxy@users.noreply.github.com> Date: Tue, 21 Jan 2025 19:30:34 +0100 Subject: [PATCH 31/99] remove BADF return --- src/core/devices/nop_device.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/devices/nop_device.h b/src/core/devices/nop_device.h index 5518b1de1..da9a3fc82 100644 --- a/src/core/devices/nop_device.h +++ b/src/core/devices/nop_device.h @@ -27,7 +27,7 @@ public: } size_t writev(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt) override { - return ORBIS_KERNEL_ERROR_EBADF; + return 0; } s64 preadv(const Libraries::Kernel::SceKernelIovec* iov, int iovcnt, u64 offset) override { From 41b39428335025e65f9e707ed8d5a9a1b09ba942 Mon Sep 17 00:00:00 2001 From: polyproxy <47796739+polybiusproxy@users.noreply.github.com> Date: Tue, 21 Jan 2025 19:34:05 +0100 Subject: [PATCH 32/99] clang-format --- src/core/file_sys/fs.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/file_sys/fs.cpp b/src/core/file_sys/fs.cpp index 8a191e666..ec940503f 100644 --- a/src/core/file_sys/fs.cpp +++ b/src/core/file_sys/fs.cpp @@ -233,7 +233,7 @@ void HandleTable::CreateStdHandles() { std::shared_ptr{reinterpret_cast(device)}; }; // order matters - setup("/dev/stdin", new Devices::Logger("stdin", false)); // stdin + setup("/dev/stdin", new Devices::Logger("stdin", false)); // stdin setup("/dev/stdout", new Devices::Logger("stdout", false)); // stdout setup("/dev/stderr", new Devices::Logger("stderr", true)); // stderr } From 5c62a00134523c4d0b2f06e9b6c28c596631e748 Mon Sep 17 00:00:00 2001 From: polyproxy <47796739+polybiusproxy@users.noreply.github.com> Date: Tue, 21 Jan 2025 21:14:05 +0100 Subject: [PATCH 33/99] `clang-format` (again) --- src/core/libraries/kernel/file_system.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/libraries/kernel/file_system.cpp b/src/core/libraries/kernel/file_system.cpp index b0f7fdafe..0150c11f5 100644 --- a/src/core/libraries/kernel/file_system.cpp +++ b/src/core/libraries/kernel/file_system.cpp @@ -8,8 +8,8 @@ #include "common/logging/log.h" #include "common/scope_exit.h" #include "common/singleton.h" -#include "core/devices/deci_tty6_device.h" #include "core/devices/console_device.h" +#include "core/devices/deci_tty6_device.h" #include "core/devices/logger.h" #include "core/devices/nop_device.h" #include "core/devices/random_device.h" From 2a4798cfa60f430840855a88339c1f4b364df9a4 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Wed, 22 Jan 2025 00:40:00 -0800 Subject: [PATCH 34/99] tile: Fix some tile thickness calculation errors. (#2203) * tile: Fix some tile thickness calculation errors. * tile: Do not pad mip height to tile height. --- src/video_core/texture_cache/image_info.cpp | 13 ++++++------- src/video_core/texture_cache/tile.h | 4 ++-- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/src/video_core/texture_cache/image_info.cpp b/src/video_core/texture_cache/image_info.cpp index 8068aae2f..dd89be8aa 100644 --- a/src/video_core/texture_cache/image_info.cpp +++ b/src/video_core/texture_cache/image_info.cpp @@ -178,7 +178,6 @@ void ImageInfo::UpdateSize() { case AmdGpu::TilingMode::Display_Linear: { std::tie(mip_info.pitch, mip_info.size) = ImageSizeLinearAligned(mip_w, mip_h, bpp, num_samples); - mip_info.height = mip_h; break; } case AmdGpu::TilingMode::Texture_Volume: @@ -188,12 +187,7 @@ void ImageInfo::UpdateSize() { case AmdGpu::TilingMode::Display_MicroTiled: case AmdGpu::TilingMode::Texture_MicroTiled: { std::tie(mip_info.pitch, mip_info.size) = - ImageSizeMicroTiled(mip_w, mip_h, bpp, thickness, num_samples); - mip_info.height = std::max(mip_h, 8u); - if (props.is_block) { - mip_info.pitch = std::max(mip_info.pitch * 4, 32u); - mip_info.height = std::max(mip_info.height * 4, 32u); - } + ImageSizeMicroTiled(mip_w, mip_h, thickness, bpp, num_samples); break; } case AmdGpu::TilingMode::Display_MacroTiled: @@ -208,6 +202,11 @@ void ImageInfo::UpdateSize() { UNREACHABLE(); } } + mip_info.height = mip_h; + if (props.is_block) { + mip_info.pitch = std::max(mip_info.pitch * 4, 32u); + mip_info.height = std::max(mip_info.height * 4, 32u); + } mip_info.size *= mip_d; mip_info.offset = guest_size; mips_layout.emplace_back(mip_info); diff --git a/src/video_core/texture_cache/tile.h b/src/video_core/texture_cache/tile.h index c111e6aca..54938b801 100644 --- a/src/video_core/texture_cache/tile.h +++ b/src/video_core/texture_cache/tile.h @@ -313,8 +313,8 @@ constexpr std::pair ImageSizeMicroTiled(u32 pitch, u32 height, u32 const auto& [pitch_align, height_align] = micro_tile_extent; auto pitch_aligned = (pitch + pitch_align - 1) & ~(pitch_align - 1); const auto height_aligned = (height + height_align - 1) & ~(height_align - 1); - size_t log_sz = (pitch_aligned * height_aligned * bpp * num_samples * thickness + 7) / 8; - while (log_sz % 256) { + size_t log_sz = (pitch_aligned * height_aligned * bpp * num_samples + 7) / 8; + while ((log_sz * thickness) % 256) { pitch_aligned += pitch_align; log_sz = (pitch_aligned * height_aligned * bpp * num_samples + 7) / 8; } From 78ae9613c5f0e40f30b5a5cea83fa368530f1c24 Mon Sep 17 00:00:00 2001 From: Stephen Miller <56742918+StevenMiller123@users.noreply.github.com> Date: Wed, 22 Jan 2025 04:07:43 -0600 Subject: [PATCH 35/99] Fix for address_space initialization on Windows (#2202) Should fix some `Region coalescing failed: Attempt to access invalid address.` crashes. Co-authored-by: TheTurtle <47210458+raphaelthegreat@users.noreply.github.com> --- src/core/address_space.cpp | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/src/core/address_space.cpp b/src/core/address_space.cpp index 2b7331cbd..e9fb8cfbc 100644 --- a/src/core/address_space.cpp +++ b/src/core/address_space.cpp @@ -67,28 +67,25 @@ struct AddressSpace::Impl { static constexpr size_t ReductionOnFail = 1_GB; static constexpr size_t MaxReductions = 10; - size_t reduction = 0; size_t virtual_size = SystemManagedSize + SystemReservedSize + UserSize; for (u32 i = 0; i < MaxReductions; i++) { - virtual_base = static_cast(VirtualAlloc2(process, NULL, virtual_size - reduction, + virtual_base = static_cast(VirtualAlloc2(process, NULL, virtual_size, MEM_RESERVE | MEM_RESERVE_PLACEHOLDER, PAGE_NOACCESS, ¶m, 1)); if (virtual_base) { break; } - reduction += ReductionOnFail; + virtual_size -= ReductionOnFail; } ASSERT_MSG(virtual_base, "Unable to reserve virtual address space: {}", Common::GetLastErrorMsg()); - // Take the reduction off of the system managed area, and leave the others unchanged. - reduction = size_t(virtual_base - SYSTEM_MANAGED_MIN); - system_managed_base = virtual_base; - system_managed_size = SystemManagedSize - reduction; system_reserved_base = reinterpret_cast(SYSTEM_RESERVED_MIN); system_reserved_size = SystemReservedSize; + system_managed_base = virtual_base; + system_managed_size = system_reserved_base - virtual_base; user_base = reinterpret_cast(USER_MIN); - user_size = UserSize; + user_size = virtual_base + virtual_size - user_base; LOG_INFO(Kernel_Vmm, "System managed virtual memory region: {} - {}", fmt::ptr(system_managed_base), @@ -101,10 +98,8 @@ struct AddressSpace::Impl { // Initializer placeholder tracker const uintptr_t system_managed_addr = reinterpret_cast(system_managed_base); - const uintptr_t system_reserved_addr = reinterpret_cast(system_reserved_base); - const uintptr_t user_addr = reinterpret_cast(user_base); regions.emplace(system_managed_addr, - MemoryRegion{system_managed_addr, virtual_size - reduction, false}); + MemoryRegion{system_managed_addr, virtual_size, false}); // Allocate backing file that represents the total physical memory. backing_handle = From adbff4056fe5a98026c2239ecd9511cd1be90e0f Mon Sep 17 00:00:00 2001 From: f3d209 <45915273+rootexpm@users.noreply.github.com> Date: Wed, 22 Jan 2025 10:10:35 +0000 Subject: [PATCH 36/99] Added ability to change save data path (#2199) * added ability to change save data path * get default save data path from fs * add copyright * formatting --- src/common/config.cpp | 15 +++ src/common/config.h | 2 + .../libraries/save_data/save_instance.cpp | 6 +- src/qt_gui/settings_dialog.cpp | 33 ++++- src/qt_gui/settings_dialog.ui | 121 +++++++++++------- src/qt_gui/translations/en.ts | 8 ++ 6 files changed, 132 insertions(+), 53 deletions(-) diff --git a/src/common/config.cpp b/src/common/config.cpp index ed9af5a72..6e9db50ff 100644 --- a/src/common/config.cpp +++ b/src/common/config.cpp @@ -78,6 +78,7 @@ static std::string trophyKey; static bool load_game_size = true; std::vector settings_install_dirs = {}; std::filesystem::path settings_addon_install_dir = {}; +std::filesystem::path save_data_path = {}; u32 main_window_geometry_x = 400; u32 main_window_geometry_y = 400; u32 main_window_geometry_w = 1280; @@ -110,6 +111,13 @@ bool GetLoadGameSizeEnabled() { return load_game_size; } +std::filesystem::path GetSaveDataPath() { + if (save_data_path.empty()) { + return Common::FS::GetUserPath(Common::FS::PathType::SaveDataDir); + } + return save_data_path; +} + void setLoadGameSizeEnabled(bool enable) { load_game_size = enable; } @@ -502,6 +510,10 @@ void setGameInstallDirs(const std::vector& settings_insta settings_install_dirs = settings_install_dirs_config; } +void setSaveDataPath(const std::filesystem::path& path) { + save_data_path = path; +} + u32 getMainWindowGeometryX() { return main_window_geometry_x; } @@ -690,6 +702,8 @@ void load(const std::filesystem::path& path) { addGameInstallDir(std::filesystem::path{dir}); } + save_data_path = toml::find_fs_path_or(gui, "saveDataPath", {}); + settings_addon_install_dir = toml::find_fs_path_or(gui, "addonInstallDir", {}); main_window_geometry_x = toml::find_or(gui, "geometry_x", 0); main_window_geometry_y = toml::find_or(gui, "geometry_y", 0); @@ -784,6 +798,7 @@ void save(const std::filesystem::path& path) { install_dirs.emplace_back(std::string{fmt::UTF(dirString.u8string()).data}); } data["GUI"]["installDirs"] = install_dirs; + data["GUI"]["saveDataPath"] = std::string{fmt::UTF(save_data_path.u8string()).data}; data["GUI"]["loadGameSizeEnabled"] = load_game_size; data["GUI"]["addonInstallDir"] = diff --git a/src/common/config.h b/src/common/config.h index cb56f99c7..564947f1e 100644 --- a/src/common/config.h +++ b/src/common/config.h @@ -18,6 +18,7 @@ void saveMainWindow(const std::filesystem::path& path); std::string getTrophyKey(); void setTrophyKey(std::string key); bool GetLoadGameSizeEnabled(); +std::filesystem::path GetSaveDataPath(); void setLoadGameSizeEnabled(bool enable); bool getIsFullscreen(); std::string getFullscreenMode(); @@ -82,6 +83,7 @@ void setUserName(const std::string& type); void setUpdateChannel(const std::string& type); void setSeparateUpdateEnabled(bool use); void setGameInstallDirs(const std::vector& settings_install_dirs_config); +void setSaveDataPath(const std::filesystem::path& path); void setCompatibilityEnabled(bool use); void setCheckCompatibilityOnStartup(bool use); diff --git a/src/core/libraries/save_data/save_instance.cpp b/src/core/libraries/save_data/save_instance.cpp index 99daf83cc..c2b7dca3c 100644 --- a/src/core/libraries/save_data/save_instance.cpp +++ b/src/core/libraries/save_data/save_instance.cpp @@ -47,15 +47,13 @@ namespace Libraries::SaveData { std::filesystem::path SaveInstance::MakeTitleSavePath(OrbisUserServiceUserId user_id, std::string_view game_serial) { - return Common::FS::GetUserPath(Common::FS::PathType::SaveDataDir) / std::to_string(user_id) / - game_serial; + return Config::GetSaveDataPath() / std::to_string(user_id) / game_serial; } std::filesystem::path SaveInstance::MakeDirSavePath(OrbisUserServiceUserId user_id, std::string_view game_serial, std::string_view dir_name) { - return Common::FS::GetUserPath(Common::FS::PathType::SaveDataDir) / std::to_string(user_id) / - game_serial / dir_name; + return Config::GetSaveDataPath() / std::to_string(user_id) / game_serial / dir_name; } uint64_t SaveInstance::GetMaxBlockFromSFO(const PSF& psf) { diff --git a/src/qt_gui/settings_dialog.cpp b/src/qt_gui/settings_dialog.cpp index 175c8c51d..5695d6232 100644 --- a/src/qt_gui/settings_dialog.cpp +++ b/src/qt_gui/settings_dialog.cpp @@ -202,6 +202,21 @@ SettingsDialog::SettingsDialog(std::span physical_devices, delete selected_item; } }); + + connect(ui->browseButton, &QPushButton::clicked, this, [this]() { + const auto save_data_path = Config::GetSaveDataPath(); + QString initial_path; + Common::FS::PathToQString(initial_path, save_data_path); + + QString save_data_path_string = + QFileDialog::getExistingDirectory(this, tr("Directory to save data"), initial_path); + + auto file_path = Common::FS::PathFromQString(save_data_path_string); + if (!file_path.empty()) { + Config::setSaveDataPath(file_path); + ui->currentSaveDataPath->setText(save_data_path_string); + } + }); } // DEBUG TAB @@ -256,6 +271,10 @@ SettingsDialog::SettingsDialog(std::span physical_devices, ui->addFolderButton->installEventFilter(this); ui->removeFolderButton->installEventFilter(this); + ui->saveDataGroupBox->installEventFilter(this); + ui->currentSaveDataPath->installEventFilter(this); + ui->browseButton->installEventFilter(this); + // Debug ui->debugDump->installEventFilter(this); ui->vkValidationCheckBox->installEventFilter(this); @@ -286,6 +305,11 @@ void SettingsDialog::LoadValuesFromConfig() { const QVector languageIndexes = {21, 23, 14, 6, 18, 1, 12, 22, 2, 4, 25, 24, 29, 5, 0, 9, 15, 16, 17, 7, 26, 8, 11, 20, 3, 13, 27, 10, 19, 30, 28}; + const auto save_data_path = Config::GetSaveDataPath(); + QString save_data_path_string; + Common::FS::PathToQString(save_data_path_string, save_data_path); + ui->currentSaveDataPath->setText(save_data_path_string); + ui->consoleLanguageComboBox->setCurrentIndex( std::distance(languageIndexes.begin(), std::find(languageIndexes.begin(), languageIndexes.end(), @@ -497,6 +521,13 @@ void SettingsDialog::updateNoteTextEdit(const QString& elementName) { text = tr("removeFolderButton"); } + // Save Data + if (elementName == "saveDataGroupBox" || elementName == "currentSaveDataPath") { + text = tr("saveDataBox"); + } else if (elementName == "browseButton") { + text = tr("browseButton"); + } + // Debug if (elementName == "debugDump") { text = tr("debugDump"); @@ -603,4 +634,4 @@ void SettingsDialog::ResetInstallFolders() { } Config::setGameInstallDirs(settings_install_dirs_config); } -} +} \ No newline at end of file diff --git a/src/qt_gui/settings_dialog.ui b/src/qt_gui/settings_dialog.ui index c084d4849..d72a56973 100644 --- a/src/qt_gui/settings_dialog.ui +++ b/src/qt_gui/settings_dialog.ui @@ -53,7 +53,7 @@ - 0 + 3 @@ -67,8 +67,8 @@ 0 0 - 946 - 611 + 771 + 606 @@ -644,8 +644,8 @@ 0 0 - 946 - 605 + 455 + 252 @@ -928,8 +928,8 @@ 0 0 - 946 - 605 + 579 + 194 @@ -1178,51 +1178,76 @@ Paths - - - 0 - 0 - 946 - 605 - - - + - - - - - Game Folders - - - - - - 0 - - + + + Game Folders + + + + + - - Add... - + + Add... + - - + + - - Remove - + + Remove + - - - - - - + + + + + Qt::Horizontal + + + + 40 + 20 + + + + - - - + + + + + + + + + + + Save Data Path + + + + + + + + true + + + + + + + Browse + + + + + + + @@ -1239,8 +1264,8 @@ 0 0 - 946 - 586 + 510 + 269 diff --git a/src/qt_gui/translations/en.ts b/src/qt_gui/translations/en.ts index 9127df7e3..dc72d97c9 100644 --- a/src/qt_gui/translations/en.ts +++ b/src/qt_gui/translations/en.ts @@ -912,6 +912,14 @@ rdocCheckBox Enable RenderDoc Debugging:\nIf enabled, the emulator will provide compatibility with Renderdoc to allow capture and analysis of the currently rendered frame. + + saveDataBox + Save Data Path:\nThe folder where game save data will be saved. + + + browseButton + Browse:\nBrowse for a folder to set as the save data path. + CheatsPatches From 2968cf5a99a1be2fe7f3f28dbc65fe16f488c8af Mon Sep 17 00:00:00 2001 From: Stephen Miller <56742918+StevenMiller123@users.noreply.github.com> Date: Wed, 22 Jan 2025 09:06:27 -0600 Subject: [PATCH 37/99] sceKernelVirtualQuery Fixes (#2204) --- src/core/memory.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/memory.cpp b/src/core/memory.cpp index 619941000..f90d4e6aa 100644 --- a/src/core/memory.cpp +++ b/src/core/memory.cpp @@ -529,8 +529,8 @@ int MemoryManager::VirtualQuery(VAddr addr, int flags, info->is_flexible.Assign(vma.type == VMAType::Flexible); info->is_direct.Assign(vma.type == VMAType::Direct); info->is_stack.Assign(vma.type == VMAType::Stack); - info->is_pooled.Assign(vma.type == VMAType::PoolReserved); - info->is_committed.Assign(vma.type == VMAType::Pooled); + info->is_pooled.Assign(vma.type == VMAType::PoolReserved || vma.type == VMAType::Pooled); + info->is_committed.Assign(vma.IsMapped()); vma.name.copy(info->name.data(), std::min(info->name.size(), vma.name.size())); if (vma.type == VMAType::Direct) { const auto dmem_it = FindDmemArea(vma.phys_base); From b3bce086b30c148f25817f9df06abaedad244453 Mon Sep 17 00:00:00 2001 From: Vinicius Rangel Date: Wed, 22 Jan 2025 12:08:49 -0300 Subject: [PATCH 38/99] devtools: fix ReleaseKeyboard assert being triggered if many shader editor windows exist (#2205) --- src/core/devtools/widget/shader_list.cpp | 65 +++++++++++++++--------- src/core/devtools/widget/shader_list.h | 9 ++-- 2 files changed, 47 insertions(+), 27 deletions(-) diff --git a/src/core/devtools/widget/shader_list.cpp b/src/core/devtools/widget/shader_list.cpp index 97d01896d..0285db5a5 100644 --- a/src/core/devtools/widget/shader_list.cpp +++ b/src/core/devtools/widget/shader_list.cpp @@ -24,16 +24,33 @@ using namespace ImGui; namespace Core::Devtools::Widget { -ShaderList::Selection::Selection(int index) : index(index) { - isa_editor.SetPalette(TextEditor::GetDarkPalette()); - isa_editor.SetReadOnly(true); - glsl_editor.SetPalette(TextEditor::GetDarkPalette()); - glsl_editor.SetLanguageDefinition(TextEditor::LanguageDefinition::GLSL()); +ShaderList::Selection::Selection(int index) + : index(index), isa_editor(std::make_unique()), + glsl_editor(std::make_unique()) { + isa_editor->SetPalette(TextEditor::GetDarkPalette()); + isa_editor->SetReadOnly(true); + glsl_editor->SetPalette(TextEditor::GetDarkPalette()); + glsl_editor->SetLanguageDefinition(TextEditor::LanguageDefinition::GLSL()); presenter->GetWindow().RequestKeyboard(); } ShaderList::Selection::~Selection() { - presenter->GetWindow().ReleaseKeyboard(); + if (index >= 0) { + presenter->GetWindow().ReleaseKeyboard(); + } +} + +ShaderList::Selection::Selection(Selection&& other) noexcept + : index{other.index}, isa_editor{std::move(other.isa_editor)}, + glsl_editor{std::move(other.glsl_editor)}, open{other.open}, showing_bin{other.showing_bin}, + patch_path{std::move(other.patch_path)}, patch_bin_path{std::move(other.patch_bin_path)} { + other.index = -1; +} + +ShaderList::Selection& ShaderList::Selection::operator=(Selection other) { + using std::swap; + swap(*this, other); + return *this; } void ShaderList::Selection::ReloadShader(DebugStateType::ShaderDump& value) { @@ -72,13 +89,13 @@ bool ShaderList::Selection::DrawShader(DebugStateType::ShaderDump& value) { value.is_patched = !value.patch_spv.empty(); if (!value.is_patched) { // No patch - isa_editor.SetText(value.cache_isa_disasm); - glsl_editor.SetText(value.cache_spv_disasm); + isa_editor->SetText(value.cache_isa_disasm); + glsl_editor->SetText(value.cache_spv_disasm); } else { - isa_editor.SetText(value.cache_patch_disasm); - isa_editor.SetLanguageDefinition(TextEditor::LanguageDefinition::SPIRV()); - glsl_editor.SetText(value.patch_source); - glsl_editor.SetReadOnly(false); + isa_editor->SetText(value.cache_patch_disasm); + isa_editor->SetLanguageDefinition(TextEditor::LanguageDefinition::SPIRV()); + glsl_editor->SetText(value.patch_source); + glsl_editor->SetReadOnly(false); } } @@ -97,18 +114,18 @@ bool ShaderList::Selection::DrawShader(DebugStateType::ShaderDump& value) { if (value.patch_source.empty()) { value.patch_source = value.cache_spv_disasm; } - isa_editor.SetText(value.cache_patch_disasm); - isa_editor.SetLanguageDefinition(TextEditor::LanguageDefinition::SPIRV()); - glsl_editor.SetText(value.patch_source); - glsl_editor.SetReadOnly(false); + isa_editor->SetText(value.cache_patch_disasm); + isa_editor->SetLanguageDefinition(TextEditor::LanguageDefinition::SPIRV()); + glsl_editor->SetText(value.patch_source); + glsl_editor->SetReadOnly(false); if (!value.patch_spv.empty()) { ReloadShader(value); } } else { - isa_editor.SetText(value.cache_isa_disasm); - isa_editor.SetLanguageDefinition(TextEditor::LanguageDefinition()); - glsl_editor.SetText(value.cache_spv_disasm); - glsl_editor.SetReadOnly(true); + isa_editor->SetText(value.cache_isa_disasm); + isa_editor->SetLanguageDefinition(TextEditor::LanguageDefinition()); + glsl_editor->SetText(value.cache_spv_disasm); + glsl_editor->SetReadOnly(true); ReloadShader(value); } } @@ -154,7 +171,7 @@ bool ShaderList::Selection::DrawShader(DebugStateType::ShaderDump& value) { compile = true; } if (save) { - value.patch_source = glsl_editor.GetText(); + value.patch_source = glsl_editor->GetText(); std::ofstream file{patch_path, std::ios::binary | std::ios::trunc}; file << value.patch_source; std::string msg = "Patch saved to "; @@ -192,7 +209,7 @@ bool ShaderList::Selection::DrawShader(DebugStateType::ShaderDump& value) { DebugState.ShowDebugMessage("Decompilation failed (Compile was ok):\n" + res); } else { - isa_editor.SetText(value.cache_patch_disasm); + isa_editor->SetText(value.cache_patch_disasm); ReloadShader(value); } } @@ -201,9 +218,9 @@ bool ShaderList::Selection::DrawShader(DebugStateType::ShaderDump& value) { } if (showing_bin) { - isa_editor.Render(value.is_patched ? "SPIRV" : "ISA", GetContentRegionAvail()); + isa_editor->Render(value.is_patched ? "SPIRV" : "ISA", GetContentRegionAvail()); } else { - glsl_editor.Render("GLSL", GetContentRegionAvail()); + glsl_editor->Render("GLSL", GetContentRegionAvail()); } End(); diff --git a/src/core/devtools/widget/shader_list.h b/src/core/devtools/widget/shader_list.h index fbb8d2070..c882b0964 100644 --- a/src/core/devtools/widget/shader_list.h +++ b/src/core/devtools/widget/shader_list.h @@ -14,14 +14,17 @@ class ShaderList { struct Selection { explicit Selection(int index); ~Selection(); + Selection(const Selection& other) = delete; + Selection(Selection&& other) noexcept; + Selection& operator=(Selection other); void ReloadShader(DebugStateType::ShaderDump& value); bool DrawShader(DebugStateType::ShaderDump& value); - int index; - TextEditor isa_editor{}; - TextEditor glsl_editor{}; + int index{-1}; + std::unique_ptr isa_editor{}; + std::unique_ptr glsl_editor{}; bool open = true; bool showing_bin = false; From e584444aa38a6f1191f622ef1b8db7617c0549c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=8A=E9=A4=85=E3=81=AECreeeper?= <56744841+creeper-0910@users.noreply.github.com> Date: Thu, 23 Jan 2025 06:52:27 +0900 Subject: [PATCH 39/99] Update Japanese translation (#2209) * Update Japanese translation * Update Japanese translation * Update Japanese translation --- src/qt_gui/translations/ja_JP.ts | 164 +++++++++++++++---------------- 1 file changed, 82 insertions(+), 82 deletions(-) diff --git a/src/qt_gui/translations/ja_JP.ts b/src/qt_gui/translations/ja_JP.ts index e07d4eb25..bb9488a6b 100644 --- a/src/qt_gui/translations/ja_JP.ts +++ b/src/qt_gui/translations/ja_JP.ts @@ -19,7 +19,7 @@ This software should not be used to play games you have not legally obtained. - このソフトウェアは、合法的に入手していないゲームをプレイするために使用するものではありません。 + 非正規、非合法のゲームをプレイするためにこのソフトウェアを使用しないでください。 @@ -33,7 +33,7 @@ GameInfoClass Loading game list, please wait :3 - ゲームリストを読み込み中です。お待ちください :3 + ゲームリストを読み込み中です。しばらくお待ちください :3 Cancel @@ -52,7 +52,7 @@ Select which directory you want to install to. - Select which directory you want to install to. + インストール先のディレクトリを選択してください。 @@ -75,7 +75,7 @@ The value for location to install games is not valid. - ゲームをインストールする場所が無効です。 + ゲームのインストール場所が無効です。 @@ -130,35 +130,35 @@ Delete... - Delete... + 削除... Delete Game - Delete Game + ゲームを削除 Delete Update - Delete Update + アップデートを削除 Delete DLC - Delete DLC + DLCを削除 Compatibility... - Compatibility... + 互換性... Update database - Update database + データベースを更新 View report - View report + レポートを表示 Submit a report - Submit a report + レポートを送信 Shortcut creation @@ -182,23 +182,23 @@ Game - Game + ゲーム requiresEnableSeparateUpdateFolder_MSG - This feature requires the 'Enable Separate Update Folder' config option to work. If you want to use this feature, please enable it. + この機能を利用するには、 'アップデートフォルダの分離を有効化' を有効化する必要があります。 This game has no update to delete! - This game has no update to delete! + このゲームにはアップデートがないため削除することができません! Update - Update + アップデート This game has no DLC to delete! - This game has no DLC to delete! + このゲームにはDLCがないため削除することができません! DLC @@ -206,11 +206,11 @@ Delete %1 - Delete %1 + %1 を削除 Are you sure you want to delete %1's %2 directory? - Are you sure you want to delete %1's %2 directory? + %1 の %2 ディレクトリを本当に削除しますか? @@ -241,15 +241,15 @@ Install application from a .pkg file - .pkgファイルからアプリケーションをインストールする + .pkgファイルからアプリケーションをインストール Recent Games - 最近のゲーム + 最近プレイしたゲーム Open shadPS4 Folder - Open shadPS4 Folder + shadPS4フォルダを開く Exit @@ -273,7 +273,7 @@ Tiny - 極小 + 最小 Small @@ -297,7 +297,7 @@ Elf Viewer - Elfビュワー + Elfビューアー Game Install Directory @@ -397,11 +397,11 @@ You have downloaded cheats for all the games you have installed. - インストールしたすべてのゲームのチートをダウンロードしました。 + インストールされているすべてのゲームのチートをダウンロードしました。 Patches Downloaded Successfully! - パッチが正常にダウンロードされました! + パッチが正常にダウンロードされました! All Patches available for all games have been downloaded. @@ -425,11 +425,11 @@ Only one file can be selected! - 1つのファイルしか選択できません! + 1つのファイルしか選択できません! PKG Extraction - PKG抽出 + PKGの抽出 Patch detected! @@ -473,7 +473,7 @@ PKG is a patch, please install the game first! - PKGはパッチです。ゲームを先にインストールしてください! + PKGはパッチです。ゲームを先にインストールしてください! PKG ERROR @@ -526,11 +526,11 @@ Console Language - コンソール言語 + コンソールの言語 Emulator Language - エミュレーター言語 + エミュレーターの言語 Emulator @@ -542,7 +542,7 @@ Enable Separate Update Folder - Enable Separate Update Folder + アップデートフォルダの分離を有効化 Show Game Size In List @@ -550,7 +550,7 @@ Show Splash - スプラッシュを表示する + スプラッシュ画面を表示する Is PS4 Pro @@ -566,11 +566,11 @@ Trophy Key - Trophy Key + トロフィーキー Trophy - Trophy + トロフィー Logger @@ -602,7 +602,7 @@ Hide Cursor Idle Timeout - カーソル非アクティブタイムアウト + カーソルを隠すまでの非アクティブ期間 s @@ -706,7 +706,7 @@ Disable Trophy Pop-ups - Disable Trophy Pop-ups + トロフィーのポップアップを無効化 Play title music @@ -714,19 +714,19 @@ Update Compatibility Database On Startup - Update Compatibility Database On Startup + 起動時に互換性データベースを更新する Game Compatibility - Game Compatibility + ゲームの互換性 Display Compatibility Data - Display Compatibility Data + 互換性に関するデータを表示 Update Compatibility Database - Update Compatibility Database + 互換性データベースを更新 Volume @@ -734,7 +734,7 @@ Audio Backend - Audio Backend + オーディオ バックエンド Save @@ -754,15 +754,15 @@ Point your mouse at an option to display its description. - オプションにマウスをポイントすると、その説明が表示されます。 + 設定項目にマウスをホバーすると、説明が表示されます。 consoleLanguageGroupBox - コンソール言語:\nPS4ゲームが使用する言語を設定します。\nこれはゲームがサポートする言語に設定することをお勧めしますが、地域によって異なる場合があります。 + コンソールの言語:\nPS4ゲームが使用する言語を設定します。\nゲームでサポートされている言語に設定することをお勧めしますが、地域によって異なる場合があります。 emulatorLanguageGroupBox - エミュレーター言語:\nエミュレーターのユーザーインターフェースの言語を設定します。 + エミュレーターの言語:\nエミュレーターのユーザーインターフェースの言語を設定します。 fullscreenCheckBox @@ -770,7 +770,7 @@ separateUpdatesCheckBox - Enable Separate Update Folder:\nEnables installing game updates into a separate folder for easy management. + Enable Separate Update Folder:\nゲームのアップデートを別のフォルダにインストールすることで、管理が容易になります。 showSplashCheckBox @@ -778,7 +778,7 @@ ps4proCheckBox - PS4 Proです:\nエミュレーターがPS4 PROとして動作するようにし、これをサポートするゲームで特別な機能を有効にする場合があります。 + PS4 Pro モード:\nエミュレーターがPS4 PROとして動作するようになり、PS4 PROをサポートする一部のゲームで特別な機能が有効化される場合があります。 discordRPCCheckbox @@ -790,7 +790,7 @@ TrophyKey - Trophy Key:\nKey used to decrypt trophies. Must be obtained from your jailbroken console.\nMust contain only hex characters. + トロフィーキー:\nトロフィーの復号に使用されるキーです。脱獄済みのコンソールから取得することができます。\n16進数のみを受け入れます。 logTypeGroupBox @@ -798,27 +798,27 @@ logFilter - ログフィルター:\n特定の情報のみを印刷するようにログをフィルタリングします。\n例: "Core:Trace" "Lib.Pad:Debug Common.Filesystem:Error" "*:Critical" レベル: Trace, Debug, Info, Warning, Error, Critical - この順序で、特定のレベルはリスト内のすべての前のレベルをサイレンスし、その後のすべてのレベルをログに記録します。 + ログフィルター:\n特定の情報のみを印刷するようにログをフィルタリングします。\n例: "Core:Trace" "Lib.Pad:Debug Common.Filesystem:Error" "*:Critical" \nレベル: Trace, Debug, Info, Warning, Error, Critical - レベルはこの並び通りに処理され、指定されたレベルより前のレベル ログを抑制し、それ以外のすべてのレベルをログに記録します。 updaterGroupBox - 更新:\nRelease: 非常に古いかもしれないが、より信頼性が高くテスト済みの公式バージョンを毎月リリースします。\nNightly: 最新の機能と修正がすべて含まれていますが、バグが含まれている可能性があり、安定性は低いです。 + 更新:\nRelease: 最新の機能を利用できない可能性がありますが、より信頼性が高くテストされた公式バージョンが毎月リリースされます。\nNightly: 最新の機能と修正がすべて含まれていますが、バグが含まれている可能性があり、安定性は低いです。 GUIgroupBox - タイトルミュージックを再生:\nゲームがそれをサポートしている場合、GUIでゲームを選択したときに特別な音楽を再生することを有効にします。 + タイトルミュージックを再生:\nゲームでサポートされている場合に、GUIでゲームを選択したときに特別な音楽を再生する機能を有効にします。 disableTrophycheckBox - Disable Trophy Pop-ups:\nDisable in-game trophy notifications. Trophy progress can still be tracked using the Trophy Viewer (right-click the game in the main window). + トロフィーのポップアップを無効化:\nゲーム内でのトロフィー通知を無効化します。 トロフィーの進行状況は、トロフィービューアーを使用して確認できます。(メインウィンドウでゲームを右クリック) hideCursorGroupBox - カーソルを隠す:\nカーソルが消えるタイミングを選択してください:\n決して: いつでもマウスが見えます。\nアイドル: アイダルの後に消えるまでの時間を設定します。\n常に: マウスは決して見えません。 + カーソルを隠す:\nカーソルが消えるタイミングを選択してください:\n無効: 常にカーソルが表示されます。\n非アクティブ時: カーソルの非アクティブ期間が指定した時間を超えた場合にカーソルを隠します。\n常に: カーソルは常に隠れた状態になります。 idleTimeoutGroupBox - アイドル後にマウスが消えるまでの時間を設定します。 + カーソルが非アクティブになってから隠すまでの時間を設定します。 backButtonBehaviorGroupBox @@ -826,23 +826,23 @@ enableCompatibilityCheckBox - Display Compatibility Data:\nDisplays game compatibility information in table view. Enable "Update Compatibility On Startup" to get up-to-date information. + 互換性に関するデータを表示:\nゲームの互換性に関する情報を表として表示します。常に最新情報を取得したい場合、"起動時に互換性データベースを更新する" を有効化してください。 checkCompatibilityOnStartupCheckBox - Update Compatibility On Startup:\nAutomatically update the compatibility database when shadPS4 starts. + 起動時に互換性データベースを更新する:\nshadPS4の起動時に自動で互換性データベースを更新します。 updateCompatibilityButton - Update Compatibility Database:\nImmediately update the compatibility database. + 互換性データベースを更新する:\n今すぐ互換性データベースを更新します。 Never - 決して + 無効 Idle - アイドル + 非アクティブ時 Always @@ -850,11 +850,11 @@ Touchpad Left - タッチパッド左 + 左タッチパッド Touchpad Right - タッチパッド右 + 右タッチパッド Touchpad Center @@ -866,15 +866,15 @@ graphicsAdapterGroupBox - グラフィックデバイス:\n複数のGPUシステムで、ドロップダウンリストからエミュレーターで使用するGPUを選択するか、\n「自動選択」を選択して自動的に決定します。 + グラフィックデバイス:\nシステムに複数のGPUが搭載されている場合、ドロップダウンリストからエミュレーターで使用するGPUを選択するか、\n「自動選択」を選択して自動的に決定します。 resolutionLayout - 幅/高さ:\n起動時にエミュレーターウィンドウのサイズを設定します。ゲーム中にサイズ変更できます。\nこれはゲーム内の解像度とは異なります。 + 幅/高さ:\n起動時にエミュレーターウィンドウのサイズを設定します。ゲーム中でもサイズを変更することができます。\nこれはゲーム内の解像度とは異なります。 heightDivider - Vblankディバイダー:\nエミュレーターが更新されるフレームレートにこの数を掛けます。これを変更すると、ゲームの速度が上がったり、想定外の変更がある場合、ゲームの重要な機能が壊れる可能性があります! + Vblankディバイダー:\nエミュレーターが更新されるフレームレートにこの数を掛けます。これを変更すると、ゲームの速度が上がったり、想定外の変更がある場合、ゲームの重要な機能が壊れる可能性があります! dumpShadersCheckBox @@ -917,11 +917,11 @@ CheatsPatches Cheats / Patches for - Cheats / Patches for + のチート/パッチ defaultTextEdit_MSG - チート/パッチは実験的です。\n使用には注意してください。\n\nリポジトリを選択し、ダウンロードボタンをクリックしてチートを個別にダウンロードします。\n「Patches」タブでは、すべてのパッチを一度にダウンロードし、使用したいものを選択して選択を保存できます。\n\nチート/パッチを開発していないため、\n問題があればチートの作者に報告してください。\n\n新しいチートを作成しましたか?\nhttps://github.com/shadps4-emu/ps4_cheats を訪問してください。 + チート/パッチは実験的です。\n使用には注意してください。\n\nリポジトリを選択し、ダウンロードボタンをクリックしてチートを個別にダウンロードします。\n「Patches」タブでは、すべてのパッチを一度にダウンロードし、使用したいものを選択して選択を保存できます。\n\nチート/パッチは開発を行っていないため、\n問題があればチートの作者に報告してください。\n\n新しいチートを作成しましたか?\nhttps://github.com/shadps4-emu/ps4_cheats を訪問してください。 No Image Available @@ -997,7 +997,7 @@ Unable to open files.json for reading. - files.jsonを読み込み用に開けません。 + files.jsonを読み取りのために開く事が出来ませんでした。 No patch file found for the current serial. @@ -1005,11 +1005,11 @@ Unable to open the file for reading. - ファイルを読み込み用に開けません。 + ファイルを読み取りのために開く事が出来ませんでした。 Unable to open the file for writing. - ファイルを記録用に開けません。 + ファイルをを書き込みのために開く事が出来ませんでした。 Failed to parse XML: @@ -1029,7 +1029,7 @@ The selected source is invalid. - 選択したソースは無効です。 + 選択されたソースは無効です。 File Exists @@ -1113,7 +1113,7 @@ Failed to open files.json for writing - files.jsonを記録用に開けません + files.jsonを読み取りのために開く事が出来ませんでした。 Author: @@ -1125,7 +1125,7 @@ Failed to open files.json for reading. - files.jsonを読み込み用に開けません。 + files.jsonを読み取りのために開く事が出来ませんでした。 Name: @@ -1180,43 +1180,43 @@ Never Played - Never Played + 未プレイ h - h + 時間 m - m + s - s + Compatibility is untested - Compatibility is untested + 互換性は未検証です Game does not initialize properly / crashes the emulator - Game does not initialize properly / crashes the emulator + ゲームが正常に初期化されない/エミュレーターがクラッシュする Game boots, but only displays a blank screen - Game boots, but only displays a blank screen + ゲームは起動しますが、空のスクリーンが表示されます Game displays an image but does not go past the menu - Game displays an image but does not go past the menu + 正常にゲーム画面が表示されますが、メニューから先に進むことができません Game has game-breaking glitches or unplayable performance - Game has game-breaking glitches or unplayable performance + ゲームを壊すような不具合や、プレイが不可能なほどのパフォーマンスの問題があります Game can be completed with playable performance and no major glitches - Game can be completed with playable performance and no major glitches + パフォーマンスに問題はなく、大きな不具合なしでゲームをプレイすることができます From c015ac134462b3c425d69953e27da0e6c8ca9498 Mon Sep 17 00:00:00 2001 From: tomboylover93 <95257311+tomboylover93@users.noreply.github.com> Date: Wed, 22 Jan 2025 13:53:27 -0800 Subject: [PATCH 40/99] Update Linux building documentation (#2211) * wip: redo build instructions guide for Linux * Add Linux screenshots directory to REUSE.toml * change links for Visual Studio Code images * change instructions for building from terminal reference: https://github.com/shadps4-emu/shadPS4/pull/2211#issuecomment-2608134455 --- REUSE.toml | 1 + documents/Screenshots/Linux/1.png | Bin 0 -> 11447 bytes documents/Screenshots/Linux/2.png | Bin 0 -> 20159 bytes documents/Screenshots/Linux/3.png | Bin 0 -> 25540 bytes documents/Screenshots/Linux/4.png | Bin 0 -> 16845 bytes documents/Screenshots/Linux/5.png | Bin 0 -> 26893 bytes documents/building-linux.md | 103 +++++++++++++++++++++++++----- 7 files changed, 89 insertions(+), 15 deletions(-) create mode 100644 documents/Screenshots/Linux/1.png create mode 100644 documents/Screenshots/Linux/2.png create mode 100644 documents/Screenshots/Linux/3.png create mode 100644 documents/Screenshots/Linux/4.png create mode 100644 documents/Screenshots/Linux/5.png diff --git a/REUSE.toml b/REUSE.toml index 55d76673d..a62974bcd 100644 --- a/REUSE.toml +++ b/REUSE.toml @@ -14,6 +14,7 @@ path = [ "documents/changelog.md", "documents/Quickstart/2.png", "documents/Screenshots/*", + "documents/Screenshots/Linux/*", "externals/MoltenVK/MoltenVK_icd.json", "scripts/ps4_names.txt", "src/images/about_icon.png", diff --git a/documents/Screenshots/Linux/1.png b/documents/Screenshots/Linux/1.png new file mode 100644 index 0000000000000000000000000000000000000000..3dd5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_MSDDk^r9A%vZ$7V5`Vv zaA4%e~pQ2&?Ms_1nB5)d0tu|swhOrMf*oLH{X zV^+2u%;AgZC#6HkLmNwh{0oE-kIW<`@&;hr`SvF3{=r2he{&o2Cl1))=mv+*$VvLQ z&Q&dE_jw%os%8fY^ki|VNq93m(o-%SoSgHOr`w~Jbu9Ms_*+jm!KRNVtiaL&aEJ6k zIWg?JN|2-Ob>G8()+w+gs0Eaq9N8S#t2ulRPbx##waYzq>i9JrAWtNmAce=;H8Yb4 zfI{os4e!_ZX&l_`%R8|lODnsL$;j7-6_>`cO2BMm0C8|MYIG0PlcAV_C&9-y$k)wm zo4UIPWp^A}_KTf|nSq&-iy`wO>@aK1-n8#zL_U)zaywcuSe#OHI(I`v(z8uWG%-Sw zN=lK$xOYkmRPwrkJ;XH2>w1APkfZ8;_99hYmjs>3-&ri#+zAcdPB5EW90H8uz~wIj zT)kc6mCF-z8UBC9t16>~DaF=iv@42jf4%zcn;5IamRBU?(8E zG7e_FBpolI0YHis`bLR+?2snpUFXP08u}D2g+*IJ4#ejsKsg6^0Z`~+!2Nze8*sxr zq3=6KwvV=kbI=83g7y0{eGIg&_3(u`baZrRl+wcrf-Os$iW)*Qyz2D0k#*}iy_>zY zI9^4kh&Y>Wj>~}p&{Zw*y^r|?`Ov9clro`jTF+qmLVr5&%Z1D4QpVOqHz9GyM>eX9RDkV?XaSB`2X2>C6C$)sPkOl{|poh OgJdKW#s7Xb^#4D*Qdz11 literal 0 HcmV?d00001 diff --git a/documents/Screenshots/Linux/2.png b/documents/Screenshots/Linux/2.png new file mode 100644 index 0000000000000000000000000000000000000000..fc5ff3b534773394c892a9d026a4d5e553ed2cfa GIT binary patch literal 20159 zcmdSBbySqy-#3b)sH94_2qN7bgM!lCozmT10wOKlUDDmHgmiaH3^jDuoXzjPpYy)w ztmpaTto8nL)>2~Tnz`oM*WTanr#3;d(jsWc1jq;o2xwxWpX3n`5Uat@G0%~}*K9w- zr{LQQ8&NfT1O)WXhyRaaY0(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core!o9rOrzgt`D>1j37v*?hflNh-faNHnoBbqoznftc@q2TwbBR_$Sl1sf zMom(dfFR>0xp4Lny8>D9n&lAhMHfD({ki|V% z5WZcd4xMxuSY+jt4aUf)5t6SuUm9j#oQLGVHd?h4WUeVWWuvisIu5*Q>ZC0^UL8gf z&u11{_T6l>tljJC(+7tbog4odwWdt6m_b+YpYIV-4UkfBi;7{FHeOb|a0@Mq%82s% zUCouvE-ujR2(OQ>*ARWd2Uzv_kRK{Q?tHU^ z`=+2LJen#bXcfi;GL{}e-?Ga*18fxlIF>A#+Vv@Y<6EjvC?qT~+~g<#rs|sVx2Y7< zF@v7^ix_6qy;$DsLQ*6!fx|pWMM;Hr)R3x~ojVVUHXhRsUdC!Zf9&el8GT!m1caNa z{(djwuC471Y52KXg2%E| zKVB99nuwCj^d?6+tkX^=*`6odb<&B-*%nT_%~oWie$|6OO6i_?0#JgnJ!3grC|v$8AG zh2_-6Hv*Oar$rZimz&4MO|^I4KkqrXg{zQS{lB8!6M)W!i)Nlp4Deh!1L>2D%Ev0H HFG2qUd8Vx* literal 0 HcmV?d00001 diff --git a/documents/Screenshots/Linux/4.png b/documents/Screenshots/Linux/4.png new file mode 100644 index 0000000000000000000000000000000000000000..6e8a3b6c1e9a39d06bfc9ec0364db3b1f0b7a5bc GIT binary patch literal 16845 zcmbuHWmH_@?ry?G73 z!N8FF|9XHY(IFH3HQGs3&B@Bv)Z9?tN)3#K`3tMCH^2$>0>XcKK^=^P8?MsYA9R@7 zTv^S@(b+)U*w)(E$-!O5-0`o`D#~IETws5Hd~NU#=uAk#Bt?Xj-E>aZeU+6TIxap; zheO8t(?&$55YcE0{3Kuj5=oFzYM~frTVhsbhWUTKdBiX5W$dxv-nKYk5O_{nIHvrO zs-MA~EwFYP$oxTfZ&0--6@yCw4v{P`B7%vCD~5XpZTeeA&-D7uP%Iej)xW{`IHAC!U$Od)R%LTx4ArU;s% zfMWs#F-p3@0h}azrD5}=(RF~Z+VTG}G;s@Q7a0E8S%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the necessary tools to build shadPS4: +First and foremost, Clang 18 is the **recommended compiler** as it is used for official builds and CI. If you build with GCC, you might encounter issues — please report any you find. Additionally, if you choose to use GCC, please build shadPS4 with Clang at least once before creating an `[APP BUG]` issue or submitting a pull request. + +## Preparatory steps + +### Installing dependencies #### Debian & Ubuntu + ``` sudo apt install build-essential clang git cmake libasound2-dev libpulse-dev libopenal-dev libssl-dev zlib1g-dev libedit-dev libudev-dev libevdev-dev libsdl2-dev libjack-dev libsndio-dev qt6-base-dev qt6-tools-dev qt6-multimedia-dev libvulkan-dev vulkan-validationlayers ``` #### Fedora + ``` sudo dnf install clang git cmake libatomic alsa-lib-devel pipewire-jack-audio-connection-kit-devel openal-devel openssl-devel libevdev-devel libudev-devel libXext-devel qt6-qtbase-devel qt6-qtbase-private-devel qt6-qtmultimedia-devel qt6-qtsvg-devel qt6-qttools-devel vulkan-devel vulkan-validation-layers ``` #### Arch Linux + ``` sudo pacman -S base-devel clang git cmake sndio jack2 openal qt6-base qt6-declarative qt6-multimedia sdl2 vulkan-validation-layers ``` +**Note**: The `shadps4-git` AUR package is not maintained by any of the developers, and it uses GCC as the compiler as opposed to Clang. Use at your own discretion. #### OpenSUSE + ``` sudo zypper install clang git cmake libasound2 libpulse-devel libsndio7 libjack-devel openal-soft-devel libopenssl-devel zlib-devel libedit-devel systemd-devel libevdev-devel qt6-base-devel qt6-multimedia-devel qt6-svg-devel qt6-linguist-devel qt6-gui-private-devel vulkan-devel vulkan-validationlayers ``` -### Cloning and compiling: -Clone the repository recursively: +#### Other Linux distributions + +You can try one of two methods: + +- Search the packages by name and install them with your package manager, or +- Install [distrobox](https://distrobox.it/), create a container using any of the distributions cited above as a base, for Arch Linux you'd do: + +``` +distrobox create --name archlinux --init --image archlinux:latest +``` + +and install the dependencies on that container as cited above. +This option is **highly recommended** for NixOS and distributions with immutable/atomic filesystems (example: Fedora Kinoite, SteamOS). +### Cloning + ``` git clone --recursive https://github.com/shadps4-emu/shadPS4.git cd shadPS4 ``` -Generate the build directory in the shadPS4 directory. To disable the QT GUI, remove the ```-DENABLE_QT_GUI=ON``` flag: +## Building + +There are 3 options you can choose from. Option 1 is **highly recommended**. + +#### Option 1: Terminal-only + +1. Generate the build directory in the shadPS4 directory. -**Note**: Clang is the compiler used for official builds and CI. If you build with GCC, you might encounter issues—please report any you find. If you choose to use GCC, we recommend building with Clang at least once before submitting a pull request. ``` cmake -S . -B build/ -DENABLE_QT_GUI=ON -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ ``` -Enter the directory: +To disable the Qt GUI, remove the `-DENABLE_QT_GUI=ON` flag. To change the build type (for debugging), add `-DCMAKE_BUILD_TYPE=Debug`. + +2. Use CMake to build the project: + ``` -cd build/ +cmake --build ./build --parallel$(nproc) ``` -Use make to build the project: +If your computer freezes during this step, this could be caused by excessive system resource usage. In that case, remove `--parallel$(nproc)`. + +Now run the emulator. If Qt was enabled at configure time: + ``` -cmake --build . --parallel$(nproc) +./build/shadps4 ``` -Now run the emulator. If QT is enabled: -``` -./shadps4 -``` Otherwise, specify the path to your PKG's boot file: + ``` -./shadps4 /"PATH"/"TO"/"GAME"/"FOLDER"/eboot.bin +./build/shadps4 /"PATH"/"TO"/"GAME"/"FOLDER"/eboot.bin ``` + +You can also specify the Game ID as an argument for which game to boot, as long as the folder containing the games is specified in config.toml (example: Bloodborne (US) is CUSA00900). +#### Option 2: Configuring with cmake-gui + +`cmake-gui` should be installed by default alongside `cmake`, if not search for the package in your package manager and install it. + +Open `cmake-gui` and specify the source code and build directories. If you cloned the source code to your Home directory, it would be `/home/user/shadPS4` and `/home/user/shadPS4/build`. + +Click on Configure, select "Unix Makefiles", select "Specify native compilers", click Next and choose `clang` and `clang++` as the C and CXX compilers. Usually they are located in `/bin/clang` and `/bin/clang++`. Click on Finish and let it configure the project. + +Now every option should be displayed in red. Change anything you want, then click on Generate to make the changes permanent, then open a terminal window and do steps 2 and 3 of Option 1. + +#### Option 3: Visual Studio Code + +This option is pretty convoluted and should only be used if you have VSCode as your default IDE, or just prefer building and debugging projects through it. This also assumes that you're using an Arch Linux environment, as the naming for some options might differ from other distros. + +[Download Visual Studio Code for your platform](https://code.visualstudio.com/download), or use [Code - OSS](https://github.com/microsoft/vscode) if you'd like. Code - OSS is available on most Linux distributions' package repositories (on Arch Linux it is simply named `code`). + +Once set up, go to Extensions and install "CMake Tools": + +![image](https://raw.githubusercontent.com/shadps4-emu/shadPS4/refs/heads/main/documents/Screenshots/Linux/3.png) + +You can also install other CMake and Clang related extensions if you'd like, but this one is what enables you to configure and build CMake projects directly within VSCode. + +Go to Settings, filter by `@ext:ms-vscode.cmake-tools configure` and disable this option: + +![image](https://raw.githubusercontent.com/shadps4-emu/shadPS4/refs/heads/main/documents/Screenshots/Linux/1.png) + +If you wish to build with the Qt GUI, add `-DENABLE_QT_GUI=ON` to the configure arguments: + +![image](https://raw.githubusercontent.com/shadps4-emu/shadPS4/refs/heads/main/documents/Screenshots/Linux/2.png) + +On the CMake tab, change the options as you wish, but make sure that it looks similar to or exactly like this: + +![image](https://raw.githubusercontent.com/shadps4-emu/shadPS4/refs/heads/main/documents/Screenshots/Linux/4.png) + +When hovering over Project Status > Configure, there should be an icon titled "Configure". Click on it and let it configure the project, then do the same for Project Status > Build. + +If you want to debug it, change the build type under Project Status > Configure to Debug (it should be the default) and compile it, then click on the icon in Project Status > Debug. If you simply want to launch the shadPS4 executable from within VSCode, click on the icon in Project Status > Launch. + +Don't forget to change the launch target for both options to the shadPS4 executable inside shadPS4/build: + +![image](https://raw.githubusercontent.com/shadps4-emu/shadPS4/refs/heads/main/documents/Screenshots/Linux/5.png) \ No newline at end of file From d7c2cb17f3e1b339d78c5eb1bcb44e0305a85e89 Mon Sep 17 00:00:00 2001 From: panzone91 <150828896+panzone91@users.noreply.github.com> Date: Wed, 22 Jan 2025 21:53:54 +0000 Subject: [PATCH 41/99] update extension vector capacity (#2210) --- src/video_core/renderer_vulkan/vk_instance.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/video_core/renderer_vulkan/vk_instance.cpp b/src/video_core/renderer_vulkan/vk_instance.cpp index d183d6b09..a722b5322 100644 --- a/src/video_core/renderer_vulkan/vk_instance.cpp +++ b/src/video_core/renderer_vulkan/vk_instance.cpp @@ -232,7 +232,7 @@ bool Instance::CreateDevice() { return false; } - boost::container::static_vector enabled_extensions; + boost::container::static_vector enabled_extensions; const auto add_extension = [&](std::string_view extension) -> bool { const auto result = std::find_if(available_extensions.begin(), available_extensions.end(), From 1fcfb07421909ab779ee1a884b6a5ce0fb0fd4e3 Mon Sep 17 00:00:00 2001 From: DanielSvoboda Date: Wed, 22 Jan 2025 19:21:52 -0300 Subject: [PATCH 42/99] GUI: Settings improvements (#2213) --- src/common/config.cpp | 13 +- src/common/config.h | 2 + src/qt_gui/settings_dialog.cpp | 23 +- src/qt_gui/settings_dialog.ui | 1336 ++++++++++++++++++------------ src/qt_gui/translations/ar.ts | 18 +- src/qt_gui/translations/da_DK.ts | 18 +- src/qt_gui/translations/de.ts | 18 +- src/qt_gui/translations/el.ts | 18 +- src/qt_gui/translations/en.ts | 18 +- src/qt_gui/translations/es_ES.ts | 18 +- src/qt_gui/translations/fa_IR.ts | 18 +- src/qt_gui/translations/fi.ts | 18 +- src/qt_gui/translations/fr.ts | 18 +- src/qt_gui/translations/hu_HU.ts | 18 +- src/qt_gui/translations/id.ts | 18 +- src/qt_gui/translations/it.ts | 18 +- src/qt_gui/translations/ja_JP.ts | 18 +- src/qt_gui/translations/ko_KR.ts | 18 +- src/qt_gui/translations/lt_LT.ts | 18 +- src/qt_gui/translations/nb.ts | 18 +- src/qt_gui/translations/nl.ts | 18 +- src/qt_gui/translations/pl_PL.ts | 18 +- src/qt_gui/translations/pt_BR.ts | 24 +- src/qt_gui/translations/ro_RO.ts | 18 +- src/qt_gui/translations/ru_RU.ts | 18 +- src/qt_gui/translations/sq.ts | 18 +- src/qt_gui/translations/sv.ts | 18 +- src/qt_gui/translations/tr_TR.ts | 18 +- src/qt_gui/translations/uk_UA.ts | 18 +- src/qt_gui/translations/vi_VN.ts | 18 +- src/qt_gui/translations/zh_CN.ts | 18 +- src/qt_gui/translations/zh_TW.ts | 18 +- 32 files changed, 1339 insertions(+), 545 deletions(-) diff --git a/src/common/config.cpp b/src/common/config.cpp index 6e9db50ff..a57b6d35c 100644 --- a/src/common/config.cpp +++ b/src/common/config.cpp @@ -45,6 +45,7 @@ static std::string logFilter; static std::string logType = "async"; static std::string userName = "shadPS4"; static std::string updateChannel; +static std::string chooseHomeTab; static u16 deadZoneLeft = 2.0; static u16 deadZoneRight = 2.0; static std::string backButtonBehavior = "left"; @@ -194,6 +195,10 @@ std::string getUpdateChannel() { return updateChannel; } +std::string getChooseHomeTab() { + return chooseHomeTab; +} + std::string getBackButtonBehavior() { return backButtonBehavior; } @@ -399,6 +404,9 @@ void setUserName(const std::string& type) { void setUpdateChannel(const std::string& type) { updateChannel = type; } +void setChooseHomeTab(const std::string& type) { + chooseHomeTab = type; +} void setBackButtonBehavior(const std::string& type) { backButtonBehavior = type; @@ -637,6 +645,7 @@ void load(const std::filesystem::path& path) { compatibilityData = toml::find_or(general, "compatibilityEnabled", false); checkCompatibilityOnStartup = toml::find_or(general, "checkCompatibilityOnStartup", false); + chooseHomeTab = toml::find_or(general, "chooseHomeTab", "Release"); } if (data.contains("Input")) { @@ -760,6 +769,7 @@ void save(const std::filesystem::path& path) { data["General"]["logType"] = logType; data["General"]["userName"] = userName; data["General"]["updateChannel"] = updateChannel; + data["General"]["chooseHomeTab"] = chooseHomeTab; data["General"]["showSplash"] = isShowSplash; data["General"]["autoUpdate"] = isAutoUpdate; data["General"]["separateUpdateEnabled"] = separateupdatefolder; @@ -871,6 +881,7 @@ void setDefaultValues() { } else { updateChannel = "Nightly"; } + chooseHomeTab = "General"; cursorState = HideCursorState::Idle; cursorHideTimeout = 5; backButtonBehavior = "left"; @@ -898,4 +909,4 @@ void setDefaultValues() { checkCompatibilityOnStartup = false; } -} // namespace Config +} // namespace Config \ No newline at end of file diff --git a/src/common/config.h b/src/common/config.h index 564947f1e..15937606e 100644 --- a/src/common/config.h +++ b/src/common/config.h @@ -35,6 +35,7 @@ std::string getLogFilter(); std::string getLogType(); std::string getUserName(); std::string getUpdateChannel(); +std::string getChooseHomeTab(); u16 leftDeadZone(); u16 rightDeadZone(); @@ -81,6 +82,7 @@ void setLanguage(u32 language); void setNeoMode(bool enable); void setUserName(const std::string& type); void setUpdateChannel(const std::string& type); +void setChooseHomeTab(const std::string& type); void setSeparateUpdateEnabled(bool use); void setGameInstallDirs(const std::vector& settings_install_dirs_config); void setSaveDataPath(const std::filesystem::path& path); diff --git a/src/qt_gui/settings_dialog.cpp b/src/qt_gui/settings_dialog.cpp index 5695d6232..b41fde745 100644 --- a/src/qt_gui/settings_dialog.cpp +++ b/src/qt_gui/settings_dialog.cpp @@ -65,6 +65,7 @@ SettingsDialog::SettingsDialog(std::span physical_devices, : QDialog(parent), ui(new Ui::SettingsDialog) { ui->setupUi(this); ui->tabWidgetSettings->setUsesScrollButtons(false); + initialHeight = this->height(); const auto config_dir = Common::FS::GetUserPath(Common::FS::PathType::UserDir); @@ -150,7 +151,6 @@ SettingsDialog::SettingsDialog(std::span physical_devices, }); #else ui->updaterGroupBox->setVisible(false); - ui->GUIgroupBox->setMaximumSize(265, 16777215); #endif connect(ui->updateCompatibilityButton, &QPushButton::clicked, this, [this, parent, m_compat_info]() { @@ -169,6 +169,11 @@ SettingsDialog::SettingsDialog(std::span physical_devices, }); } + // Gui TAB + { + connect(ui->chooseHomeTabComboBox, &QComboBox::currentTextChanged, this, + [](const QString& hometab) { Config::setChooseHomeTab(hometab.toStdString()); }); + } // Input TAB { connect(ui->hideCursorComboBox, QOverload::of(&QComboBox::currentIndexChanged), this, @@ -246,7 +251,7 @@ SettingsDialog::SettingsDialog(std::span physical_devices, #ifdef ENABLE_UPDATER ui->updaterGroupBox->installEventFilter(this); #endif - ui->GUIgroupBox->installEventFilter(this); + ui->GUIMusicGroupBox->installEventFilter(this); ui->disableTrophycheckBox->installEventFilter(this); ui->enableCompatibilityCheckBox->installEventFilter(this); ui->checkCompatibilityOnStartupCheckBox->installEventFilter(this); @@ -373,6 +378,15 @@ void SettingsDialog::LoadValuesFromConfig() { ui->updateComboBox->setCurrentText(QString::fromStdString(updateChannel)); #endif + std::string chooseHomeTab = toml::find_or(data, "General", "chooseHomeTab", ""); + ui->chooseHomeTabComboBox->setCurrentText(QString::fromStdString(chooseHomeTab)); + QStringList tabNames = {tr("General"), tr("Gui"), tr("Graphics"), tr("User"), + tr("Input"), tr("Paths"), tr("Debug")}; + QString chooseHomeTabQString = QString::fromStdString(chooseHomeTab); + int indexTab = tabNames.indexOf(chooseHomeTabQString); + indexTab = (indexTab == -1) ? 0 : indexTab; + ui->tabWidgetSettings->setCurrentIndex(indexTab); + QString backButtonBehavior = QString::fromStdString( toml::find_or(data, "Input", "backButtonBehavior", "left")); int index = ui->backButtonBehaviorComboBox->findData(backButtonBehavior); @@ -476,8 +490,8 @@ void SettingsDialog::updateNoteTextEdit(const QString& elementName) { } else if (elementName == "updaterGroupBox") { text = tr("updaterGroupBox"); #endif - } else if (elementName == "GUIgroupBox") { - text = tr("GUIgroupBox"); + } else if (elementName == "GUIMusicGroupBox") { + text = tr("GUIMusicGroupBox"); } else if (elementName == "disableTrophycheckBox") { text = tr("disableTrophycheckBox"); } else if (elementName == "enableCompatibilityCheckBox") { @@ -592,6 +606,7 @@ void SettingsDialog::UpdateSettings() { Config::setRdocEnabled(ui->rdocCheckBox->isChecked()); Config::setAutoUpdate(ui->updateCheckBox->isChecked()); Config::setUpdateChannel(ui->updateComboBox->currentText().toStdString()); + Config::setChooseHomeTab(ui->chooseHomeTabComboBox->currentText().toStdString()); Config::setCompatibilityEnabled(ui->enableCompatibilityCheckBox->isChecked()); Config::setCheckCompatibilityOnStartup(ui->checkCompatibilityOnStartupCheckBox->isChecked()); diff --git a/src/qt_gui/settings_dialog.ui b/src/qt_gui/settings_dialog.ui index d72a56973..5da6a8198 100644 --- a/src/qt_gui/settings_dialog.ui +++ b/src/qt_gui/settings_dialog.ui @@ -12,11 +12,11 @@ 0 0 970 - 820 + 600 - + 0 0 @@ -52,8 +52,14 @@ 0 + + + 0 + 0 + + - 3 + 0 @@ -67,8 +73,8 @@ 0 0 - 771 - 606 + 946 + 386 @@ -77,14 +83,56 @@ 0 - + + 6 + + + + 0 + + + 0 + + + 0 + + + + 0 + 0 + + Emulator - + + Qt::AlignmentFlag::AlignBottom|Qt::AlignmentFlag::AlignLeading|Qt::AlignmentFlag::AlignLeft + + + false + + + false + + + + 6 + + + 9 + + + 9 + + + 9 + + + 9 + @@ -106,7 +154,7 @@ - + 0 0 @@ -149,215 +197,40 @@ - - - - 6 - - - 0 - - - - - - - Username - - - - - - - - - - - - - - + + + + 6 + + + 0 + - + - + 0 0 - + 0 0 - - GUI Settings - - - - 1 - - - 11 - - - - - Show Game Size In List - - - - - - - - 0 - 0 - - - - Play title music - - - - - - - 1 - - - 0 - - - - - - 0 - 0 - - - - - 16777215 - 16777215 - - - - Volume - - - - - - - Set the volume of the background music. - - - 100 - - - 10 - - - 20 - - - 50 - - - Qt::Orientation::Horizontal - - - false - - - false - - - QSlider::TickPosition::NoTicks - - - 10 - - - - - - - - - 6 - - - 0 - - - 50 - - - - - - - Trophy - - - - - - Disable Trophy Pop-ups - - - - - - - Trophy Key - - - - - - - - 0 - 0 - - - - - 10 - false - - - - - - - - - - - - - - - - - - - - System + + 70 + @@ -387,6 +260,45 @@ + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + @@ -432,16 +344,16 @@ - 10 + 6 - 1 + 9 - 11 + 9 - 190 + 80 @@ -508,7 +420,7 @@ - + 0 0 @@ -554,8 +466,255 @@ - + + + + + + + + true + + + Gui + + + + + 0 + 0 + 946 + 386 + + + + + + + 0 + + + 0 + + + + + 0 + + + + + + 0 + 0 + + + + + 0 + 0 + + + + GUI Settings + + + + 9 + + + 9 + + + + + Default tab when opening settings + + + + + + + 0 + 0 + + + + + General + + + + + Gui + + + + + Graphics + + + + + User + + + + + Input + + + + + Paths + + + + + Debug + + + + + + + + + + + Show Game Size In List + + + + + + + + 0 + 0 + + + + + 11 + false + true + + + + false + + + + + + false + + + + + 10 + 80 + 416 + 29 + + + + + 0 + 0 + + + + Set the volume of the background music. + + + 100 + + + 10 + + + 20 + + + 50 + + + Qt::Orientation::Horizontal + + + false + + + false + + + QSlider::TickPosition::NoTicks + + + 10 + + + + + + 10 + 22 + 416 + 26 + + + + + 0 + 0 + + + + Play title music + + + + + + 10 + 54 + 416 + 20 + + + + + 0 + 0 + + + + + 16777215 + 16777215 + + + + Volume + + + + + + + + + + + + 6 + + + 210 + @@ -570,6 +729,12 @@ 0 + + + 0 + 0 + + Game Compatibility @@ -578,10 +743,10 @@ 10 - 1 + 9 - 11 + 9 @@ -632,6 +797,394 @@ + + + true + + + Graphics + + + + + 0 + 0 + 946 + 386 + + + + + + + + + + + Graphics Device + + + + + + + + + Enable NULL GPU + + + + + + + + + + + 0 + + + 0 + + + 0 + + + 0 + + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + + + + + + + + + + + + 6 + + + 0 + + + + + + + Width + + + + + + true + + + QAbstractSpinBox::CorrectionMode::CorrectToNearestValue + + + false + + + 0 + + + 9999 + + + 1280 + + + + + + + + + + Height + + + + + + true + + + true + + + QAbstractSpinBox::CorrectionMode::CorrectToNearestValue + + + false + + + 0 + + + 9999 + + + 720 + + + + + + + + + + Vblank Divider + + + + + + true + + + true + + + QAbstractSpinBox::CorrectionMode::CorrectToNearestValue + + + false + + + 1 + + + 9999 + + + 1 + + + + + + + + + + + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + + + + + + + 12 + + + 12 + + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + + + + + + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + + + + + + + true + + + User + + + + + 0 + 0 + 946 + 386 + + + + + + + 0 + + + 0 + + + + + + + Username + + + + + + + + + + + + + + Qt::Orientation::Horizontal + + + + 40 + 40 + + + + + + + + + + 6 + + + 0 + + + 50 + + + + + + + Trophy + + + + + + Disable Trophy Pop-ups + + + + + + + Trophy Key + + + + + + + + 0 + 0 + + + + + 10 + false + + + + + + + + + + + Qt::Orientation::Horizontal + + + + 40 + 20 + + + + + + + + + + + + Qt::Orientation::Vertical + + + QSizePolicy::Policy::MinimumExpanding + + + + 0 + 0 + + + + + + + true @@ -644,8 +1197,8 @@ 0 0 - 455 - 252 + 946 + 386 @@ -916,260 +1469,6 @@ - - - true - - - Graphics - - - - - 0 - 0 - 579 - 194 - - - - - - - - - - - Graphics Device - - - - - - - - - - - - - 0 - - - 0 - - - 0 - - - 0 - - - - - - - - - - - - 6 - - - 0 - - - - - - - Width - - - - - - true - - - QAbstractSpinBox::CorrectionMode::CorrectToNearestValue - - - false - - - 0 - - - 9999 - - - 1280 - - - - - - - - - - Height - - - - - - true - - - true - - - QAbstractSpinBox::CorrectionMode::CorrectToNearestValue - - - false - - - 0 - - - 9999 - - - 720 - - - - - - - - - - - - - - 6 - - - 0 - - - - - - - Vblank Divider - - - - - - true - - - true - - - QAbstractSpinBox::CorrectionMode::CorrectToNearestValue - - - false - - - 1 - - - 9999 - - - 1 - - - - - - - - - - - - - - - - 12 - - - 12 - - - - - true - - - Advanced - - - Qt::AlignmentFlag::AlignLeading|Qt::AlignmentFlag::AlignLeft|Qt::AlignmentFlag::AlignTop - - - - - - Enable Shaders Dumping - - - - - - - Enable NULL GPU - - - - - - - - - - Qt::Orientation::Vertical - - - - 20 - 40 - - - - - - - - - - - - Qt::Orientation::Vertical - - - - 20 - 40 - - - - - - - true @@ -1178,6 +1477,14 @@ Paths + + + 0 + 0 + 946 + 386 + + @@ -1186,34 +1493,34 @@ - - - - - Add... - - - - - - - Remove - - - - - - - Qt::Horizontal - - - - 40 - 20 - - - - + + + + + Add... + + + + + + + Remove + + + + + + + Qt::Orientation::Horizontal + + + + 40 + 20 + + + + @@ -1225,27 +1532,27 @@ - Save Data Path + Save Data Path - - - - - - true - - - - - - - Browse - - - - - + + + + + + true + + + + + + + Browse + + + + + @@ -1264,13 +1571,13 @@ 0 0 - 510 - 269 + 946 + 386 - + 0 @@ -1291,6 +1598,13 @@ Qt::AlignmentFlag::AlignLeading|Qt::AlignmentFlag::AlignLeft|Qt::AlignmentFlag::AlignTop + + + + Enable Shaders Dumping + + + diff --git a/src/qt_gui/translations/ar.ts b/src/qt_gui/translations/ar.ts index 47bd673b2..f7b93028a 100644 --- a/src/qt_gui/translations/ar.ts +++ b/src/qt_gui/translations/ar.ts @@ -540,10 +540,18 @@ Enable Fullscreen تمكين ملء الشاشة + + Fullscreen Mode + وضع ملء الشاشة + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + علامة التبويب الافتراضية عند فتح الإعدادات + Show Game Size In List عرض حجم اللعبة في القائمة @@ -620,6 +628,14 @@ Graphics الرسومات + + Gui + واجهة + + + User + مستخدم + Graphics Device جهاز الرسومات @@ -805,7 +821,7 @@ تحديث: Release: إصدارات رسمية تصدر شهريًا، قد تكون قديمة بعض الشيء، لكنها أكثر استقرارًا واختبارًا. Nightly: إصدارات تطوير تحتوي على أحدث الميزات والإصلاحات، لكنها قد تحتوي على أخطاء وأقل استقرارًا. - GUIgroupBox + GUIMusicGroupBox تشغيل موسيقى العنوان:\nإذا كانت اللعبة تدعم ذلك، قم بتمكين تشغيل موسيقى خاصة عند اختيار اللعبة في واجهة المستخدم. diff --git a/src/qt_gui/translations/da_DK.ts b/src/qt_gui/translations/da_DK.ts index 91a98abd4..61d2f68bf 100644 --- a/src/qt_gui/translations/da_DK.ts +++ b/src/qt_gui/translations/da_DK.ts @@ -540,10 +540,18 @@ Enable Fullscreen Enable Fullscreen + + Fullscreen Mode + Fuldskærmstilstand + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Standardfaneblad ved åbning af indstillinger + Show Game Size In List Vis vis spilstørrelse i listen @@ -620,6 +628,14 @@ Graphics Graphics + + Gui + Interface + + + User + Bruger + Graphics Device Graphics Device @@ -805,7 +821,7 @@ Opdatering:\nRelease: Officielle builds, der frigives månedligt, som kan være meget ældre, men mere stabile og testet.\nNightly: Udviklerbuilds med de nyeste funktioner og rettelser, men som kan indeholde fejl og være mindre stabile. - GUIgroupBox + GUIMusicGroupBox Titelsmusikafspilning:\nHvis spillet understøtter det, aktiver speciel musik, når spillet vælges i brugergrænsefladen. diff --git a/src/qt_gui/translations/de.ts b/src/qt_gui/translations/de.ts index b1e1d2664..9d99a7048 100644 --- a/src/qt_gui/translations/de.ts +++ b/src/qt_gui/translations/de.ts @@ -540,10 +540,18 @@ Enable Fullscreen Vollbild aktivieren + + Fullscreen Mode + Vollbildmodus + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Standardregisterkarte beim Öffnen der Einstellungen + Show Game Size In List Zeigen Sie die Spielgröße in der Liste @@ -620,6 +628,14 @@ Graphics Grafik + + Gui + Benutzeroberfläche + + + User + Benutzer + Graphics Device Grafikgerät @@ -805,7 +821,7 @@ Update:\nRelease: Offizielle Builds, die monatlich veröffentlicht werden, können viel älter sein, aber stabiler und getestet.\nNightly: Entwickler-Builds, die die neuesten Funktionen und Fehlerbehebungen enthalten, aber Fehler enthalten und weniger stabil sein können. - GUIgroupBox + GUIMusicGroupBox Wiedergabe der Titelmusik:\nWenn das Spiel dies unterstützt, wird beim Auswählen des Spiels in der Benutzeroberfläche spezielle Musik abgespielt. diff --git a/src/qt_gui/translations/el.ts b/src/qt_gui/translations/el.ts index ecda0ede0..66c3c07cd 100644 --- a/src/qt_gui/translations/el.ts +++ b/src/qt_gui/translations/el.ts @@ -540,10 +540,18 @@ Enable Fullscreen Enable Fullscreen + + Fullscreen Mode + Λειτουργία Πλήρους Οθόνης + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Προεπιλεγμένη καρτέλα κατά την ανοίγμα των ρυθμίσεων + Show Game Size In List Εμφάνιση Μεγέθους Παιχνιδιού στη Λίστα @@ -620,6 +628,14 @@ Graphics Graphics + + Gui + Διεπαφή + + + User + Χρήστης + Graphics Device Graphics Device @@ -805,7 +821,7 @@ Ενημερώσεις:\nRelease: Επίσημες εκδόσεις που κυκλοφορούν μηνιαίως, είναι παλαιότερες αλλά πιο σταθερές και δοκιμασμένες.\nNightly: Εκδόσεις προγραμματιστών με νέες δυνατότητες και διορθώσεις, αλλά μπορεί να περιέχουν σφάλματα και να είναι λιγότερο σταθερές. - GUIgroupBox + GUIMusicGroupBox Αναπαραγωγή Μουσικής Τίτλων:\nΕάν το παιχνίδι το υποστηρίζει, ενεργοποιεί ειδική μουσική κατά την επιλογή του παιχνιδιού από τη διεπαφή χρήστη. diff --git a/src/qt_gui/translations/en.ts b/src/qt_gui/translations/en.ts index dc72d97c9..8b6c3c69f 100644 --- a/src/qt_gui/translations/en.ts +++ b/src/qt_gui/translations/en.ts @@ -540,10 +540,18 @@ Enable Fullscreen Enable Fullscreen + + Fullscreen Mode + Fullscreen Mode + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Default tab when opening settings + Show Game Size In List Show Game Size In List @@ -620,6 +628,14 @@ Graphics Graphics + + Gui + Gui + + + User + User + Graphics Device Graphics Device @@ -805,7 +821,7 @@ Update:\nRelease: Official versions released every month that may be very outdated, but are more reliable and tested.\nNightly: Development versions that have all the latest features and fixes, but may contain bugs and are less stable. - GUIgroupBox + GUIMusicGroupBox Play Title Music:\nIf a game supports it, enable playing special music when selecting the game in the GUI. diff --git a/src/qt_gui/translations/es_ES.ts b/src/qt_gui/translations/es_ES.ts index a47f7c577..8f7a09b5d 100644 --- a/src/qt_gui/translations/es_ES.ts +++ b/src/qt_gui/translations/es_ES.ts @@ -540,10 +540,18 @@ Enable Fullscreen Habilitar pantalla completa + + Fullscreen Mode + Modo de Pantalla Completa + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Pestaña predeterminada al abrir la configuración + Show Game Size In List Mostrar Tamaño del Juego en la Lista @@ -620,6 +628,14 @@ Graphics Gráficos + + Gui + Interfaz + + + User + Usuario + Graphics Device Dispositivo gráfico @@ -805,7 +821,7 @@ Actualización:\nRelease: Versiones oficiales lanzadas cada mes que pueden estar muy desactualizadas, pero son más confiables y están probadas.\nNightly: Versiones de desarrollo que tienen todas las últimas funciones y correcciones, pero pueden contener errores y son menos estables. - GUIgroupBox + GUIMusicGroupBox Reproducir Música del Título:\nSi un juego lo admite, habilita la reproducción de música especial al seleccionar el juego en la interfaz gráfica. diff --git a/src/qt_gui/translations/fa_IR.ts b/src/qt_gui/translations/fa_IR.ts index 976e7614e..043d782c2 100644 --- a/src/qt_gui/translations/fa_IR.ts +++ b/src/qt_gui/translations/fa_IR.ts @@ -540,10 +540,18 @@ Enable Fullscreen تمام صفحه + + Fullscreen Mode + حالت تمام صفحه + Enable Separate Update Folder فعال‌سازی پوشه جداگانه برای به‌روزرسانی + + Default tab when opening settings + زبان پیش‌فرض هنگام باز کردن تنظیمات + Show Game Size In List نمایش اندازه بازی در لیست @@ -620,6 +628,14 @@ Graphics گرافیک + + Gui + رابط کاربری + + + User + کاربر + Graphics Device کارت گرافیک مورداستفاده @@ -805,7 +821,7 @@ به‌روزرسانی:\nانتشار: نسخه‌های رسمی که هر ماه منتشر می‌شوند و ممکن است بسیار قدیمی باشند، اما پایدارتر و تست‌ شده‌تر هستند.\nشبانه: نسخه‌های توسعه‌ای که شامل جدیدترین ویژگی‌ها و اصلاحات هستند، اما ممکن است دارای اشکال باشند و کمتر پایدار باشند. - GUIgroupBox + GUIMusicGroupBox پخش موسیقی عنوان:\nIدر صورتی که بازی از آن پشتیبانی کند، پخش موسیقی ویژه هنگام انتخاب بازی در رابط کاربری را فعال می‌کند. diff --git a/src/qt_gui/translations/fi.ts b/src/qt_gui/translations/fi.ts index abc091b7e..86f6a6d3c 100644 --- a/src/qt_gui/translations/fi.ts +++ b/src/qt_gui/translations/fi.ts @@ -540,10 +540,18 @@ Enable Fullscreen Ota Käyttöön Koko Ruudun Tila + + Fullscreen Mode + Koko näytön tila + Enable Separate Update Folder Ota Käyttöön Erillinen Päivityshakemisto + + Default tab when opening settings + Oletusvälilehti avattaessa asetuksia + Show Game Size In List Näytä pelin koko luettelossa @@ -620,6 +628,14 @@ Graphics Grafiikka + + Gui + Rajapinta + + + User + Käyttäjä + Graphics Device Näytönohjain @@ -805,7 +821,7 @@ Päivitys:\nRelease: Viralliset versiot, jotka julkaistaan kuukausittain ja saattavat olla hyvin vanhoja, mutta ovat luotettavampia ja testatumpia.\nNightly: Kehitysversiot, joissa on kaikki uusimmat ominaisuudet ja korjaukset, mutta ne saattavat sisältää virheitä ja ovat vähemmän vakaita. - GUIgroupBox + GUIMusicGroupBox Soita Otsikkomusiikkia:\nJos peli tukee sitä, ota käyttöön erityisen musiikin soittaminen pelin valinnan yhteydessä käyttöliittymässä. diff --git a/src/qt_gui/translations/fr.ts b/src/qt_gui/translations/fr.ts index d2a1c5307..601ece8b4 100644 --- a/src/qt_gui/translations/fr.ts +++ b/src/qt_gui/translations/fr.ts @@ -540,10 +540,18 @@ Enable Fullscreen Plein écran + + Fullscreen Mode + Mode Plein Écran + Enable Separate Update Folder Dossier séparé pour les mises à jours + + Default tab when opening settings + Onglet par défaut lors de l'ouverture des paramètres + Show Game Size In List Afficher la taille du jeu dans la liste @@ -620,6 +628,14 @@ Graphics Graphismes + + Gui + Interface + + + User + Utilisateur + Graphics Device Carte graphique @@ -805,7 +821,7 @@ Mise à jour:\nRelease: versions officielles publiées chaque mois qui peuvent être très anciennes, mais plus fiables et testées.\nNightly: versions de développement avec toutes les dernières fonctionnalités et correctifs, mais pouvant avoir des bogues et être moins stables. - GUIgroupBox + GUIMusicGroupBox Jouer de la musique de titre:\nSi le jeu le prend en charge, cela active la musique spéciale lorsque vous sélectionnez le jeu dans l'interface utilisateur. diff --git a/src/qt_gui/translations/hu_HU.ts b/src/qt_gui/translations/hu_HU.ts index dff6a3a18..fe71e8120 100644 --- a/src/qt_gui/translations/hu_HU.ts +++ b/src/qt_gui/translations/hu_HU.ts @@ -540,10 +540,18 @@ Enable Fullscreen Teljes Képernyő Engedélyezése + + Fullscreen Mode + Teljes képernyős mód + Enable Separate Update Folder Külön Frissítési Mappa Engedélyezése + + Default tab when opening settings + Alapértelmezett fül a beállítások megnyitásakor + Show Game Size In List Játékméret megjelenítése a listában @@ -620,6 +628,14 @@ Graphics Grafika + + Gui + Felület + + + User + Felhasználó + Graphics Device Grafikai Eszköz @@ -805,7 +821,7 @@ Frissítés:\nRelease: Hivatalos verziók, amelyeket havonta adnak ki, és amelyek nagyon elavultak lehetnek, de megbízhatóbbak és teszteltek.\nNightly: Fejlesztési verziók, amelyek az összes legújabb funkciót és javítást tartalmazzák, de hibákat tartalmazhatnak és kevésbé stabilak. - GUIgroupBox + GUIMusicGroupBox Játék címzene lejátszása:\nHa a játék támogatja, engedélyezze egy speciális zene lejátszását, amikor a játékot kiválasztja a GUI-ban. diff --git a/src/qt_gui/translations/id.ts b/src/qt_gui/translations/id.ts index e6fb8b5aa..acfde43a7 100644 --- a/src/qt_gui/translations/id.ts +++ b/src/qt_gui/translations/id.ts @@ -540,10 +540,18 @@ Enable Fullscreen Enable Fullscreen + + Fullscreen Mode + Mode Layar Penuh + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Tab default saat membuka pengaturan + Show Game Size In List Tampilkan Ukuran Game di Daftar @@ -620,6 +628,14 @@ Graphics Graphics + + Gui + Antarmuka + + + User + Pengguna + Graphics Device Graphics Device @@ -805,7 +821,7 @@ Pembaruan:\nRelease: Versi resmi yang dirilis setiap bulan yang mungkin sangat ketinggalan zaman, tetapi lebih dapat diandalkan dan teruji.\nNightly: Versi pengembangan yang memiliki semua fitur dan perbaikan terbaru, tetapi mungkin mengandung bug dan kurang stabil. - GUIgroupBox + GUIMusicGroupBox Putar Musik Judul Permainan:\nJika permainan mendukungnya, aktifkan pemutaran musik khusus saat memilih permainan di GUI. diff --git a/src/qt_gui/translations/it.ts b/src/qt_gui/translations/it.ts index 73dbdc603..93c6233a6 100644 --- a/src/qt_gui/translations/it.ts +++ b/src/qt_gui/translations/it.ts @@ -540,10 +540,18 @@ Enable Fullscreen Abilita Schermo Intero + + Fullscreen Mode + Modalità Schermo Intero + Enable Separate Update Folder Abilita Cartella Aggiornamenti Separata + + Default tab when opening settings + Scheda predefinita all'apertura delle impostazioni + Show Game Size In List Mostra la dimensione del gioco nell'elenco @@ -620,6 +628,14 @@ Graphics Grafica + + Gui + Interfaccia + + + User + Utente + Graphics Device Scheda Grafica @@ -805,7 +821,7 @@ Aggiornamento:\nRelease: Versioni ufficiali rilasciate ogni mese che potrebbero essere molto datate, ma sono più affidabili e testate.\nNightly: Versioni di sviluppo che hanno tutte le ultime funzionalità e correzioni, ma potrebbero contenere bug e sono meno stabili. - GUIgroupBox + GUIMusicGroupBox Riproduci Musica del Titolo:\nSe un gioco lo supporta, attiva la riproduzione di musica speciale quando selezioni il gioco nell'interfaccia grafica. diff --git a/src/qt_gui/translations/ja_JP.ts b/src/qt_gui/translations/ja_JP.ts index bb9488a6b..921af52bb 100644 --- a/src/qt_gui/translations/ja_JP.ts +++ b/src/qt_gui/translations/ja_JP.ts @@ -540,10 +540,18 @@ Enable Fullscreen フルスクリーンを有効にする + + Fullscreen Mode + 全画面モード + Enable Separate Update Folder アップデートフォルダの分離を有効化 + + Default tab when opening settings + 設定を開くときのデフォルトタブ + Show Game Size In List ゲームサイズをリストに表示 @@ -620,6 +628,14 @@ Graphics グラフィックス + + Gui + インターフェース + + + User + ユーザー + Graphics Device グラフィックスデバイス @@ -805,7 +821,7 @@ 更新:\nRelease: 最新の機能を利用できない可能性がありますが、より信頼性が高くテストされた公式バージョンが毎月リリースされます。\nNightly: 最新の機能と修正がすべて含まれていますが、バグが含まれている可能性があり、安定性は低いです。 - GUIgroupBox + GUIMusicGroupBox タイトルミュージックを再生:\nゲームでサポートされている場合に、GUIでゲームを選択したときに特別な音楽を再生する機能を有効にします。 diff --git a/src/qt_gui/translations/ko_KR.ts b/src/qt_gui/translations/ko_KR.ts index 560b58340..2491959a6 100644 --- a/src/qt_gui/translations/ko_KR.ts +++ b/src/qt_gui/translations/ko_KR.ts @@ -540,10 +540,18 @@ Enable Fullscreen Enable Fullscreen + + Fullscreen Mode + 전체 화면 모드 + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + 설정 열기 시 기본 탭 + Show Game Size In List 게임 크기를 목록에 표시 @@ -620,6 +628,14 @@ Graphics Graphics + + Gui + 인터페이스 + + + User + 사용자 + Graphics Device Graphics Device @@ -805,7 +821,7 @@ Update:\nRelease: Official versions released every month that may be very outdated, but are more reliable and tested.\nNightly: Development versions that have all the latest features and fixes, but may contain bugs and are less stable. - GUIgroupBox + GUIMusicGroupBox Play Title Music:\nIf a game supports it, enable playing special music when selecting the game in the GUI. diff --git a/src/qt_gui/translations/lt_LT.ts b/src/qt_gui/translations/lt_LT.ts index e2ec1e5c3..23a52e948 100644 --- a/src/qt_gui/translations/lt_LT.ts +++ b/src/qt_gui/translations/lt_LT.ts @@ -540,10 +540,18 @@ Enable Fullscreen Enable Fullscreen + + Fullscreen Mode + Viso ekranas + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Numatytoji kortelė atidarius nustatymus + Show Game Size In List Rodyti žaidimo dydį sąraše @@ -620,6 +628,14 @@ Graphics Graphics + + Gui + Interfeisa + + + User + Naudotojas + Graphics Device Graphics Device @@ -805,7 +821,7 @@ Atnaujinti:\nRelease: Oficialios versijos, išleidžiamos kiekvieną mėnesį, kurios gali būti labai pasenusios, tačiau yra patikimos ir išbandytos.\nNightly: Vystymo versijos, kuriose yra visos naujausios funkcijos ir taisymai, tačiau gali turėti klaidų ir būti mažiau stabilios. - GUIgroupBox + GUIMusicGroupBox Groti antraščių muziką:\nJei žaidimas tai palaiko, įjungia specialios muzikos grojimą, kai pasirinkite žaidimą GUI. diff --git a/src/qt_gui/translations/nb.ts b/src/qt_gui/translations/nb.ts index b94d29b23..d6d4090df 100644 --- a/src/qt_gui/translations/nb.ts +++ b/src/qt_gui/translations/nb.ts @@ -540,10 +540,18 @@ Enable Fullscreen Aktiver fullskjerm + + Fullscreen Mode + Fullskjermmodus + Enable Separate Update Folder Aktiver seperat oppdateringsmappe + + Default tab when opening settings + Standardfanen når innstillingene åpnes + Show Game Size In List Vis spillstørrelse i listen @@ -620,6 +628,14 @@ Graphics Grafikk + + Gui + Grensesnitt + + + User + Bruker + Graphics Device Grafikkenhet @@ -805,7 +821,7 @@ Oppdatering:\nRelease: Offisielle versjoner utgitt hver måned som kan være veldig utdaterte, men er mer pålitelige og testet.\nNightly: Utviklingsversjoner som har alle de nyeste funksjonene og feilrettingene, men som kan inneholde feil og er mindre stabile. - GUIgroupBox + GUIMusicGroupBox Spille tittelmusikk:\nHvis et spill støtter det, så aktiveres det spesiell musikk når du velger spillet i menyen. diff --git a/src/qt_gui/translations/nl.ts b/src/qt_gui/translations/nl.ts index add27500f..1dabda8b4 100644 --- a/src/qt_gui/translations/nl.ts +++ b/src/qt_gui/translations/nl.ts @@ -540,10 +540,18 @@ Enable Fullscreen Enable Fullscreen + + Fullscreen Mode + Volledig schermmodus + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Standaardtabblad bij het openen van instellingen + Show Game Size In List Toon grootte van het spel in de lijst @@ -620,6 +628,14 @@ Graphics Graphics + + Gui + Interface + + + User + Gebruiker + Graphics Device Graphics Device @@ -805,7 +821,7 @@ Updateren:\nRelease: Officiële versies die elke maand worden uitgebracht, die zeer verouderd kunnen zijn, maar betrouwbaar en getest zijn.\nNightly: Ontwikkelingsversies die alle nieuwste functies en bugfixes bevatten, maar mogelijk bugs bevatten en minder stabiel zijn. - GUIgroupBox + GUIMusicGroupBox Speel titelsong:\nAls een game dit ondersteunt, wordt speciale muziek afgespeeld wanneer je het spel in de GUI selecteert. diff --git a/src/qt_gui/translations/pl_PL.ts b/src/qt_gui/translations/pl_PL.ts index 3280beea7..528e88337 100644 --- a/src/qt_gui/translations/pl_PL.ts +++ b/src/qt_gui/translations/pl_PL.ts @@ -540,10 +540,18 @@ Enable Fullscreen Włącz pełny ekran + + Fullscreen Mode + Tryb Pełnoekranowy + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Domyślna zakładka podczas otwierania ustawień + Show Game Size In List Pokaż rozmiar gry na liście @@ -620,6 +628,14 @@ Graphics Grafika + + Gui + Interfejs + + + User + Użytkownik + Graphics Device Karta graficzna @@ -805,7 +821,7 @@ Aktualizator:\nRelease: Oficjalne wersje wydawane co miesiąc, które mogą być bardzo przestarzałe, ale są niezawodne i przetestowane.\nNightly: Wersje rozwojowe, które zawierają wszystkie najnowsze funkcje i poprawki błędów, ale mogą mieć błędy i być mniej stabilne. - GUIgroupBox + GUIMusicGroupBox Odtwórz muzykę tytułową:\nJeśli gra to obsługuje, aktywuje odtwarzanie specjalnej muzyki podczas wybierania gry w GUI. diff --git a/src/qt_gui/translations/pt_BR.ts b/src/qt_gui/translations/pt_BR.ts index b9d889519..fde1d3b63 100644 --- a/src/qt_gui/translations/pt_BR.ts +++ b/src/qt_gui/translations/pt_BR.ts @@ -540,10 +540,18 @@ Enable Fullscreen Ativar Tela Cheia + + Fullscreen Mode + Modo de Tela Cheia + Enable Separate Update Folder Habilitar pasta de atualização separada + + Default tab when opening settings + Aba padrão ao abrir as configurações + Show Game Size In List Mostrar Tamanho do Jogo na Lista @@ -620,6 +628,14 @@ Graphics Gráficos + + Gui + Interface + + + User + Usuário + Graphics Device Placa de Vídeo @@ -766,7 +782,7 @@ fullscreenCheckBox - Ativar Tela Cheia:\nMove automaticamente a janela do jogo para o modo tela cheia.\nIsso pode ser alterado pressionando a tecla F11. + Ativar Tela Cheia:\nAltera a janela do jogo para o modo tela cheia.\nIsso pode ser alterado pressionando a tecla F11. separateUpdatesCheckBox @@ -805,7 +821,11 @@ Atualizações:\nRelease: Versões oficiais que são lançadas todo mês e podem ser bastante antigas, mas são mais confiáveis e testadas.\nNightly: Versões de desenvolvimento que têm todos os novos recursos e correções, mas podem ter bugs e ser instáveis. - GUIgroupBox + chooseHomeTabGroupBox + do menu. + + + GUIMusicGroupBox Reproduzir música de abertura:\nSe o jogo suportar, ativa a reprodução de uma música especial ao selecionar o jogo na interface do menu. diff --git a/src/qt_gui/translations/ro_RO.ts b/src/qt_gui/translations/ro_RO.ts index 00a9eb179..9791a7682 100644 --- a/src/qt_gui/translations/ro_RO.ts +++ b/src/qt_gui/translations/ro_RO.ts @@ -540,10 +540,18 @@ Enable Fullscreen Enable Fullscreen + + Fullscreen Mode + Mod Ecran Complet + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Tab-ul implicit la deschiderea setărilor + Show Game Size In List Afișează dimensiunea jocului în listă @@ -620,6 +628,14 @@ Graphics Graphics + + Gui + Interfață + + + User + Utilizator + Graphics Device Graphics Device @@ -805,7 +821,7 @@ Actualizare:\nRelease: Versiuni oficiale lansate în fiecare lună, care pot fi foarte învechite, dar sunt mai fiabile și testate.\nNightly: Versiuni de dezvoltare care conțin toate cele mai recente funcții și corecții, dar pot conține erori și sunt mai puțin stabile. - GUIgroupBox + GUIMusicGroupBox Redă muzica titlului:\nDacă un joc o suportă, activează redarea muzicii speciale când selectezi jocul în GUI. diff --git a/src/qt_gui/translations/ru_RU.ts b/src/qt_gui/translations/ru_RU.ts index 4c90450dd..6423f5ba4 100644 --- a/src/qt_gui/translations/ru_RU.ts +++ b/src/qt_gui/translations/ru_RU.ts @@ -540,10 +540,18 @@ Enable Fullscreen Полноэкранный режим + + Fullscreen Mode + Режим Полного Экран + Enable Separate Update Folder Отдельная папка обновлений + + Default tab when opening settings + Вкладка по умолчанию при открытии настроек + Show Game Size In List Показать размер игры в списке @@ -620,6 +628,14 @@ Graphics Графика + + Gui + Интерфейс + + + User + Пользователь + Graphics Device Графическое устройство @@ -805,7 +821,7 @@ Обновление:\nRelease: Официальные версии, которые выпускаются каждый месяц и могут быть очень старыми, но они более надежные и проверенные.\nNightly: Версии разработки, которые содержат все последние функции и исправления, но могут содержать ошибки и менее стабильны. - GUIgroupBox + GUIMusicGroupBox Играть заглавную музыку:\nВключает воспроизведение специальной музыки при выборе игры в списке, если она это поддерживает. diff --git a/src/qt_gui/translations/sq.ts b/src/qt_gui/translations/sq.ts index 768db1e75..2f88b4390 100644 --- a/src/qt_gui/translations/sq.ts +++ b/src/qt_gui/translations/sq.ts @@ -540,10 +540,18 @@ Enable Fullscreen Aktivizo Ekranin e plotë + + Fullscreen Mode + Modaliteti i Plotë + Enable Separate Update Folder Aktivizo dosjen e ndarë të përditësimit + + Default tab when opening settings + Skeda e parazgjedhur kur hapni cilësimet + Show Game Size In List Shfaq madhësinë e lojës në listë @@ -620,6 +628,14 @@ Graphics Grafika + + Gui + Ndërfaqe + + + User + Përdorues + Graphics Device Pajisja e Grafikës @@ -805,7 +821,7 @@ Përditësimi:\nRelease: Versionet zyrtare të lëshuara çdo muaj që mund të jenë shumë të vjetra, por janë më të besueshme dhe të provuara.\nNightly: Versionet e zhvillimit që kanë të gjitha veçoritë dhe rregullimet më të fundit, por mund të përmbajnë gabime dhe janë më pak të qëndrueshme. - GUIgroupBox + GUIMusicGroupBox Luaj muzikën e titullit:\nNëse një lojë e mbështet, aktivizohet luajtja e muzikës të veçantë kur të zgjidhësh lojën në GUI. diff --git a/src/qt_gui/translations/sv.ts b/src/qt_gui/translations/sv.ts index 3781ba45c..e17944f12 100644 --- a/src/qt_gui/translations/sv.ts +++ b/src/qt_gui/translations/sv.ts @@ -1032,10 +1032,18 @@ Enable Fullscreen Aktivera helskärm + + Fullscreen Mode + Helskärmsläge + Enable Separate Update Folder Aktivera separat uppdateringsmapp + + Default tab when opening settings + Standardflik när inställningar öppnas + Show Game Size In List Visa spelstorlek i listan @@ -1108,6 +1116,14 @@ Graphics Grafik + + Gui + Gränssnitt + + + User + Användare + Graphics Device Grafikenhet @@ -1285,7 +1301,7 @@ updaterGroupBox - GUIgroupBox + GUIMusicGroupBox Spela upp titelmusik:\nOm ett spel har stöd för det kan speciell musik spelas upp från spelet i gränssnittet diff --git a/src/qt_gui/translations/tr_TR.ts b/src/qt_gui/translations/tr_TR.ts index 5e8499073..6436278de 100644 --- a/src/qt_gui/translations/tr_TR.ts +++ b/src/qt_gui/translations/tr_TR.ts @@ -540,10 +540,18 @@ Enable Fullscreen Tam Ekranı Etkinleştir + + Fullscreen Mode + Tam Ekran Modu + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Ayarlar açıldığında varsayılan sekme + Show Game Size In List Göster oyun boyutunu listede @@ -620,6 +628,14 @@ Graphics Grafikler + + Gui + Arayüz + + + User + Kullanıcı + Graphics Device Grafik Cihazı @@ -805,7 +821,7 @@ Güncelleme:\nRelease: Her ay yayınlanan resmi sürümler; çok eski olabilirler, ancak daha güvenilirdir ve test edilmiştir.\nNightly: Tüm en son özellikler ve düzeltmeler ile birlikte geliştirme sürümleri; hatalar içerebilir ve daha az kararlıdırlar. - GUIgroupBox + GUIMusicGroupBox Başlık Müziklerini Çal:\nEğer bir oyun bunu destekliyorsa, GUI'de oyunu seçtiğinizde özel müziklerin çalmasını etkinleştirir. diff --git a/src/qt_gui/translations/uk_UA.ts b/src/qt_gui/translations/uk_UA.ts index a1c7e97e0..720ad5b99 100644 --- a/src/qt_gui/translations/uk_UA.ts +++ b/src/qt_gui/translations/uk_UA.ts @@ -540,10 +540,18 @@ Enable Fullscreen Увімкнути повноекранний режим + + Fullscreen Mode + Режим Повноекранний + Enable Separate Update Folder Увімкнути окрему папку оновлень + + Default tab when opening settings + Вкладка за замовчуванням при відкритті налаштувань + Show Game Size In List Показати розмір гри в списку @@ -620,6 +628,14 @@ Graphics Графіка + + Gui + Інтерфейс + + + User + Користувач + Graphics Device Графічний пристрій @@ -805,7 +821,7 @@ Оновлення:\nRelease: Офіційні версії, які випускаються щомісяця і можуть бути дуже старими, але вони більш надійні та перевірені.\nNightly: Версії для розробників, які мають усі найновіші функції та виправлення, але можуть містити помилки та є менш стабільними. - GUIgroupBox + GUIMusicGroupBox Грати заголовну музику:\nВмикає відтворення спеціальної музики під час вибору гри в списку, якщо вона це підтримує. diff --git a/src/qt_gui/translations/vi_VN.ts b/src/qt_gui/translations/vi_VN.ts index a579a1983..a81630fad 100644 --- a/src/qt_gui/translations/vi_VN.ts +++ b/src/qt_gui/translations/vi_VN.ts @@ -540,10 +540,18 @@ Enable Fullscreen Enable Fullscreen + + Fullscreen Mode + Chế độ Toàn màn hình + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + Tab mặc định khi mở cài đặt + Show Game Size In List Hiển thị Kích thước Game trong Danh sách @@ -620,6 +628,14 @@ Graphics Graphics + + Gui + Giao diện + + + User + Người dùng + Graphics Device Graphics Device @@ -805,7 +821,7 @@ Cập nhật:\nRelease: Các phiên bản chính thức được phát hành hàng tháng; có thể khá cũ nhưng đáng tin cậy hơn và đã được thử nghiệm.\nNightly: Các phiên bản phát triển có tất cả các tính năng và sửa lỗi mới nhất; có thể có lỗi và ít ổn định hơn. - GUIgroupBox + GUIMusicGroupBox Phát nhạc tiêu đề trò chơi:\nNếu một trò chơi hỗ trợ điều này, hãy kích hoạt phát nhạc đặc biệt khi bạn chọn trò chơi trong GUI. diff --git a/src/qt_gui/translations/zh_CN.ts b/src/qt_gui/translations/zh_CN.ts index 5450f3dfd..b06b0a286 100644 --- a/src/qt_gui/translations/zh_CN.ts +++ b/src/qt_gui/translations/zh_CN.ts @@ -540,10 +540,18 @@ Enable Fullscreen 启用全屏 + + Fullscreen Mode + 全屏模式 + Enable Separate Update Folder 启用单独的更新目录 + + Default tab when opening settings + 打开设置时的默认选项卡 + Show Game Size In List 显示游戏大小在列表中 @@ -620,6 +628,14 @@ Graphics 图像 + + Gui + 界面 + + + User + 用户 + Graphics Device 图形设备 @@ -805,7 +821,7 @@ 更新:\nRelease:每月发布的官方版本可能非常过时,但更可靠且经过测试。\nNightly:包含所有最新功能和修复的开发版本,但可能包含错误且稳定性较低。 - GUIgroupBox + GUIMusicGroupBox 播放标题音乐:\n如果游戏支持,在图形界面选择游戏时播放特殊音乐。 diff --git a/src/qt_gui/translations/zh_TW.ts b/src/qt_gui/translations/zh_TW.ts index 0ce0b4d69..9f6758797 100644 --- a/src/qt_gui/translations/zh_TW.ts +++ b/src/qt_gui/translations/zh_TW.ts @@ -540,10 +540,18 @@ Enable Fullscreen Enable Fullscreen + + Fullscreen Mode + 全螢幕模式 + Enable Separate Update Folder Enable Separate Update Folder + + Default tab when opening settings + 打開設置時的默認選項卡 + Show Game Size In List 顯示遊戲大小在列表中 @@ -620,6 +628,14 @@ Graphics Graphics + + Gui + 介面 + + + User + 使用者 + Graphics Device Graphics Device @@ -805,7 +821,7 @@ 更新:\nRelease: 每月發布的官方版本,可能非常舊,但更可靠且經過測試。\nNightly: 開發版本,擁有所有最新的功能和修復,但可能包含錯誤,穩定性較差。 - GUIgroupBox + GUIMusicGroupBox 播放標題音樂:\n如果遊戲支持,啟用在GUI中選擇遊戲時播放特殊音樂。 From 81e7e4b21646ad40edaae06f9b1e58eaea139b3c Mon Sep 17 00:00:00 2001 From: georgemoralis Date: Thu, 23 Jan 2025 00:52:22 +0200 Subject: [PATCH 43/99] Update building-linux.md --- documents/building-linux.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/documents/building-linux.md b/documents/building-linux.md index 2672c70f4..28b8c6056 100644 --- a/documents/building-linux.md +++ b/documents/building-linux.md @@ -99,7 +99,7 @@ Open `cmake-gui` and specify the source code and build directories. If you clone Click on Configure, select "Unix Makefiles", select "Specify native compilers", click Next and choose `clang` and `clang++` as the C and CXX compilers. Usually they are located in `/bin/clang` and `/bin/clang++`. Click on Finish and let it configure the project. -Now every option should be displayed in red. Change anything you want, then click on Generate to make the changes permanent, then open a terminal window and do steps 2 and 3 of Option 1. +Now every option should be displayed in red. Change anything you want, then click on Generate to make the changes permanent, then open a terminal window and do step 2 of Option 1. #### Option 3: Visual Studio Code @@ -131,4 +131,4 @@ If you want to debug it, change the build type under Project Status > Configure Don't forget to change the launch target for both options to the shadPS4 executable inside shadPS4/build: -![image](https://raw.githubusercontent.com/shadps4-emu/shadPS4/refs/heads/main/documents/Screenshots/Linux/5.png) \ No newline at end of file +![image](https://raw.githubusercontent.com/shadps4-emu/shadPS4/refs/heads/main/documents/Screenshots/Linux/5.png) From cc2e13873f9be4e2f95e4da7a71e7333502fa183 Mon Sep 17 00:00:00 2001 From: DanielSvoboda Date: Wed, 22 Jan 2025 22:21:41 -0300 Subject: [PATCH 44/99] Fix showing debug menu bar / Devtools (#2214) * Fix showing debug menu bar / Devtools * Fix --- src/core/debug_state.cpp | 2 ++ src/core/debug_state.h | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/core/debug_state.cpp b/src/core/debug_state.cpp index 6508a9875..23ebcbb9b 100644 --- a/src/core/debug_state.cpp +++ b/src/core/debug_state.cpp @@ -17,6 +17,8 @@ using namespace DebugStateType; DebugStateImpl& DebugState = *Common::Singleton::Instance(); +bool DebugStateType::showing_debug_menu_bar = false; + static ThreadID ThisThreadID() { #ifdef _WIN32 return GetCurrentThreadId(); diff --git a/src/core/debug_state.h b/src/core/debug_state.h index a9e6f48b7..217efd1a9 100644 --- a/src/core/debug_state.h +++ b/src/core/debug_state.h @@ -35,6 +35,8 @@ class ShaderList; namespace DebugStateType { +extern bool showing_debug_menu_bar; + enum class QueueType { dcb = 0, ccb = 1, @@ -131,8 +133,6 @@ class DebugStateImpl { friend class Core::Devtools::Widget::FrameGraph; friend class Core::Devtools::Widget::ShaderList; - bool showing_debug_menu_bar = false; - std::queue debug_message_popup; std::mutex guest_threads_mutex{}; From cef92fbcaad34e0caa90bc5afbce5e5b30c43636 Mon Sep 17 00:00:00 2001 From: DemoJameson Date: Thu, 23 Jan 2025 19:28:44 +0800 Subject: [PATCH 45/99] Update Simplified Chinese translation (#2216) * Update Simplified Chinese translation * Fix incorrect translation * Fix new line --- src/qt_gui/translations/zh_CN.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/qt_gui/translations/zh_CN.ts b/src/qt_gui/translations/zh_CN.ts index b06b0a286..16ae03f94 100644 --- a/src/qt_gui/translations/zh_CN.ts +++ b/src/qt_gui/translations/zh_CN.ts @@ -552,7 +552,7 @@ Default tab when opening settings 打开设置时的默认选项卡 - + Show Game Size In List 显示游戏大小在列表中 @@ -830,7 +830,7 @@ hideCursorGroupBox - 隐藏光标:\n选择光标何时消失:\n从不: 始终显示光标。\闲置: 光标在闲置若干秒后消失。\n始终: 始终显示光标。 + 隐藏光标:\n选择光标何时消失:\n从不: 从不隐藏光标。\n闲置:光标在闲置若干秒后消失。\n始终:始终隐藏光标。 idleTimeoutGroupBox @@ -928,6 +928,14 @@ rdocCheckBox 启用 RenderDoc 调试:\n启用后模拟器将提供与 Renderdoc 的兼容性,允许在渲染过程中捕获和分析当前渲染的帧。 + + saveDataBox + 存档数据路径:\n保存游戏存档数据的目录。 + + + browseButton + 浏览:\n选择一个目录保存游戏存档数据。 + CheatsPatches From fb738bc24739704abcc87d87f25dd6a241c9719d Mon Sep 17 00:00:00 2001 From: Angelo Rosa Date: Thu, 23 Jan 2025 05:54:42 -0800 Subject: [PATCH 46/99] Optimize workflows by caching `apt install` (#2212) * optimize apt caches * change on push syntax * removing comments and check time improvements on following pushes * add recursive submodule fetch * Revert "add recursive submodule fetch" This reverts commit b059bda3b88aa7d81e4bee3348c9104536b15fd2. * restore old push on everyhing rule * fix libfuse2 uncaching package * moving qt deps outside from caching directives --- .github/workflows/build.yml | 48 ++++++++++++++++++++++++++++++------- 1 file changed, 40 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3da7163dd..a49ffefe9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -24,20 +24,27 @@ jobs: runs-on: ubuntu-24.04 continue-on-error: true steps: + - uses: actions/checkout@v4 with: fetch-depth: 0 + - name: Install run: | wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - sudo add-apt-repository 'deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-18 main' - sudo apt update - sudo apt install clang-format-18 + + - uses: awalsh128/cache-apt-pkgs-action@latest + with: + packages: clang-format-18 + version: 1.0 + - name: Build env: COMMIT_RANGE: ${{ github.event.pull_request.base.sha }}..${{ github.event.pull_request.head.sha }} run: ./.ci/clang-format.sh - + + get-info: runs-on: ubuntu-24.04 outputs: @@ -282,7 +289,13 @@ jobs: submodules: recursive - name: Install dependencies - run: sudo apt-get update && sudo apt install -y libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev libfuse2 clang build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev + run: | + sudo apt install -y libfuse2 + + - uses: awalsh128/cache-apt-pkgs-action@latest + with: + packages: libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev clang build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev + version: 1.0 - name: Cache CMake Configuration uses: actions/cache@v4 @@ -338,7 +351,13 @@ jobs: submodules: recursive - name: Install dependencies - run: sudo apt-get update && sudo apt install -y libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev libfuse2 clang build-essential qt6-base-dev qt6-tools-dev qt6-multimedia-dev libasound2-dev libpulse-dev libopenal-dev libudev-dev + run: | + sudo apt install -y libfuse2 qt6-base-dev qt6-tools-dev qt6-multimedia-dev + + - uses: awalsh128/cache-apt-pkgs-action@latest + with: + packages: libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev clang build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev + version: 1.0 - name: Cache CMake Configuration uses: actions/cache@v4 @@ -385,7 +404,13 @@ jobs: submodules: recursive - name: Install dependencies - run: sudo apt-get update && sudo apt install -y libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev libfuse2 gcc-14 build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev + run: | + sudo apt install -y libfuse2 + + - uses: awalsh128/cache-apt-pkgs-action@latest + with: + packages: libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev gcc-14 build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev + version: 1.0 - name: Cache CMake Configuration uses: actions/cache@v4 @@ -421,7 +446,13 @@ jobs: submodules: recursive - name: Install dependencies - run: sudo apt-get update && sudo apt install -y libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev libfuse2 gcc-14 build-essential qt6-base-dev qt6-tools-dev qt6-multimedia-dev libasound2-dev libpulse-dev libopenal-dev libudev-dev + run: | + sudo apt install -y libfuse2 qt6-base-dev qt6-tools-dev qt6-multimedia-dev + + - uses: awalsh128/cache-apt-pkgs-action@latest + with: + packages: libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev gcc-14 build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev + version: 1.0 - name: Cache CMake Configuration uses: actions/cache@v4 @@ -443,7 +474,8 @@ jobs: key: ${{ env.cache-name }}-${{ hashFiles('**/CMakeLists.txt', 'cmake/**') }} - name: Configure CMake - run: cmake --fresh -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_INTERPROCEDURAL_OPTIMIZATION_RELEASE=ON -DCMAKE_C_COMPILER=gcc-14 -DCMAKE_CXX_COMPILER=g++-14 -DENABLE_QT_GUI=ON -DENABLE_UPDATER=ON -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache + run: | + cmake --fresh -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_INTERPROCEDURAL_OPTIMIZATION_RELEASE=ON -DCMAKE_C_COMPILER=gcc-14 -DCMAKE_CXX_COMPILER=g++-14 -DENABLE_QT_GUI=ON -DENABLE_UPDATER=ON -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache - name: Build run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} --parallel $(nproc) From 2e6c9b8f9866f48bd39dc35b25310e77e3fa89f6 Mon Sep 17 00:00:00 2001 From: georgemoralis Date: Thu, 23 Jan 2025 22:58:45 +0200 Subject: [PATCH 47/99] Revert "Optimize workflows by caching `apt install` (#2212)" (#2220) This reverts commit fb738bc24739704abcc87d87f25dd6a241c9719d. --- .github/workflows/build.yml | 48 +++++++------------------------------ 1 file changed, 8 insertions(+), 40 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a49ffefe9..3da7163dd 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -24,27 +24,20 @@ jobs: runs-on: ubuntu-24.04 continue-on-error: true steps: - - uses: actions/checkout@v4 with: fetch-depth: 0 - - name: Install run: | wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - sudo add-apt-repository 'deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-18 main' - - - uses: awalsh128/cache-apt-pkgs-action@latest - with: - packages: clang-format-18 - version: 1.0 - + sudo apt update + sudo apt install clang-format-18 - name: Build env: COMMIT_RANGE: ${{ github.event.pull_request.base.sha }}..${{ github.event.pull_request.head.sha }} run: ./.ci/clang-format.sh - - + get-info: runs-on: ubuntu-24.04 outputs: @@ -289,13 +282,7 @@ jobs: submodules: recursive - name: Install dependencies - run: | - sudo apt install -y libfuse2 - - - uses: awalsh128/cache-apt-pkgs-action@latest - with: - packages: libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev clang build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev - version: 1.0 + run: sudo apt-get update && sudo apt install -y libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev libfuse2 clang build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev - name: Cache CMake Configuration uses: actions/cache@v4 @@ -351,13 +338,7 @@ jobs: submodules: recursive - name: Install dependencies - run: | - sudo apt install -y libfuse2 qt6-base-dev qt6-tools-dev qt6-multimedia-dev - - - uses: awalsh128/cache-apt-pkgs-action@latest - with: - packages: libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev clang build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev - version: 1.0 + run: sudo apt-get update && sudo apt install -y libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev libfuse2 clang build-essential qt6-base-dev qt6-tools-dev qt6-multimedia-dev libasound2-dev libpulse-dev libopenal-dev libudev-dev - name: Cache CMake Configuration uses: actions/cache@v4 @@ -404,13 +385,7 @@ jobs: submodules: recursive - name: Install dependencies - run: | - sudo apt install -y libfuse2 - - - uses: awalsh128/cache-apt-pkgs-action@latest - with: - packages: libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev gcc-14 build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev - version: 1.0 + run: sudo apt-get update && sudo apt install -y libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev libfuse2 gcc-14 build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev - name: Cache CMake Configuration uses: actions/cache@v4 @@ -446,13 +421,7 @@ jobs: submodules: recursive - name: Install dependencies - run: | - sudo apt install -y libfuse2 qt6-base-dev qt6-tools-dev qt6-multimedia-dev - - - uses: awalsh128/cache-apt-pkgs-action@latest - with: - packages: libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev gcc-14 build-essential libasound2-dev libpulse-dev libopenal-dev libudev-dev - version: 1.0 + run: sudo apt-get update && sudo apt install -y libx11-dev libxext-dev libwayland-dev libdecor-0-dev libxkbcommon-dev libglfw3-dev libgles2-mesa-dev libfuse2 gcc-14 build-essential qt6-base-dev qt6-tools-dev qt6-multimedia-dev libasound2-dev libpulse-dev libopenal-dev libudev-dev - name: Cache CMake Configuration uses: actions/cache@v4 @@ -474,8 +443,7 @@ jobs: key: ${{ env.cache-name }}-${{ hashFiles('**/CMakeLists.txt', 'cmake/**') }} - name: Configure CMake - run: | - cmake --fresh -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_INTERPROCEDURAL_OPTIMIZATION_RELEASE=ON -DCMAKE_C_COMPILER=gcc-14 -DCMAKE_CXX_COMPILER=g++-14 -DENABLE_QT_GUI=ON -DENABLE_UPDATER=ON -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache + run: cmake --fresh -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_INTERPROCEDURAL_OPTIMIZATION_RELEASE=ON -DCMAKE_C_COMPILER=gcc-14 -DCMAKE_CXX_COMPILER=g++-14 -DENABLE_QT_GUI=ON -DENABLE_UPDATER=ON -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache - name: Build run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} --parallel $(nproc) From cdca420a2e8579832c7ebffb7ec2ed8f9e74030c Mon Sep 17 00:00:00 2001 From: georgemoralis Date: Thu, 23 Jan 2025 23:27:37 +0200 Subject: [PATCH 48/99] Update building-linux.md --- documents/building-linux.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/documents/building-linux.md b/documents/building-linux.md index 28b8c6056..eedcd6664 100644 --- a/documents/building-linux.md +++ b/documents/building-linux.md @@ -29,8 +29,7 @@ sudo dnf install clang git cmake libatomic alsa-lib-devel pipewire-jack-audio-co sudo pacman -S base-devel clang git cmake sndio jack2 openal qt6-base qt6-declarative qt6-multimedia sdl2 vulkan-validation-layers ``` -**Note**: The `shadps4-git` AUR package is not maintained by any of the developers, and it uses GCC as the compiler as opposed to Clang. Use at your own discretion. -#### OpenSUSE +**Note**: The `shadps4-git` AUR package is not maintained by any of the developers, and it uses the default compiler, which is often set to GCC. Use at your own discretion.#### OpenSUSE ``` sudo zypper install clang git cmake libasound2 libpulse-devel libsndio7 libjack-devel openal-soft-devel libopenssl-devel zlib-devel libedit-devel systemd-devel libevdev-devel qt6-base-devel qt6-multimedia-devel qt6-svg-devel qt6-linguist-devel qt6-gui-private-devel vulkan-devel vulkan-validationlayers From 0ebe817a28afc14511578d183f8ef2afce3905aa Mon Sep 17 00:00:00 2001 From: georgemoralis Date: Thu, 23 Jan 2025 23:46:15 +0200 Subject: [PATCH 49/99] Update building-linux.md --- documents/building-linux.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documents/building-linux.md b/documents/building-linux.md index eedcd6664..2342e9afc 100644 --- a/documents/building-linux.md +++ b/documents/building-linux.md @@ -29,7 +29,7 @@ sudo dnf install clang git cmake libatomic alsa-lib-devel pipewire-jack-audio-co sudo pacman -S base-devel clang git cmake sndio jack2 openal qt6-base qt6-declarative qt6-multimedia sdl2 vulkan-validation-layers ``` -**Note**: The `shadps4-git` AUR package is not maintained by any of the developers, and it uses the default compiler, which is often set to GCC. Use at your own discretion.#### OpenSUSE +**Note** : The `shadps4-git` AUR package is not maintained by any of the developers, and it uses the default compiler, which is often set to GCC. Use at your own discretion.#### OpenSUSE ``` sudo zypper install clang git cmake libasound2 libpulse-devel libsndio7 libjack-devel openal-soft-devel libopenssl-devel zlib-devel libedit-devel systemd-devel libevdev-devel qt6-base-devel qt6-multimedia-devel qt6-svg-devel qt6-linguist-devel qt6-gui-private-devel vulkan-devel vulkan-validationlayers From cc4ddd28c3f3cfe978a0be75131a99ca4e86851b Mon Sep 17 00:00:00 2001 From: Log3rinioo <80830849+Log3rinioo@users.noreply.github.com> Date: Thu, 23 Jan 2025 22:56:06 +0100 Subject: [PATCH 50/99] Add missing Polish translations and fix typos (#2222) --- src/qt_gui/translations/pl_PL.ts | 86 ++++++++++++++++---------------- 1 file changed, 43 insertions(+), 43 deletions(-) diff --git a/src/qt_gui/translations/pl_PL.ts b/src/qt_gui/translations/pl_PL.ts index 528e88337..85eb63bfb 100644 --- a/src/qt_gui/translations/pl_PL.ts +++ b/src/qt_gui/translations/pl_PL.ts @@ -52,7 +52,7 @@ Select which directory you want to install to. - Select which directory you want to install to. + Wybierz katalog, do którego chcesz zainstalować. @@ -130,35 +130,35 @@ Delete... - Delete... + Usuń... Delete Game - Delete Game + Usuń Grę Delete Update - Delete Update + Usuń Aktualizację Delete DLC - Delete DLC + Usuń DLC Compatibility... - Compatibility... + kompatybilność... Update database - Update database + Zaktualizuj bazę danych View report - View report + Wyświetl zgłoszenie Submit a report - Submit a report + Wyślij zgłoszenie Shortcut creation @@ -182,23 +182,23 @@ Game - Game + Gra requiresEnableSeparateUpdateFolder_MSG - This feature requires the 'Enable Separate Update Folder' config option to work. If you want to use this feature, please enable it. + Ta funkcja wymaga do działania opcji „Włącz oddzielny folder aktualizacji”. Jeśli chcesz korzystać z tej funkcji, włącz ją. This game has no update to delete! - This game has no update to delete! + Ta gra nie ma aktualizacji do usunięcia! Update - Update + Aktualizacja This game has no DLC to delete! - This game has no DLC to delete! + Ta gra nie ma DLC do usunięcia! DLC @@ -206,11 +206,11 @@ Delete %1 - Delete %1 + Usuń %1 Are you sure you want to delete %1's %2 directory? - Are you sure you want to delete %1's %2 directory? + Czy na pewno chcesz usunąć katalog %1 z %2? @@ -249,7 +249,7 @@ Open shadPS4 Folder - Open shadPS4 Folder + Otwórz folder shadPS4 Exit @@ -546,7 +546,7 @@ Enable Separate Update Folder - Enable Separate Update Folder + Włącz oddzielny folder aktualizacji Default tab when opening settings @@ -574,11 +574,11 @@ Trophy Key - Trophy Key + Klucz trofeów Trophy - Trophy + Trofeum Logger @@ -722,7 +722,7 @@ Disable Trophy Pop-ups - Disable Trophy Pop-ups + Wyłącz wyskakujące okienka trofeów Play title music @@ -730,19 +730,19 @@ Update Compatibility Database On Startup - Update Compatibility Database On Startup + Aktualizuj bazę danych zgodności podczas uruchamiania Game Compatibility - Game Compatibility + Kompatybilność gier Display Compatibility Data - Display Compatibility Data + Wyświetl dane zgodności Update Compatibility Database - Update Compatibility Database + Aktualizuj bazę danych zgodności Volume @@ -750,7 +750,7 @@ Audio Backend - Audio Backend + Zaplecze audio Save @@ -786,7 +786,7 @@ separateUpdatesCheckBox - Enable Separate Update Folder:\nEnables installing game updates into a separate folder for easy management. + Włącz oddzielny folder aktualizacji:\nUmożliwia instalowanie aktualizacji gier w oddzielnym folderze w celu łatwego zarządzania. showSplashCheckBox @@ -798,7 +798,7 @@ discordRPCCheckbox - Włącz Discord Rich Presence:\nWyświetla ikonę emuladora i odpowiednie informacje na twoim profilu Discord. + Włącz Discord Rich Presence:\nWyświetla ikonę emulatora i odpowiednie informacje na twoim profilu Discord. userName @@ -806,7 +806,7 @@ TrophyKey - Trophy Key:\nKey used to decrypt trophies. Must be obtained from your jailbroken console.\nMust contain only hex characters. + Klucz trofeów:\nKlucz używany do odszyfrowywania trofeów. Musi być uzyskany z konsoli po jailbreaku. Musi zawierać tylko znaki w kodzie szesnastkowym. logTypeGroupBox @@ -826,7 +826,7 @@ disableTrophycheckBox - Disable Trophy Pop-ups:\nDisable in-game trophy notifications. Trophy progress can still be tracked using the Trophy Viewer (right-click the game in the main window). + Wyłącz wyskakujące okienka trofeów:\nWyłącz powiadomienia o trofeach w grze. Postępy w zdobywaniu trofeów można nadal śledzić za pomocą przeglądarki trofeów (kliknij prawym przyciskiem myszy grę w oknie głównym). hideCursorGroupBox @@ -842,15 +842,15 @@ enableCompatibilityCheckBox - Display Compatibility Data:\nDisplays game compatibility information in table view. Enable "Update Compatibility On Startup" to get up-to-date information. + Wyświetl dane zgodności:\nWyświetla informacje o kompatybilności gry w widoku tabeli. Włącz opcję „Aktualizuj zgodność przy uruchomieniu”, aby uzyskać aktualne informacje. checkCompatibilityOnStartupCheckBox - Update Compatibility On Startup:\nAutomatically update the compatibility database when shadPS4 starts. + Aktualizuj zgodność przy uruchomieniu:\nAutomatycznie aktualizuj bazę danych kompatybilności podczas uruchamiania shadPS4. updateCompatibilityButton - Update Compatibility Database:\nImmediately update the compatibility database. + Zaktualizuj bazę danych zgodności:\nNatychmiast zaktualizuj bazę danych zgodności. Never @@ -933,7 +933,7 @@ CheatsPatches Cheats / Patches for - Cheats / Patches for + Kody / Łatki dla defaultTextEdit_MSG @@ -1145,7 +1145,7 @@ Failed to parse JSON: - Nie udało się przeanlizować JSON: + Nie udało się przeanalizować JSON: Can't apply cheats before the game is started @@ -1168,7 +1168,7 @@ Compatibility - Compatibility + Zgodność Region @@ -1196,7 +1196,7 @@ Never Played - Never Played + Nigdy nie grane h @@ -1212,27 +1212,27 @@ Compatibility is untested - Compatibility is untested + Kompatybilność nie została przetestowana Game does not initialize properly / crashes the emulator - Game does not initialize properly / crashes the emulator + Gra nie inicjuje się poprawnie / zawiesza się emulator Game boots, but only displays a blank screen - Game boots, but only displays a blank screen + Gra uruchamia się, ale wyświetla tylko pusty ekran Game displays an image but does not go past the menu - Game displays an image but does not go past the menu + Gra wyświetla obraz, ale nie przechodzi do menu Game has game-breaking glitches or unplayable performance - Game has game-breaking glitches or unplayable performance + Gra ma usterki przerywające rozgrywkę lub niegrywalną wydajność Game can be completed with playable performance and no major glitches - Game can be completed with playable performance and no major glitches + Grę można ukończyć z grywalną wydajnością i bez większych usterek From e652369f22fc7cbdd456ce338dd1dae0974c69a4 Mon Sep 17 00:00:00 2001 From: georgemoralis Date: Thu, 23 Jan 2025 23:58:43 +0200 Subject: [PATCH 51/99] sdl3 update (#2221) --- externals/MoltenVK/MoltenVK | 2 +- externals/sdl3 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/externals/MoltenVK/MoltenVK b/externals/MoltenVK/MoltenVK index 9f0b616d9..2473ce6f0 160000 --- a/externals/MoltenVK/MoltenVK +++ b/externals/MoltenVK/MoltenVK @@ -1 +1 @@ -Subproject commit 9f0b616d9e2c39464d2a859b79dbc655c4a30e7e +Subproject commit 2473ce6f0ab7d5d8a49aa91b2e37f3447a939f18 diff --git a/externals/sdl3 b/externals/sdl3 index 22422f774..a336b62d8 160000 --- a/externals/sdl3 +++ b/externals/sdl3 @@ -1 +1 @@ -Subproject commit 22422f7748d5128135995ed34c8f8012861c7332 +Subproject commit a336b62d8b0b97b09214e053203e442e2b6e2be5 From a8a779c79b48f020a1432274114f1ddaff0b1dec Mon Sep 17 00:00:00 2001 From: DanielSvoboda Date: Fri, 24 Jan 2025 05:11:48 -0300 Subject: [PATCH 52/99] Fix AutoUpdate Changelog (#2224) --- src/qt_gui/check_update.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/qt_gui/check_update.cpp b/src/qt_gui/check_update.cpp index e3e019144..0c1cce5da 100644 --- a/src/qt_gui/check_update.cpp +++ b/src/qt_gui/check_update.cpp @@ -146,14 +146,14 @@ void CheckUpdate::CheckForUpdates(const bool showMessage) { } QString currentRev = (updateChannel == "Nightly") - ? QString::fromStdString(Common::g_scm_rev).left(7) + ? QString::fromStdString(Common::g_scm_rev) : "v." + QString::fromStdString(Common::VERSION); QString currentDate = Common::g_scm_date; QDateTime dateTime = QDateTime::fromString(latestDate, Qt::ISODate); latestDate = dateTime.isValid() ? dateTime.toString("yyyy-MM-dd HH:mm:ss") : "Unknown date"; - if (latestRev == currentRev) { + if (latestRev == currentRev.left(7)) { if (showMessage) { QMessageBox::information(this, tr("Auto Updater"), tr("Your version is already up to date!")); @@ -190,7 +190,7 @@ void CheckUpdate::setupUI(const QString& downloadUrl, const QString& latestDate, QString("


" + tr("Update Channel") + ":
" + updateChannel + "
" + tr("Current Version") + ": %1 (%2)
" + tr("Latest Version") + ": %3 (%4)

" + tr("Do you want to update?") + "

") - .arg(currentRev, currentDate, latestRev, latestDate); + .arg(currentRev.left(7), currentDate, latestRev, latestDate); QLabel* updateLabel = new QLabel(updateText, this); layout->addWidget(updateLabel); From 91444a05453ba1468b29c575d844ae173cc7e738 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Fri, 24 Jan 2025 00:21:32 -0800 Subject: [PATCH 53/99] liverpool: Fix tiled check for color buffer. (#2227) --- src/video_core/amdgpu/liverpool.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/video_core/amdgpu/liverpool.h b/src/video_core/amdgpu/liverpool.h index a29bde4ce..ec9c92ef1 100644 --- a/src/video_core/amdgpu/liverpool.h +++ b/src/video_core/amdgpu/liverpool.h @@ -904,7 +904,7 @@ struct Liverpool { } bool IsTiled() const { - return !info.linear_general; + return GetTilingMode() != TilingMode::Display_Linear; } [[nodiscard]] DataFormat GetDataFmt() const { From 74710116f6bdd805c39ffe7fff4be017df3ac910 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Fri, 24 Jan 2025 00:21:56 -0800 Subject: [PATCH 54/99] renderer_vulkan: Remove dead code. (#2228) --- CMakeLists.txt | 2 - .../vk_descriptor_update_queue.cpp | 108 ------------------ .../vk_descriptor_update_queue.h | 51 --------- 3 files changed, 161 deletions(-) delete mode 100644 src/video_core/renderer_vulkan/vk_descriptor_update_queue.cpp delete mode 100644 src/video_core/renderer_vulkan/vk_descriptor_update_queue.h diff --git a/CMakeLists.txt b/CMakeLists.txt index 131809c8e..3db142be7 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -751,8 +751,6 @@ set(VIDEO_CORE src/video_core/amdgpu/liverpool.cpp src/video_core/renderer_vulkan/vk_common.h src/video_core/renderer_vulkan/vk_compute_pipeline.cpp src/video_core/renderer_vulkan/vk_compute_pipeline.h - src/video_core/renderer_vulkan/vk_descriptor_update_queue.cpp - src/video_core/renderer_vulkan/vk_descriptor_update_queue.h src/video_core/renderer_vulkan/vk_graphics_pipeline.cpp src/video_core/renderer_vulkan/vk_graphics_pipeline.h src/video_core/renderer_vulkan/vk_instance.cpp diff --git a/src/video_core/renderer_vulkan/vk_descriptor_update_queue.cpp b/src/video_core/renderer_vulkan/vk_descriptor_update_queue.cpp deleted file mode 100644 index 7699bea9d..000000000 --- a/src/video_core/renderer_vulkan/vk_descriptor_update_queue.cpp +++ /dev/null @@ -1,108 +0,0 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later - -#include "video_core/renderer_vulkan/vk_descriptor_update_queue.h" -#include "video_core/renderer_vulkan/vk_instance.h" - -namespace Vulkan { - -DescriptorUpdateQueue::DescriptorUpdateQueue(const Instance& instance, u32 descriptor_write_max_) - : device{instance.GetDevice()}, descriptor_write_max{descriptor_write_max_} { - descriptor_infos = std::make_unique(descriptor_write_max); - descriptor_writes = std::make_unique(descriptor_write_max); -} - -void DescriptorUpdateQueue::Flush() { - if (descriptor_write_end == 0) { - return; - } - device.updateDescriptorSets({std::span(descriptor_writes.get(), descriptor_write_end)}, {}); - descriptor_write_end = 0; -} - -void DescriptorUpdateQueue::AddStorageImage(vk::DescriptorSet target, u8 binding, - vk::ImageView image_view, - vk::ImageLayout image_layout) { - if (descriptor_write_end >= descriptor_write_max) [[unlikely]] { - Flush(); - } - - auto& image_info = descriptor_infos[descriptor_write_end].image_info; - image_info.sampler = VK_NULL_HANDLE; - image_info.imageView = image_view; - image_info.imageLayout = image_layout; - - descriptor_writes[descriptor_write_end++] = vk::WriteDescriptorSet{ - .dstSet = target, - .dstBinding = binding, - .dstArrayElement = 0, - .descriptorCount = 1, - .descriptorType = vk::DescriptorType::eStorageImage, - .pImageInfo = &image_info, - }; -} - -void DescriptorUpdateQueue::AddImageSampler(vk::DescriptorSet target, u8 binding, u8 array_index, - vk::ImageView image_view, vk::Sampler sampler, - vk::ImageLayout image_layout) { - if (descriptor_write_end >= descriptor_write_max) [[unlikely]] { - Flush(); - } - - auto& image_info = descriptor_infos[descriptor_write_end].image_info; - image_info.sampler = sampler; - image_info.imageView = image_view; - image_info.imageLayout = image_layout; - - descriptor_writes[descriptor_write_end++] = vk::WriteDescriptorSet{ - .dstSet = target, - .dstBinding = binding, - .dstArrayElement = array_index, - .descriptorCount = 1, - .descriptorType = - sampler ? vk::DescriptorType::eCombinedImageSampler : vk::DescriptorType::eSampledImage, - .pImageInfo = &image_info, - }; -} - -void DescriptorUpdateQueue::AddBuffer(vk::DescriptorSet target, u8 binding, vk::Buffer buffer, - vk::DeviceSize offset, vk::DeviceSize size, - vk::DescriptorType type) { - if (descriptor_write_end >= descriptor_write_max) [[unlikely]] { - Flush(); - } - - auto& buffer_info = descriptor_infos[descriptor_write_end].buffer_info; - buffer_info.buffer = buffer; - buffer_info.offset = offset; - buffer_info.range = size; - - descriptor_writes[descriptor_write_end++] = vk::WriteDescriptorSet{ - .dstSet = target, - .dstBinding = binding, - .dstArrayElement = 0, - .descriptorCount = 1, - .descriptorType = type, - .pBufferInfo = &buffer_info, - }; -} - -void DescriptorUpdateQueue::AddTexelBuffer(vk::DescriptorSet target, u8 binding, - vk::BufferView buffer_view) { - if (descriptor_write_end >= descriptor_write_max) [[unlikely]] { - Flush(); - } - - auto& buffer_info = descriptor_infos[descriptor_write_end].buffer_view; - buffer_info = buffer_view; - descriptor_writes[descriptor_write_end++] = vk::WriteDescriptorSet{ - .dstSet = target, - .dstBinding = binding, - .dstArrayElement = 0, - .descriptorCount = 1, - .descriptorType = vk::DescriptorType::eUniformTexelBuffer, - .pTexelBufferView = &buffer_info, - }; -} - -} // namespace Vulkan diff --git a/src/video_core/renderer_vulkan/vk_descriptor_update_queue.h b/src/video_core/renderer_vulkan/vk_descriptor_update_queue.h deleted file mode 100644 index 9e864db6e..000000000 --- a/src/video_core/renderer_vulkan/vk_descriptor_update_queue.h +++ /dev/null @@ -1,51 +0,0 @@ -// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later - -#include - -#include "common/types.h" -#include "video_core/renderer_vulkan/vk_common.h" - -namespace Vulkan { - -class Instance; - -struct DescriptorInfoUnion { - DescriptorInfoUnion() {} - - union { - vk::DescriptorImageInfo image_info; - vk::DescriptorBufferInfo buffer_info; - vk::BufferView buffer_view; - }; -}; - -class DescriptorUpdateQueue { -public: - explicit DescriptorUpdateQueue(const Instance& instance, u32 descriptor_write_max = 2048); - ~DescriptorUpdateQueue() = default; - - void Flush(); - - void AddStorageImage(vk::DescriptorSet target, u8 binding, vk::ImageView image_view, - vk::ImageLayout image_layout = vk::ImageLayout::eGeneral); - - void AddImageSampler(vk::DescriptorSet target, u8 binding, u8 array_index, - vk::ImageView image_view, vk::Sampler sampler, - vk::ImageLayout imageLayout = vk::ImageLayout::eGeneral); - - void AddBuffer(vk::DescriptorSet target, u8 binding, vk::Buffer buffer, vk::DeviceSize offset, - vk::DeviceSize size = VK_WHOLE_SIZE, - vk::DescriptorType type = vk::DescriptorType::eUniformBufferDynamic); - - void AddTexelBuffer(vk::DescriptorSet target, u8 binding, vk::BufferView buffer_view); - -private: - const vk::Device device; - const u32 descriptor_write_max; - std::unique_ptr descriptor_infos; - std::unique_ptr descriptor_writes; - u32 descriptor_write_end = 0; -}; - -} // namespace Vulkan From d1b9a5adcceb0c61e03293db9840ca6844442398 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Fri, 24 Jan 2025 00:23:18 -0800 Subject: [PATCH 55/99] texture_cache: Do not overwrite overlap hit with a miss. (#2217) --- src/video_core/texture_cache/texture_cache.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/video_core/texture_cache/texture_cache.cpp b/src/video_core/texture_cache/texture_cache.cpp index 04711539c..e995b10b2 100644 --- a/src/video_core/texture_cache/texture_cache.cpp +++ b/src/video_core/texture_cache/texture_cache.cpp @@ -345,8 +345,13 @@ ImageId TextureCache::FindImage(BaseDesc& desc, FindFlags flags) { view_slice = -1; const auto& merged_info = image_id ? slot_images[image_id].info : info; - std::tie(image_id, view_mip, view_slice) = + auto [overlap_image_id, overlap_view_mip, overlap_view_slice] = ResolveOverlap(merged_info, desc.type, cache_id, image_id); + if (overlap_image_id) { + image_id = overlap_image_id; + view_mip = overlap_view_mip; + view_slice = overlap_view_slice; + } } } From 481f420a892e02ac30bfe3e4966368900c69ead2 Mon Sep 17 00:00:00 2001 From: georgemoralis Date: Fri, 24 Jan 2025 10:28:14 +0200 Subject: [PATCH 56/99] Update building-linux.md --- documents/building-linux.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/documents/building-linux.md b/documents/building-linux.md index 2342e9afc..4aa66aac6 100644 --- a/documents/building-linux.md +++ b/documents/building-linux.md @@ -29,7 +29,9 @@ sudo dnf install clang git cmake libatomic alsa-lib-devel pipewire-jack-audio-co sudo pacman -S base-devel clang git cmake sndio jack2 openal qt6-base qt6-declarative qt6-multimedia sdl2 vulkan-validation-layers ``` -**Note** : The `shadps4-git` AUR package is not maintained by any of the developers, and it uses the default compiler, which is often set to GCC. Use at your own discretion.#### OpenSUSE +**Note** : The `shadps4-git` AUR package is not maintained by any of the developers, and it uses the default compiler, which is often set to GCC. Use at your own discretion. + +#### OpenSUSE ``` sudo zypper install clang git cmake libasound2 libpulse-devel libsndio7 libjack-devel openal-soft-devel libopenssl-devel zlib-devel libedit-devel systemd-devel libevdev-devel qt6-base-devel qt6-multimedia-devel qt6-svg-devel qt6-linguist-devel qt6-gui-private-devel vulkan-devel vulkan-validationlayers @@ -48,6 +50,7 @@ distrobox create --name archlinux --init --image archlinux:latest and install the dependencies on that container as cited above. This option is **highly recommended** for NixOS and distributions with immutable/atomic filesystems (example: Fedora Kinoite, SteamOS). + ### Cloning ``` From 0f69697acb7504e57abe2b15238b2c92414a0d8f Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Fri, 24 Jan 2025 00:48:39 -0800 Subject: [PATCH 57/99] documents: Update CPU requirements. (#2229) --- documents/Quickstart/Quickstart.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/documents/Quickstart/Quickstart.md b/documents/Quickstart/Quickstart.md index b2931e51e..2f2751887 100644 --- a/documents/Quickstart/Quickstart.md +++ b/documents/Quickstart/Quickstart.md @@ -22,7 +22,10 @@ SPDX-License-Identifier: GPL-2.0-or-later - A processor with at least 4 cores and 6 threads - Above 2.5 GHz frequency -- required support AVX2 extension or Rosetta 2 on ARM +- A CPU supporting the following instruction sets: MMX, SSE, SSE2, SSE3, SSSE3, SSE4.1, SSE4.2, AVX, F16C, CLMUL, AES, BMI1, MOVBE, XSAVE, ABM + - **Intel**: Haswell generation or newer + - **AMD**: Jaguar generation or newer + - **Apple**: Rosetta 2 on macOS 15 or newer ### GPU From 9dcf40e261c6775a997b92d26a4bd8113821c6ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcin=20Miko=C5=82ajczyk?= Date: Fri, 24 Jan 2025 11:07:36 +0000 Subject: [PATCH 58/99] Handle more 64bit shifts in Translator (#1825) --- .../frontend/translate/scalar_alu.cpp | 22 ++++++++++++++++++- .../frontend/translate/translate.h | 2 ++ .../frontend/translate/vector_alu.cpp | 4 ++++ 3 files changed, 27 insertions(+), 1 deletion(-) diff --git a/src/shader_recompiler/frontend/translate/scalar_alu.cpp b/src/shader_recompiler/frontend/translate/scalar_alu.cpp index 7f34126f5..b1b260fde 100644 --- a/src/shader_recompiler/frontend/translate/scalar_alu.cpp +++ b/src/shader_recompiler/frontend/translate/scalar_alu.cpp @@ -72,10 +72,14 @@ void Translator::EmitScalarAlu(const GcnInst& inst) { return S_OR_B64(NegateMode::Result, true, inst); case Opcode::S_LSHL_B32: return S_LSHL_B32(inst); + case Opcode::S_LSHL_B64: + return S_LSHL_B64(inst); case Opcode::S_LSHR_B32: return S_LSHR_B32(inst); case Opcode::S_ASHR_I32: return S_ASHR_I32(inst); + case Opcode::S_ASHR_I64: + return S_ASHR_I64(inst); case Opcode::S_BFM_B32: return S_BFM_B32(inst); case Opcode::S_MUL_I32: @@ -420,6 +424,14 @@ void Translator::S_LSHL_B32(const GcnInst& inst) { ir.SetScc(ir.INotEqual(result, ir.Imm32(0))); } +void Translator::S_LSHL_B64(const GcnInst& inst) { + const IR::U64 src0{GetSrc64(inst.src[0])}; + const IR::U64 src1{GetSrc64(inst.src[1])}; + const IR::U64 result = ir.ShiftLeftLogical(src0, ir.BitwiseAnd(src1, ir.Imm64(u64(0x3F)))); + SetDst64(inst.dst[0], result); + ir.SetScc(ir.INotEqual(result, ir.Imm64(u64(0)))); +} + void Translator::S_LSHR_B32(const GcnInst& inst) { const IR::U32 src0{GetSrc(inst.src[0])}; const IR::U32 src1{GetSrc(inst.src[1])}; @@ -431,11 +443,19 @@ void Translator::S_LSHR_B32(const GcnInst& inst) { void Translator::S_ASHR_I32(const GcnInst& inst) { const IR::U32 src0{GetSrc(inst.src[0])}; const IR::U32 src1{GetSrc(inst.src[1])}; - const IR::U32 result{ir.ShiftRightArithmetic(src0, src1)}; + const IR::U32 result{ir.ShiftRightArithmetic(src0, ir.BitwiseAnd(src1, ir.Imm32(0x1F)))}; SetDst(inst.dst[0], result); ir.SetScc(ir.INotEqual(result, ir.Imm32(0))); } +void Translator::S_ASHR_I64(const GcnInst& inst) { + const IR::U64 src0{GetSrc64(inst.src[0])}; + const IR::U64 src1{GetSrc64(inst.src[1])}; + const IR::U64 result{ir.ShiftRightArithmetic(src0, ir.BitwiseAnd(src1, ir.Imm64(u64(0x3F))))}; + SetDst64(inst.dst[0], result); + ir.SetScc(ir.INotEqual(result, ir.Imm64(u64(0)))); +} + void Translator::S_BFM_B32(const GcnInst& inst) { const IR::U32 src0{ir.BitwiseAnd(GetSrc(inst.src[0]), ir.Imm32(0x1F))}; const IR::U32 src1{ir.BitwiseAnd(GetSrc(inst.src[1]), ir.Imm32(0x1F))}; diff --git a/src/shader_recompiler/frontend/translate/translate.h b/src/shader_recompiler/frontend/translate/translate.h index bef61f997..496455b50 100644 --- a/src/shader_recompiler/frontend/translate/translate.h +++ b/src/shader_recompiler/frontend/translate/translate.h @@ -90,8 +90,10 @@ public: void S_OR_B64(NegateMode negate, bool is_xor, const GcnInst& inst); void S_XOR_B32(const GcnInst& inst); void S_LSHL_B32(const GcnInst& inst); + void S_LSHL_B64(const GcnInst& inst); void S_LSHR_B32(const GcnInst& inst); void S_ASHR_I32(const GcnInst& inst); + void S_ASHR_I64(const GcnInst& inst); void S_BFM_B32(const GcnInst& inst); void S_MUL_I32(const GcnInst& inst); void S_BFE(const GcnInst& inst, bool is_signed); diff --git a/src/shader_recompiler/frontend/translate/vector_alu.cpp b/src/shader_recompiler/frontend/translate/vector_alu.cpp index b2863f6a8..ac72293e4 100644 --- a/src/shader_recompiler/frontend/translate/vector_alu.cpp +++ b/src/shader_recompiler/frontend/translate/vector_alu.cpp @@ -1273,6 +1273,10 @@ void Translator::V_LSHL_B64(const GcnInst& inst) { ir.SetVectorReg(dst_reg + 1, ir.Imm32(static_cast(result >> 32))); return; } + + const IR::U64 result = ir.ShiftLeftLogical(src0, ir.BitwiseAnd(src1, ir.Imm64(u64(0x3F)))); + SetDst64(inst.dst[0], result); + return; } UNREACHABLE_MSG("Unimplemented V_LSHL_B64 arguments"); } From 4d12de8149cce521916f7752a0830430170144db Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Fri, 24 Jan 2025 03:11:13 -0800 Subject: [PATCH 59/99] hotfix: 64-bit shift fixups --- .../backend/spirv/emit_spirv_instructions.h | 3 ++- .../backend/spirv/emit_spirv_integer.cpp | 6 ++++- .../frontend/translate/vector_alu.cpp | 23 +------------------ src/shader_recompiler/ir/ir_emitter.cpp | 14 +++++++++-- src/shader_recompiler/ir/ir_emitter.h | 2 +- src/shader_recompiler/ir/opcodes.inc | 3 ++- .../ir/passes/constant_propagation_pass.cpp | 5 +++- 7 files changed, 27 insertions(+), 29 deletions(-) diff --git a/src/shader_recompiler/backend/spirv/emit_spirv_instructions.h b/src/shader_recompiler/backend/spirv/emit_spirv_instructions.h index f0bb9fd7e..4833dc9d0 100644 --- a/src/shader_recompiler/backend/spirv/emit_spirv_instructions.h +++ b/src/shader_recompiler/backend/spirv/emit_spirv_instructions.h @@ -348,7 +348,8 @@ Id EmitSLessThanEqual(EmitContext& ctx, Id lhs, Id rhs); Id EmitULessThanEqual(EmitContext& ctx, Id lhs, Id rhs); Id EmitSGreaterThan(EmitContext& ctx, Id lhs, Id rhs); Id EmitUGreaterThan(EmitContext& ctx, Id lhs, Id rhs); -Id EmitINotEqual(EmitContext& ctx, Id lhs, Id rhs); +Id EmitINotEqual32(EmitContext& ctx, Id lhs, Id rhs); +Id EmitINotEqual64(EmitContext& ctx, Id lhs, Id rhs); Id EmitSGreaterThanEqual(EmitContext& ctx, Id lhs, Id rhs); Id EmitUGreaterThanEqual(EmitContext& ctx, Id lhs, Id rhs); Id EmitLogicalOr(EmitContext& ctx, Id a, Id b); diff --git a/src/shader_recompiler/backend/spirv/emit_spirv_integer.cpp b/src/shader_recompiler/backend/spirv/emit_spirv_integer.cpp index 70411ecec..e2d702389 100644 --- a/src/shader_recompiler/backend/spirv/emit_spirv_integer.cpp +++ b/src/shader_recompiler/backend/spirv/emit_spirv_integer.cpp @@ -324,7 +324,11 @@ Id EmitUGreaterThan(EmitContext& ctx, Id lhs, Id rhs) { return ctx.OpUGreaterThan(ctx.U1[1], lhs, rhs); } -Id EmitINotEqual(EmitContext& ctx, Id lhs, Id rhs) { +Id EmitINotEqual32(EmitContext& ctx, Id lhs, Id rhs) { + return ctx.OpINotEqual(ctx.U1[1], lhs, rhs); +} + +Id EmitINotEqual64(EmitContext& ctx, Id lhs, Id rhs) { return ctx.OpINotEqual(ctx.U1[1], lhs, rhs); } diff --git a/src/shader_recompiler/frontend/translate/vector_alu.cpp b/src/shader_recompiler/frontend/translate/vector_alu.cpp index ac72293e4..42dbcc513 100644 --- a/src/shader_recompiler/frontend/translate/vector_alu.cpp +++ b/src/shader_recompiler/frontend/translate/vector_alu.cpp @@ -1257,28 +1257,7 @@ void Translator::V_CVT_PK_U8_F32(const GcnInst& inst) { void Translator::V_LSHL_B64(const GcnInst& inst) { const IR::U64 src0{GetSrc64(inst.src[0])}; const IR::U64 src1{GetSrc64(inst.src[1])}; - const IR::VectorReg dst_reg{inst.dst[0].code}; - if (src0.IsImmediate()) { - if (src0.U64() == -1) { - // If src0 is a fixed -1, the result will always be -1. - ir.SetVectorReg(dst_reg, ir.Imm32(0xFFFFFFFF)); - ir.SetVectorReg(dst_reg + 1, ir.Imm32(0xFFFFFFFF)); - return; - } - if (src1.IsImmediate()) { - // If both src0 and src1 are immediates, we can calculate the result now. - // Note that according to the manual, only bits 4:0 are used from src1. - const u64 result = src0.U64() << (src1.U64() & 0x1F); - ir.SetVectorReg(dst_reg, ir.Imm32(static_cast(result))); - ir.SetVectorReg(dst_reg + 1, ir.Imm32(static_cast(result >> 32))); - return; - } - - const IR::U64 result = ir.ShiftLeftLogical(src0, ir.BitwiseAnd(src1, ir.Imm64(u64(0x3F)))); - SetDst64(inst.dst[0], result); - return; - } - UNREACHABLE_MSG("Unimplemented V_LSHL_B64 arguments"); + SetDst64(inst.dst[0], ir.ShiftLeftLogical(src0, ir.BitwiseAnd(src1, ir.Imm64(u64(0x3F))))); } void Translator::V_MUL_F64(const GcnInst& inst) { diff --git a/src/shader_recompiler/ir/ir_emitter.cpp b/src/shader_recompiler/ir/ir_emitter.cpp index 5ac08e7dc..f0558665b 100644 --- a/src/shader_recompiler/ir/ir_emitter.cpp +++ b/src/shader_recompiler/ir/ir_emitter.cpp @@ -1461,8 +1461,18 @@ U1 IREmitter::IGreaterThan(const U32& lhs, const U32& rhs, bool is_signed) { return Inst(is_signed ? Opcode::SGreaterThan : Opcode::UGreaterThan, lhs, rhs); } -U1 IREmitter::INotEqual(const U32& lhs, const U32& rhs) { - return Inst(Opcode::INotEqual, lhs, rhs); +U1 IREmitter::INotEqual(const U32U64& lhs, const U32U64& rhs) { + if (lhs.Type() != rhs.Type()) { + UNREACHABLE_MSG("Mismatching types {} and {}", lhs.Type(), rhs.Type()); + } + switch (lhs.Type()) { + case Type::U32: + return Inst(Opcode::INotEqual32, lhs, rhs); + case Type::U64: + return Inst(Opcode::INotEqual64, lhs, rhs); + default: + ThrowInvalidType(lhs.Type()); + } } U1 IREmitter::IGreaterThanEqual(const U32& lhs, const U32& rhs, bool is_signed) { diff --git a/src/shader_recompiler/ir/ir_emitter.h b/src/shader_recompiler/ir/ir_emitter.h index d1dc44d74..5dd49ce7a 100644 --- a/src/shader_recompiler/ir/ir_emitter.h +++ b/src/shader_recompiler/ir/ir_emitter.h @@ -258,7 +258,7 @@ public: [[nodiscard]] U1 IEqual(const U32U64& lhs, const U32U64& rhs); [[nodiscard]] U1 ILessThanEqual(const U32& lhs, const U32& rhs, bool is_signed); [[nodiscard]] U1 IGreaterThan(const U32& lhs, const U32& rhs, bool is_signed); - [[nodiscard]] U1 INotEqual(const U32& lhs, const U32& rhs); + [[nodiscard]] U1 INotEqual(const U32U64& lhs, const U32U64& rhs); [[nodiscard]] U1 IGreaterThanEqual(const U32& lhs, const U32& rhs, bool is_signed); [[nodiscard]] U1 LogicalOr(const U1& a, const U1& b); diff --git a/src/shader_recompiler/ir/opcodes.inc b/src/shader_recompiler/ir/opcodes.inc index b45151dba..63a4e1e62 100644 --- a/src/shader_recompiler/ir/opcodes.inc +++ b/src/shader_recompiler/ir/opcodes.inc @@ -321,7 +321,8 @@ OPCODE(SLessThanEqual, U1, U32, OPCODE(ULessThanEqual, U1, U32, U32, ) OPCODE(SGreaterThan, U1, U32, U32, ) OPCODE(UGreaterThan, U1, U32, U32, ) -OPCODE(INotEqual, U1, U32, U32, ) +OPCODE(INotEqual32, U1, U32, U32, ) +OPCODE(INotEqual64, U1, U64, U64, ) OPCODE(SGreaterThanEqual, U1, U32, U32, ) OPCODE(UGreaterThanEqual, U1, U32, U32, ) diff --git a/src/shader_recompiler/ir/passes/constant_propagation_pass.cpp b/src/shader_recompiler/ir/passes/constant_propagation_pass.cpp index 26d819d8e..12a1b56e9 100644 --- a/src/shader_recompiler/ir/passes/constant_propagation_pass.cpp +++ b/src/shader_recompiler/ir/passes/constant_propagation_pass.cpp @@ -403,9 +403,12 @@ void ConstantPropagation(IR::Block& block, IR::Inst& inst) { case IR::Opcode::IEqual64: FoldWhenAllImmediates(inst, [](u64 a, u64 b) { return a == b; }); return; - case IR::Opcode::INotEqual: + case IR::Opcode::INotEqual32: FoldWhenAllImmediates(inst, [](u32 a, u32 b) { return a != b; }); return; + case IR::Opcode::INotEqual64: + FoldWhenAllImmediates(inst, [](u64 a, u64 b) { return a != b; }); + return; case IR::Opcode::BitwiseAnd32: FoldWhenAllImmediates(inst, [](u32 a, u32 b) { return a & b; }); return; From 4f426b723f2f015af022e2f9c48813448c264d7b Mon Sep 17 00:00:00 2001 From: kalaposfos13 <153381648+kalaposfos13@users.noreply.github.com> Date: Fri, 24 Jan 2025 14:30:55 +0100 Subject: [PATCH 60/99] Rebase of "Handle munmap over multiple VMAs" (#2233) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Unmap memory in chunks if spanning over multiple VMAs * clang * Merge fixups * Minor code style changes * Update function declarations --------- Co-authored-by: Marcin Mikołajczyk --- src/core/memory.cpp | 49 +++++++++++++++++++++++++++++---------------- src/core/memory.h | 4 +++- 2 files changed, 35 insertions(+), 18 deletions(-) diff --git a/src/core/memory.cpp b/src/core/memory.cpp index f90d4e6aa..a8dd72acc 100644 --- a/src/core/memory.cpp +++ b/src/core/memory.cpp @@ -389,32 +389,29 @@ s32 MemoryManager::UnmapMemory(VAddr virtual_addr, size_t size) { return UnmapMemoryImpl(virtual_addr, size); } -s32 MemoryManager::UnmapMemoryImpl(VAddr virtual_addr, size_t size) { - const auto it = FindVMA(virtual_addr); - const auto& vma_base = it->second; - ASSERT_MSG(vma_base.Contains(virtual_addr, size), - "Existing mapping does not contain requested unmap range"); - - const auto type = vma_base.type; - if (type == VMAType::Free) { - return ORBIS_OK; - } - +u64 MemoryManager::UnmapBytesFromEntry(VAddr virtual_addr, VirtualMemoryArea vma_base, u64 size) { const auto vma_base_addr = vma_base.base; const auto vma_base_size = vma_base.size; + const auto type = vma_base.type; const auto phys_base = vma_base.phys_base; const bool is_exec = vma_base.is_exec; const auto start_in_vma = virtual_addr - vma_base_addr; + const auto adjusted_size = + vma_base_size - start_in_vma < size ? vma_base_size - start_in_vma : size; const bool has_backing = type == VMAType::Direct || type == VMAType::File; + + if (type == VMAType::Free) { + return adjusted_size; + } if (type == VMAType::Direct || type == VMAType::Pooled) { - rasterizer->UnmapMemory(virtual_addr, size); + rasterizer->UnmapMemory(virtual_addr, adjusted_size); } if (type == VMAType::Flexible) { - flexible_usage -= size; + flexible_usage -= adjusted_size; } // Mark region as free and attempt to coalesce it with neighbours. - const auto new_it = CarveVMA(virtual_addr, size); + const auto new_it = CarveVMA(virtual_addr, adjusted_size); auto& vma = new_it->second; vma.type = VMAType::Free; vma.prot = MemoryProt::NoAccess; @@ -423,13 +420,25 @@ s32 MemoryManager::UnmapMemoryImpl(VAddr virtual_addr, size_t size) { vma.name = ""; MergeAdjacent(vma_map, new_it); bool readonly_file = vma.prot == MemoryProt::CpuRead && type == VMAType::File; - if (type != VMAType::Reserved && type != VMAType::PoolReserved) { // Unmap the memory region. - impl.Unmap(vma_base_addr, vma_base_size, start_in_vma, start_in_vma + size, phys_base, - is_exec, has_backing, readonly_file); + impl.Unmap(vma_base_addr, vma_base_size, start_in_vma, start_in_vma + adjusted_size, + phys_base, is_exec, has_backing, readonly_file); TRACK_FREE(virtual_addr, "VMEM"); } + return adjusted_size; +} + +s32 MemoryManager::UnmapMemoryImpl(VAddr virtual_addr, u64 size) { + u64 unmapped_bytes = 0; + do { + auto it = FindVMA(virtual_addr + unmapped_bytes); + auto& vma_base = it->second; + auto unmapped = + UnmapBytesFromEntry(virtual_addr + unmapped_bytes, vma_base, size - unmapped_bytes); + ASSERT_MSG(unmapped > 0, "Failed to unmap memory, progress is impossible"); + unmapped_bytes += unmapped; + } while (unmapped_bytes < size); return ORBIS_OK; } @@ -651,6 +660,12 @@ MemoryManager::VMAHandle MemoryManager::CarveVMA(VAddr virtual_addr, size_t size const VAddr start_in_vma = virtual_addr - vma.base; const VAddr end_in_vma = start_in_vma + size; + + if (start_in_vma == 0 && size == vma.size) { + // if requsting the whole VMA, return it + return vma_handle; + } + ASSERT_MSG(end_in_vma <= vma.size, "Mapping cannot fit inside free region"); if (end_in_vma != vma.size) { diff --git a/src/core/memory.h b/src/core/memory.h index 615ecc3eb..59e48b248 100644 --- a/src/core/memory.h +++ b/src/core/memory.h @@ -252,7 +252,9 @@ private: DMemHandle Split(DMemHandle dmem_handle, size_t offset_in_area); - s32 UnmapMemoryImpl(VAddr virtual_addr, size_t size); + u64 UnmapBytesFromEntry(VAddr virtual_addr, VirtualMemoryArea vma_base, u64 size); + + s32 UnmapMemoryImpl(VAddr virtual_addr, u64 size); private: AddressSpace impl; From a4eba8e827c062b5e6874255ff810346943d0ea2 Mon Sep 17 00:00:00 2001 From: georgemoralis Date: Fri, 24 Jan 2025 19:22:06 +0200 Subject: [PATCH 61/99] stubbed webbrowserdialog,npparty (#2234) * stubbed webbrowserdialog,npparty * added poly's suggestions --- CMakeLists.txt | 4 + src/common/logging/filter.cpp | 2 + src/common/logging/types.h | 2 + src/core/libraries/libs.cpp | 4 + src/core/libraries/np_party/np_party.cpp | 195 ++++++++++++++++++ src/core/libraries/np_party/np_party.h | 44 ++++ .../web_browser_dialog/webbrowserdialog.cpp | 112 ++++++++++ .../web_browser_dialog/webbrowserdialog.h | 30 +++ 8 files changed, 393 insertions(+) create mode 100644 src/core/libraries/np_party/np_party.cpp create mode 100644 src/core/libraries/np_party/np_party.h create mode 100644 src/core/libraries/web_browser_dialog/webbrowserdialog.cpp create mode 100644 src/core/libraries/web_browser_dialog/webbrowserdialog.h diff --git a/CMakeLists.txt b/CMakeLists.txt index 3db142be7..4c9dad307 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -344,6 +344,8 @@ set(SYSTEM_LIBS src/core/libraries/system/commondialog.cpp src/core/libraries/razor_cpu/razor_cpu.h src/core/libraries/mouse/mouse.cpp src/core/libraries/mouse/mouse.h + src/core/libraries/web_browser_dialog/webbrowserdialog.cpp + src/core/libraries/web_browser_dialog/webbrowserdialog.h ) set(VIDEOOUT_LIB src/core/libraries/videoout/buffer.h @@ -434,6 +436,8 @@ set(NP_LIBS src/core/libraries/np_common/np_common.cpp src/core/libraries/np_trophy/np_trophy_error.h src/core/libraries/np_web_api/np_web_api.cpp src/core/libraries/np_web_api/np_web_api.h + src/core/libraries/np_party/np_party.cpp + src/core/libraries/np_party/np_party.h ) set(MISC_LIBS src/core/libraries/screenshot/screenshot.cpp diff --git a/src/common/logging/filter.cpp b/src/common/logging/filter.cpp index 168d03948..f1d3a9499 100644 --- a/src/common/logging/filter.cpp +++ b/src/common/logging/filter.cpp @@ -131,6 +131,8 @@ bool ParseFilterRule(Filter& instance, Iterator begin, Iterator end) { SUB(Lib, Videodec) \ SUB(Lib, RazorCpu) \ SUB(Lib, Mouse) \ + SUB(Lib, WebBrowserDialog) \ + SUB(Lib, NpParty) \ CLS(Frontend) \ CLS(Render) \ SUB(Render, Vulkan) \ diff --git a/src/common/logging/types.h b/src/common/logging/types.h index 4ca88e1be..d5530312c 100644 --- a/src/common/logging/types.h +++ b/src/common/logging/types.h @@ -98,6 +98,8 @@ enum class Class : u8 { Lib_Videodec, ///< The LibSceVideodec implementation. Lib_RazorCpu, ///< The LibRazorCpu implementation. Lib_Mouse, ///< The LibSceMouse implementation + Lib_WebBrowserDialog, ///< The LibSceWebBrowserDialog implementation + Lib_NpParty, ///< The LibSceNpParty implementation Frontend, ///< Emulator UI Render, ///< Video Core Render_Vulkan, ///< Vulkan backend diff --git a/src/core/libraries/libs.cpp b/src/core/libraries/libs.cpp index 6dc455028..e09de1cee 100644 --- a/src/core/libraries/libs.cpp +++ b/src/core/libraries/libs.cpp @@ -28,6 +28,7 @@ #include "core/libraries/network/ssl2.h" #include "core/libraries/np_common/np_common.h" #include "core/libraries/np_manager/np_manager.h" +#include "core/libraries/np_party/np_party.h" #include "core/libraries/np_score/np_score.h" #include "core/libraries/np_trophy/np_trophy.h" #include "core/libraries/np_web_api/np_web_api.h" @@ -52,6 +53,7 @@ #include "core/libraries/videodec/videodec.h" #include "core/libraries/videodec/videodec2.h" #include "core/libraries/videoout/video_out.h" +#include "core/libraries/web_browser_dialog/webbrowserdialog.h" #include "fiber/fiber.h" #include "jpeg/jpegenc.h" @@ -107,6 +109,8 @@ void InitHLELibs(Core::Loader::SymbolsResolver* sym) { Libraries::Fiber::RegisterlibSceFiber(sym); Libraries::JpegEnc::RegisterlibSceJpegEnc(sym); Libraries::Mouse::RegisterlibSceMouse(sym); + Libraries::WebBrowserDialog::RegisterlibSceWebBrowserDialog(sym); + Libraries::NpParty::RegisterlibSceNpParty(sym); } } // namespace Libraries diff --git a/src/core/libraries/np_party/np_party.cpp b/src/core/libraries/np_party/np_party.cpp new file mode 100644 index 000000000..8a66ccb22 --- /dev/null +++ b/src/core/libraries/np_party/np_party.cpp @@ -0,0 +1,195 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "common/logging/log.h" +#include "core/libraries/error_codes.h" +#include "core/libraries/libs.h" +#include "core/libraries/np_party/np_party.h" + +namespace Libraries::NpParty { + +s32 PS4_SYSV_ABI sceNpPartyCheckCallback() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyCreate() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyCreateA() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetId() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetMemberInfo() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetMemberInfoA() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetMembers() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetMembersA() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetMemberSessionInfo() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetMemberVoiceInfo() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetState() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetStateAsUser() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetStateAsUserA() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyGetVoiceChatPriority() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyInitialize() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyJoin() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyLeave() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyRegisterHandler() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyRegisterHandlerA() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyRegisterPrivateHandler() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartySendBinaryMessage() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartySetVoiceChatPriority() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyShowInvitationList() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyShowInvitationListA() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyTerminate() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceNpPartyUnregisterPrivateHandler() { + LOG_ERROR(Lib_NpParty, "(STUBBED) called"); + return ORBIS_OK; +} + +void RegisterlibSceNpParty(Core::Loader::SymbolsResolver* sym) { + LIB_FUNCTION("3e4k2mzLkmc", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyCheckCallback); + LIB_FUNCTION("nOZRy-slBoA", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyCreate); + LIB_FUNCTION("XQSUbbnpPBA", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyCreateA); + LIB_FUNCTION("DRA3ay-1DFQ", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyGetId); + LIB_FUNCTION("F1P+-wpxQow", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyGetMemberInfo); + LIB_FUNCTION("v2RYVGrJDkM", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyGetMemberInfoA); + LIB_FUNCTION("T2UOKf00ZN0", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyGetMembers); + LIB_FUNCTION("TaNw7W25QJw", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyGetMembersA); + LIB_FUNCTION("4gOMfNYzllw", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyGetMemberSessionInfo); + LIB_FUNCTION("EKi1jx59SP4", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyGetMemberVoiceInfo); + LIB_FUNCTION("aEzKdJzATZ0", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyGetState); + LIB_FUNCTION("o7grRhiGHYI", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyGetStateAsUser); + LIB_FUNCTION("EjyAI+QNgFw", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyGetStateAsUserA); + LIB_FUNCTION("-lc6XZnQXvM", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyGetVoiceChatPriority); + LIB_FUNCTION("lhYCTQmBkds", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyInitialize); + LIB_FUNCTION("RXNCDw2GDEg", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyJoin); + LIB_FUNCTION("J8jAi-tfJHc", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyLeave); + LIB_FUNCTION("kA88gbv71ao", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyRegisterHandler); + LIB_FUNCTION("+v4fVHMwFWc", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyRegisterHandlerA); + LIB_FUNCTION("zo4G5WWYpKg", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyRegisterPrivateHandler); + LIB_FUNCTION("U6VdUe-PNAY", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartySendBinaryMessage); + LIB_FUNCTION("nazKyHygHhY", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartySetVoiceChatPriority); + LIB_FUNCTION("-MFiL7hEnPE", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyShowInvitationList); + LIB_FUNCTION("yARHEYLajs0", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyShowInvitationListA); + LIB_FUNCTION("oLYkibiHqRA", "libSceNpParty", 1, "libSceNpParty", 1, 1, sceNpPartyTerminate); + LIB_FUNCTION("zQ7gIvt11Pc", "libSceNpParty", 1, "libSceNpParty", 1, 1, + sceNpPartyUnregisterPrivateHandler); + LIB_FUNCTION("nOZRy-slBoA", "libSceNpPartyCompat", 1, "libSceNpParty", 1, 1, sceNpPartyCreate); + LIB_FUNCTION("F1P+-wpxQow", "libSceNpPartyCompat", 1, "libSceNpParty", 1, 1, + sceNpPartyGetMemberInfo); + LIB_FUNCTION("T2UOKf00ZN0", "libSceNpPartyCompat", 1, "libSceNpParty", 1, 1, + sceNpPartyGetMembers); + LIB_FUNCTION("o7grRhiGHYI", "libSceNpPartyCompat", 1, "libSceNpParty", 1, 1, + sceNpPartyGetStateAsUser); + LIB_FUNCTION("kA88gbv71ao", "libSceNpPartyCompat", 1, "libSceNpParty", 1, 1, + sceNpPartyRegisterHandler); + LIB_FUNCTION("-MFiL7hEnPE", "libSceNpPartyCompat", 1, "libSceNpParty", 1, 1, + sceNpPartyShowInvitationList); +}; + +} // namespace Libraries::NpParty \ No newline at end of file diff --git a/src/core/libraries/np_party/np_party.h b/src/core/libraries/np_party/np_party.h new file mode 100644 index 000000000..d5f20e4f8 --- /dev/null +++ b/src/core/libraries/np_party/np_party.h @@ -0,0 +1,44 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#include "common/types.h" + +namespace Core::Loader { +class SymbolsResolver; +} + +namespace Libraries::NpParty { + +s32 PS4_SYSV_ABI sceNpPartyCheckCallback(); +s32 PS4_SYSV_ABI sceNpPartyCreate(); +s32 PS4_SYSV_ABI sceNpPartyCreateA(); +s32 PS4_SYSV_ABI sceNpPartyGetId(); +s32 PS4_SYSV_ABI sceNpPartyGetMemberInfo(); +s32 PS4_SYSV_ABI sceNpPartyGetMemberInfoA(); +s32 PS4_SYSV_ABI sceNpPartyGetMembers(); +s32 PS4_SYSV_ABI sceNpPartyGetMembersA(); +s32 PS4_SYSV_ABI sceNpPartyGetMemberSessionInfo(); +s32 PS4_SYSV_ABI sceNpPartyGetMemberVoiceInfo(); +s32 PS4_SYSV_ABI sceNpPartyGetState(); +s32 PS4_SYSV_ABI sceNpPartyGetStateAsUser(); +s32 PS4_SYSV_ABI sceNpPartyGetStateAsUserA(); +s32 PS4_SYSV_ABI sceNpPartyGetVoiceChatPriority(); +s32 PS4_SYSV_ABI sceNpPartyInitialize(); +s32 PS4_SYSV_ABI sceNpPartyJoin(); +s32 PS4_SYSV_ABI sceNpPartyLeave(); +s32 PS4_SYSV_ABI sceNpPartyRegisterHandler(); +s32 PS4_SYSV_ABI sceNpPartyRegisterHandlerA(); +s32 PS4_SYSV_ABI sceNpPartyRegisterPrivateHandler(); +s32 PS4_SYSV_ABI sceNpPartySendBinaryMessage(); +s32 PS4_SYSV_ABI sceNpPartySetVoiceChatPriority(); +s32 PS4_SYSV_ABI sceNpPartyShowInvitationList(); +s32 PS4_SYSV_ABI sceNpPartyShowInvitationListA(); +s32 PS4_SYSV_ABI sceNpPartyTerminate(); +s32 PS4_SYSV_ABI sceNpPartyUnregisterPrivateHandler(); +s32 PS4_SYSV_ABI module_start(); +s32 PS4_SYSV_ABI module_stop(); + +void RegisterlibSceNpParty(Core::Loader::SymbolsResolver* sym); +} // namespace Libraries::NpParty \ No newline at end of file diff --git a/src/core/libraries/web_browser_dialog/webbrowserdialog.cpp b/src/core/libraries/web_browser_dialog/webbrowserdialog.cpp new file mode 100644 index 000000000..ee434f96a --- /dev/null +++ b/src/core/libraries/web_browser_dialog/webbrowserdialog.cpp @@ -0,0 +1,112 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "common/logging/log.h" +#include "core/libraries/error_codes.h" +#include "core/libraries/libs.h" +#include "core/libraries/web_browser_dialog/webbrowserdialog.h" + +namespace Libraries::WebBrowserDialog { + +s32 PS4_SYSV_ABI sceWebBrowserDialogClose() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogGetEvent() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogGetResult() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogGetStatus() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogInitialize() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogNavigate() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogOpen() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogOpenForPredeterminedContent() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogResetCookie() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogSetCookie() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogSetZoom() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogTerminate() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceWebBrowserDialogUpdateStatus() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI Func_F2BE042771625F8C() { + LOG_ERROR(Lib_WebBrowserDialog, "(STUBBED) called"); + return ORBIS_OK; +} + +void RegisterlibSceWebBrowserDialog(Core::Loader::SymbolsResolver* sym) { + LIB_FUNCTION("PSK+Eik919Q", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogClose); + LIB_FUNCTION("Wit4LjeoeX4", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogGetEvent); + LIB_FUNCTION("vCaW0fgVQmc", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogGetResult); + LIB_FUNCTION("CFTG6a8TjOU", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogGetStatus); + LIB_FUNCTION("jqb7HntFQFc", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogInitialize); + LIB_FUNCTION("uYELOMVnmNQ", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogNavigate); + LIB_FUNCTION("FraP7debcdg", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogOpen); + LIB_FUNCTION("O7dIZQrwVFY", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogOpenForPredeterminedContent); + LIB_FUNCTION("Cya+jvTtPqg", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogResetCookie); + LIB_FUNCTION("TZnDVkP91Rg", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogSetCookie); + LIB_FUNCTION("RLhKBOoNyXY", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogSetZoom); + LIB_FUNCTION("ocHtyBwHfys", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogTerminate); + LIB_FUNCTION("h1dR-t5ISgg", "libSceWebBrowserDialog", 1, "libSceWebBrowserDialog", 1, 1, + sceWebBrowserDialogUpdateStatus); + LIB_FUNCTION("8r4EJ3FiX4w", "libSceWebBrowserDialogLimited", 1, "libSceWebBrowserDialog", 1, 1, + Func_F2BE042771625F8C); +}; + +} // namespace Libraries::WebBrowserDialog \ No newline at end of file diff --git a/src/core/libraries/web_browser_dialog/webbrowserdialog.h b/src/core/libraries/web_browser_dialog/webbrowserdialog.h new file mode 100644 index 000000000..aa118fe45 --- /dev/null +++ b/src/core/libraries/web_browser_dialog/webbrowserdialog.h @@ -0,0 +1,30 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#include "common/types.h" + +namespace Core::Loader { +class SymbolsResolver; +} + +namespace Libraries::WebBrowserDialog { + +s32 PS4_SYSV_ABI sceWebBrowserDialogClose(); +s32 PS4_SYSV_ABI sceWebBrowserDialogGetEvent(); +s32 PS4_SYSV_ABI sceWebBrowserDialogGetResult(); +s32 PS4_SYSV_ABI sceWebBrowserDialogGetStatus(); +s32 PS4_SYSV_ABI sceWebBrowserDialogInitialize(); +s32 PS4_SYSV_ABI sceWebBrowserDialogNavigate(); +s32 PS4_SYSV_ABI sceWebBrowserDialogOpen(); +s32 PS4_SYSV_ABI sceWebBrowserDialogOpenForPredeterminedContent(); +s32 PS4_SYSV_ABI sceWebBrowserDialogResetCookie(); +s32 PS4_SYSV_ABI sceWebBrowserDialogSetCookie(); +s32 PS4_SYSV_ABI sceWebBrowserDialogSetZoom(); +s32 PS4_SYSV_ABI sceWebBrowserDialogTerminate(); +s32 PS4_SYSV_ABI sceWebBrowserDialogUpdateStatus(); +s32 PS4_SYSV_ABI Func_F2BE042771625F8C(); + +void RegisterlibSceWebBrowserDialog(Core::Loader::SymbolsResolver* sym); +} // namespace Libraries::WebBrowserDialog \ No newline at end of file From b3c573f7989ffe3cc0fe15ce69f620bcaab9c61b Mon Sep 17 00:00:00 2001 From: poly <47796739+polybiusproxy@users.noreply.github.com> Date: Fri, 24 Jan 2025 19:37:34 +0100 Subject: [PATCH 62/99] libraries/fiber: print fiber ctx size on stack overflow --- src/core/libraries/fiber/fiber.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/libraries/fiber/fiber.cpp b/src/core/libraries/fiber/fiber.cpp index b77b5b5b6..345f0834d 100644 --- a/src/core/libraries/fiber/fiber.cpp +++ b/src/core/libraries/fiber/fiber.cpp @@ -37,8 +37,9 @@ extern "C" void PS4_SYSV_ABI _sceFiberForceQuit(u64 ret) { void PS4_SYSV_ABI _sceFiberCheckStackOverflow(OrbisFiberContext* ctx) { u64* stack_base = reinterpret_cast(ctx->current_fiber->addr_context); + u64 stack_size = ctx->current_fiber->size_context; if (stack_base && *stack_base != kFiberStackSignature) { - UNREACHABLE_MSG("Stack overflow detected in fiber."); + UNREACHABLE_MSG("Stack overflow detected in fiber with size = 0x{:x}", stack_size); } } From 56f4b8a2b860fa14421b0e6884532b441ea34a12 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Fri, 24 Jan 2025 10:41:58 -0800 Subject: [PATCH 63/99] shader_recompiler: Implement shader export formats. (#2226) --- externals/sirit | 2 +- .../spirv/emit_spirv_bitwise_conversion.cpp | 44 +++++ .../backend/spirv/emit_spirv_instructions.h | 8 + .../frontend/translate/export.cpp | 152 ++++++++++++++---- .../frontend/translate/translate.h | 9 ++ .../frontend/translate/vector_alu.cpp | 33 ++-- src/shader_recompiler/ir/ir_emitter.cpp | 32 ++++ src/shader_recompiler/ir/ir_emitter.h | 8 + src/shader_recompiler/ir/opcodes.inc | 8 + .../ir/passes/constant_propagation_pass.cpp | 16 ++ src/shader_recompiler/runtime_info.h | 1 + src/video_core/amdgpu/liverpool.h | 4 + .../renderer_vulkan/vk_graphics_pipeline.h | 5 +- .../renderer_vulkan/vk_pipeline_cache.cpp | 21 ++- 14 files changed, 286 insertions(+), 57 deletions(-) diff --git a/externals/sirit b/externals/sirit index 26ad5a9d0..d6f3c0d99 160000 --- a/externals/sirit +++ b/externals/sirit @@ -1 +1 @@ -Subproject commit 26ad5a9d0fe13260b0d7d6c64419d01a196b2e32 +Subproject commit d6f3c0d99862ab2ff8f95e9ac221560f1f97e29a diff --git a/src/shader_recompiler/backend/spirv/emit_spirv_bitwise_conversion.cpp b/src/shader_recompiler/backend/spirv/emit_spirv_bitwise_conversion.cpp index 02ac74e19..539c6cb81 100644 --- a/src/shader_recompiler/backend/spirv/emit_spirv_bitwise_conversion.cpp +++ b/src/shader_recompiler/backend/spirv/emit_spirv_bitwise_conversion.cpp @@ -58,4 +58,48 @@ Id EmitUnpackHalf2x16(EmitContext& ctx, Id value) { return ctx.OpUnpackHalf2x16(ctx.F32[2], value); } +Id EmitPackUnorm2x16(EmitContext& ctx, Id value) { + return ctx.OpPackUnorm2x16(ctx.U32[1], value); +} + +Id EmitUnpackUnorm2x16(EmitContext& ctx, Id value) { + return ctx.OpUnpackUnorm2x16(ctx.F32[2], value); +} + +Id EmitPackSnorm2x16(EmitContext& ctx, Id value) { + return ctx.OpPackSnorm2x16(ctx.U32[1], value); +} + +Id EmitUnpackSnorm2x16(EmitContext& ctx, Id value) { + return ctx.OpUnpackSnorm2x16(ctx.F32[2], value); +} + +Id EmitPackUint2x16(EmitContext& ctx, Id value) { + // No SPIR-V instruction for this, do it manually. + const auto x{ctx.OpCompositeExtract(ctx.U32[1], value, 0)}; + const auto y{ctx.OpCompositeExtract(ctx.U32[1], value, 1)}; + return ctx.OpBitFieldInsert(ctx.U32[1], x, y, ctx.ConstU32(16U), ctx.ConstU32(16U)); +} + +Id EmitUnpackUint2x16(EmitContext& ctx, Id value) { + // No SPIR-V instruction for this, do it manually. + const auto x{ctx.OpBitFieldUExtract(ctx.U32[1], value, ctx.ConstU32(0U), ctx.ConstU32(16U))}; + const auto y{ctx.OpBitFieldUExtract(ctx.U32[1], value, ctx.ConstU32(16U), ctx.ConstU32(16U))}; + return ctx.OpCompositeConstruct(ctx.U32[2], x, y); +} + +Id EmitPackSint2x16(EmitContext& ctx, Id value) { + // No SPIR-V instruction for this, do it manually. + const auto x{ctx.OpCompositeExtract(ctx.U32[1], value, 0)}; + const auto y{ctx.OpCompositeExtract(ctx.U32[1], value, 1)}; + return ctx.OpBitFieldInsert(ctx.U32[1], x, y, ctx.ConstU32(16U), ctx.ConstU32(16U)); +} + +Id EmitUnpackSint2x16(EmitContext& ctx, Id value) { + // No SPIR-V instruction for this, do it manually. + const auto x{ctx.OpBitFieldSExtract(ctx.U32[1], value, ctx.ConstU32(0U), ctx.ConstU32(16U))}; + const auto y{ctx.OpBitFieldSExtract(ctx.U32[1], value, ctx.ConstU32(16U), ctx.ConstU32(16U))}; + return ctx.OpCompositeConstruct(ctx.U32[2], x, y); +} + } // namespace Shader::Backend::SPIRV diff --git a/src/shader_recompiler/backend/spirv/emit_spirv_instructions.h b/src/shader_recompiler/backend/spirv/emit_spirv_instructions.h index 4833dc9d0..842b13207 100644 --- a/src/shader_recompiler/backend/spirv/emit_spirv_instructions.h +++ b/src/shader_recompiler/backend/spirv/emit_spirv_instructions.h @@ -197,6 +197,14 @@ Id EmitPackFloat2x16(EmitContext& ctx, Id value); Id EmitUnpackFloat2x16(EmitContext& ctx, Id value); Id EmitPackHalf2x16(EmitContext& ctx, Id value); Id EmitUnpackHalf2x16(EmitContext& ctx, Id value); +Id EmitPackUnorm2x16(EmitContext& ctx, Id value); +Id EmitUnpackUnorm2x16(EmitContext& ctx, Id value); +Id EmitPackSnorm2x16(EmitContext& ctx, Id value); +Id EmitUnpackSnorm2x16(EmitContext& ctx, Id value); +Id EmitPackUint2x16(EmitContext& ctx, Id value); +Id EmitUnpackUint2x16(EmitContext& ctx, Id value); +Id EmitPackSint2x16(EmitContext& ctx, Id value); +Id EmitUnpackSint2x16(EmitContext& ctx, Id value); Id EmitFPAbs16(EmitContext& ctx, Id value); Id EmitFPAbs32(EmitContext& ctx, Id value); Id EmitFPAbs64(EmitContext& ctx, Id value); diff --git a/src/shader_recompiler/frontend/translate/export.cpp b/src/shader_recompiler/frontend/translate/export.cpp index 38ff9ae14..84c2ee658 100644 --- a/src/shader_recompiler/frontend/translate/export.cpp +++ b/src/shader_recompiler/frontend/translate/export.cpp @@ -7,6 +7,125 @@ namespace Shader::Gcn { +u32 SwizzleMrtComponent(const FragmentRuntimeInfo::PsColorBuffer& color_buffer, u32 comp) { + const auto [r, g, b, a] = color_buffer.swizzle; + const std::array swizzle_array = {r, g, b, a}; + const auto swizzled_comp_type = static_cast(swizzle_array[comp]); + constexpr auto min_comp_type = static_cast(AmdGpu::CompSwizzle::Red); + return swizzled_comp_type >= min_comp_type ? swizzled_comp_type - min_comp_type : comp; +} + +void Translator::ExportMrtValue(IR::Attribute attribute, u32 comp, const IR::F32& value, + const FragmentRuntimeInfo::PsColorBuffer& color_buffer) { + const auto converted = ApplyWriteNumberConversion(ir, value, color_buffer.num_conversion); + ir.SetAttribute(attribute, converted, comp); +} + +void Translator::ExportMrtCompressed(IR::Attribute attribute, u32 idx, const IR::U32& value) { + const u32 color_buffer_idx = + static_cast(attribute) - static_cast(IR::Attribute::RenderTarget0); + const auto color_buffer = runtime_info.fs_info.color_buffers[color_buffer_idx]; + + IR::Value unpacked_value; + bool is_integer = false; + switch (color_buffer.export_format) { + case AmdGpu::Liverpool::ShaderExportFormat::Zero: + // No export + return; + case AmdGpu::Liverpool::ShaderExportFormat::ABGR_FP16: + unpacked_value = ir.UnpackHalf2x16(value); + break; + case AmdGpu::Liverpool::ShaderExportFormat::ABGR_UNORM16: + unpacked_value = ir.UnpackUnorm2x16(value); + break; + case AmdGpu::Liverpool::ShaderExportFormat::ABGR_SNORM16: + unpacked_value = ir.UnpackSnorm2x16(value); + break; + case AmdGpu::Liverpool::ShaderExportFormat::ABGR_UINT16: + unpacked_value = ir.UnpackUint2x16(value); + is_integer = true; + break; + case AmdGpu::Liverpool::ShaderExportFormat::ABGR_SINT16: + unpacked_value = ir.UnpackSint2x16(value); + is_integer = true; + break; + default: + UNREACHABLE_MSG("Unimplemented compressed MRT export format {}", + static_cast(color_buffer.export_format)); + break; + } + + const auto r = ir.CompositeExtract(unpacked_value, 0); + const auto g = ir.CompositeExtract(unpacked_value, 1); + const IR::F32 float_r = is_integer ? ir.BitCast(IR::U32{r}) : IR::F32{r}; + const IR::F32 float_g = is_integer ? ir.BitCast(IR::U32{g}) : IR::F32{g}; + + const auto swizzled_r = SwizzleMrtComponent(color_buffer, idx * 2); + const auto swizzled_g = SwizzleMrtComponent(color_buffer, idx * 2 + 1); + + ExportMrtValue(attribute, swizzled_r, float_r, color_buffer); + ExportMrtValue(attribute, swizzled_g, float_g, color_buffer); +} + +void Translator::ExportMrtUncompressed(IR::Attribute attribute, u32 comp, const IR::F32& value) { + const u32 color_buffer_idx = + static_cast(attribute) - static_cast(IR::Attribute::RenderTarget0); + const auto color_buffer = runtime_info.fs_info.color_buffers[color_buffer_idx]; + const auto swizzled_comp = SwizzleMrtComponent(color_buffer, comp); + + switch (color_buffer.export_format) { + case AmdGpu::Liverpool::ShaderExportFormat::Zero: + // No export + return; + case AmdGpu::Liverpool::ShaderExportFormat::R_32: + // Red only + if (swizzled_comp != 0) { + return; + } + break; + case AmdGpu::Liverpool::ShaderExportFormat::GR_32: + // Red and Green only + if (swizzled_comp != 0 && swizzled_comp != 1) { + return; + } + break; + case AmdGpu::Liverpool::ShaderExportFormat::AR_32: + // Red and Alpha only + if (swizzled_comp != 0 && swizzled_comp != 3) { + return; + } + break; + case AmdGpu::Liverpool::ShaderExportFormat::ABGR_32: + // All components + break; + default: + UNREACHABLE_MSG("Unimplemented uncompressed MRT export format {}", + static_cast(color_buffer.export_format)); + break; + } + ExportMrtValue(attribute, swizzled_comp, value, color_buffer); +} + +void Translator::ExportCompressed(IR::Attribute attribute, u32 idx, const IR::U32& value) { + if (IsMrt(attribute)) { + ExportMrtCompressed(attribute, idx, value); + return; + } + const IR::Value unpacked_value = ir.UnpackHalf2x16(value); + const IR::F32 r = IR::F32{ir.CompositeExtract(unpacked_value, 0)}; + const IR::F32 g = IR::F32{ir.CompositeExtract(unpacked_value, 1)}; + ir.SetAttribute(attribute, r, idx * 2); + ir.SetAttribute(attribute, g, idx * 2 + 1); +} + +void Translator::ExportUncompressed(IR::Attribute attribute, u32 comp, const IR::F32& value) { + if (IsMrt(attribute)) { + ExportMrtUncompressed(attribute, comp, value); + return; + } + ir.SetAttribute(attribute, value, comp); +} + void Translator::EmitExport(const GcnInst& inst) { if (ir.block->has_multiple_predecessors && info.stage == Stage::Fragment) { ir.Discard(ir.LogicalNot(ir.GetExec())); @@ -26,41 +145,15 @@ void Translator::EmitExport(const GcnInst& inst) { IR::VectorReg(inst.src[3].code), }; - const auto set_attribute = [&](u32 comp, IR::F32 value) { - if (!IR::IsMrt(attrib)) { - ir.SetAttribute(attrib, value, comp); - return; - } - const u32 index = u32(attrib) - u32(IR::Attribute::RenderTarget0); - const auto col_buf = runtime_info.fs_info.color_buffers[index]; - const auto converted = IR::ApplyWriteNumberConversion(ir, value, col_buf.num_conversion); - const auto [r, g, b, a] = col_buf.swizzle; - const std::array swizzle_array = {r, g, b, a}; - const auto swizzled_comp = swizzle_array[comp]; - if (u32(swizzled_comp) < u32(AmdGpu::CompSwizzle::Red)) { - ir.SetAttribute(attrib, converted, comp); - return; - } - ir.SetAttribute(attrib, converted, u32(swizzled_comp) - u32(AmdGpu::CompSwizzle::Red)); - }; - - const auto unpack = [&](u32 idx) { - const IR::Value value = ir.UnpackHalf2x16(ir.GetVectorReg(vsrc[idx])); - const IR::F32 r = IR::F32{ir.CompositeExtract(value, 0)}; - const IR::F32 g = IR::F32{ir.CompositeExtract(value, 1)}; - set_attribute(idx * 2, r); - set_attribute(idx * 2 + 1, g); - }; - // Components are float16 packed into a VGPR if (exp.compr) { // Export R, G if (exp.en & 1) { - unpack(0); + ExportCompressed(attrib, 0, ir.GetVectorReg(vsrc[0])); } // Export B, A if ((exp.en >> 2) & 1) { - unpack(1); + ExportCompressed(attrib, 1, ir.GetVectorReg(vsrc[1])); } } else { // Components are float32 into separate VGPRS @@ -69,8 +162,7 @@ void Translator::EmitExport(const GcnInst& inst) { if ((mask & 1) == 0) { continue; } - const IR::F32 comp = ir.GetVectorReg(vsrc[i]); - set_attribute(i, comp); + ExportUncompressed(attrib, i, ir.GetVectorReg(vsrc[i])); } } if (IR::IsMrt(attrib)) { diff --git a/src/shader_recompiler/frontend/translate/translate.h b/src/shader_recompiler/frontend/translate/translate.h index 496455b50..287885854 100644 --- a/src/shader_recompiler/frontend/translate/translate.h +++ b/src/shader_recompiler/frontend/translate/translate.h @@ -170,6 +170,7 @@ public: void V_SUBBREV_U32(const GcnInst& inst); void V_LDEXP_F32(const GcnInst& inst); void V_CVT_PKNORM_U16_F32(const GcnInst& inst); + void V_CVT_PKNORM_I16_F32(const GcnInst& inst); void V_CVT_PKRTZ_F16_F32(const GcnInst& inst); // VOP1 @@ -244,6 +245,7 @@ public: void V_SAD(const GcnInst& inst); void V_SAD_U32(const GcnInst& inst); void V_CVT_PK_U16_U32(const GcnInst& inst); + void V_CVT_PK_I16_I32(const GcnInst& inst); void V_CVT_PK_U8_F32(const GcnInst& inst); void V_LSHL_B64(const GcnInst& inst); void V_MUL_F64(const GcnInst& inst); @@ -306,6 +308,13 @@ private: IR::F32 SelectCubeResult(const IR::F32& x, const IR::F32& y, const IR::F32& z, const IR::F32& x_res, const IR::F32& y_res, const IR::F32& z_res); + void ExportMrtValue(IR::Attribute attribute, u32 comp, const IR::F32& value, + const FragmentRuntimeInfo::PsColorBuffer& color_buffer); + void ExportMrtCompressed(IR::Attribute attribute, u32 idx, const IR::U32& value); + void ExportMrtUncompressed(IR::Attribute attribute, u32 comp, const IR::F32& value); + void ExportCompressed(IR::Attribute attribute, u32 idx, const IR::U32& value); + void ExportUncompressed(IR::Attribute attribute, u32 comp, const IR::F32& value); + void LogMissingOpcode(const GcnInst& inst); private: diff --git a/src/shader_recompiler/frontend/translate/vector_alu.cpp b/src/shader_recompiler/frontend/translate/vector_alu.cpp index 42dbcc513..f73618dbe 100644 --- a/src/shader_recompiler/frontend/translate/vector_alu.cpp +++ b/src/shader_recompiler/frontend/translate/vector_alu.cpp @@ -96,6 +96,8 @@ void Translator::EmitVectorAlu(const GcnInst& inst) { return V_LDEXP_F32(inst); case Opcode::V_CVT_PKNORM_U16_F32: return V_CVT_PKNORM_U16_F32(inst); + case Opcode::V_CVT_PKNORM_I16_F32: + return V_CVT_PKNORM_I16_F32(inst); case Opcode::V_CVT_PKRTZ_F16_F32: return V_CVT_PKRTZ_F16_F32(inst); @@ -376,6 +378,8 @@ void Translator::EmitVectorAlu(const GcnInst& inst) { return V_SAD_U32(inst); case Opcode::V_CVT_PK_U16_U32: return V_CVT_PK_U16_U32(inst); + case Opcode::V_CVT_PK_I16_I32: + return V_CVT_PK_I16_I32(inst); case Opcode::V_CVT_PK_U8_F32: return V_CVT_PK_U8_F32(inst); case Opcode::V_LSHL_B64: @@ -645,12 +649,15 @@ void Translator::V_LDEXP_F32(const GcnInst& inst) { } void Translator::V_CVT_PKNORM_U16_F32(const GcnInst& inst) { - const IR::F32 src0{GetSrc(inst.src[0])}; - const IR::F32 src1{GetSrc(inst.src[1])}; - const IR::U32 dst0 = ir.ConvertFToU(32, ir.FPMul(src0, ir.Imm32(65535.f))); - const IR::U32 dst1 = ir.ConvertFToU(32, ir.FPMul(src1, ir.Imm32(65535.f))); - const IR::VectorReg dst_reg{inst.dst[0].code}; - ir.SetVectorReg(dst_reg, ir.BitFieldInsert(dst0, dst1, ir.Imm32(16), ir.Imm32(16))); + const IR::Value vec_f32 = + ir.CompositeConstruct(GetSrc(inst.src[0]), GetSrc(inst.src[1])); + SetDst(inst.dst[0], ir.PackUnorm2x16(vec_f32)); +} + +void Translator::V_CVT_PKNORM_I16_F32(const GcnInst& inst) { + const IR::Value vec_f32 = + ir.CompositeConstruct(GetSrc(inst.src[0]), GetSrc(inst.src[1])); + SetDst(inst.dst[0], ir.PackSnorm2x16(vec_f32)); } void Translator::V_CVT_PKRTZ_F16_F32(const GcnInst& inst) { @@ -1237,11 +1244,15 @@ void Translator::V_SAD_U32(const GcnInst& inst) { } void Translator::V_CVT_PK_U16_U32(const GcnInst& inst) { - const IR::U32 src0{GetSrc(inst.src[0])}; - const IR::U32 src1{GetSrc(inst.src[1])}; - const IR::U32 lo = ir.IMin(src0, ir.Imm32(0xFFFF), false); - const IR::U32 hi = ir.IMin(src1, ir.Imm32(0xFFFF), false); - SetDst(inst.dst[0], ir.BitFieldInsert(lo, hi, ir.Imm32(16), ir.Imm32(16))); + const IR::Value vec_u32 = + ir.CompositeConstruct(GetSrc(inst.src[0]), GetSrc(inst.src[1])); + SetDst(inst.dst[0], ir.PackUint2x16(vec_u32)); +} + +void Translator::V_CVT_PK_I16_I32(const GcnInst& inst) { + const IR::Value vec_u32 = + ir.CompositeConstruct(GetSrc(inst.src[0]), GetSrc(inst.src[1])); + SetDst(inst.dst[0], ir.PackSint2x16(vec_u32)); } void Translator::V_CVT_PK_U8_F32(const GcnInst& inst) { diff --git a/src/shader_recompiler/ir/ir_emitter.cpp b/src/shader_recompiler/ir/ir_emitter.cpp index f0558665b..ecbe1f838 100644 --- a/src/shader_recompiler/ir/ir_emitter.cpp +++ b/src/shader_recompiler/ir/ir_emitter.cpp @@ -795,6 +795,38 @@ Value IREmitter::UnpackHalf2x16(const U32& value) { return Inst(Opcode::UnpackHalf2x16, value); } +U32 IREmitter::PackUnorm2x16(const Value& vector) { + return Inst(Opcode::PackUnorm2x16, vector); +} + +Value IREmitter::UnpackUnorm2x16(const U32& value) { + return Inst(Opcode::UnpackUnorm2x16, value); +} + +U32 IREmitter::PackSnorm2x16(const Value& vector) { + return Inst(Opcode::PackSnorm2x16, vector); +} + +Value IREmitter::UnpackSnorm2x16(const U32& value) { + return Inst(Opcode::UnpackSnorm2x16, value); +} + +U32 IREmitter::PackUint2x16(const Value& value) { + return Inst(Opcode::PackUint2x16, value); +} + +Value IREmitter::UnpackUint2x16(const U32& value) { + return Inst(Opcode::UnpackUint2x16, value); +} + +U32 IREmitter::PackSint2x16(const Value& value) { + return Inst(Opcode::PackSint2x16, value); +} + +Value IREmitter::UnpackSint2x16(const U32& value) { + return Inst(Opcode::UnpackSint2x16, value); +} + F32F64 IREmitter::FPMul(const F32F64& a, const F32F64& b) { if (a.Type() != b.Type()) { UNREACHABLE_MSG("Mismatching types {} and {}", a.Type(), b.Type()); diff --git a/src/shader_recompiler/ir/ir_emitter.h b/src/shader_recompiler/ir/ir_emitter.h index 5dd49ce7a..97b94187a 100644 --- a/src/shader_recompiler/ir/ir_emitter.h +++ b/src/shader_recompiler/ir/ir_emitter.h @@ -175,6 +175,14 @@ public: [[nodiscard]] U32 PackHalf2x16(const Value& vector); [[nodiscard]] Value UnpackHalf2x16(const U32& value); + [[nodiscard]] U32 PackUnorm2x16(const Value& vector); + [[nodiscard]] Value UnpackUnorm2x16(const U32& value); + [[nodiscard]] U32 PackSnorm2x16(const Value& vector); + [[nodiscard]] Value UnpackSnorm2x16(const U32& value); + [[nodiscard]] U32 PackUint2x16(const Value& value); + [[nodiscard]] Value UnpackUint2x16(const U32& value); + [[nodiscard]] U32 PackSint2x16(const Value& value); + [[nodiscard]] Value UnpackSint2x16(const U32& value); [[nodiscard]] F32F64 FPAdd(const F32F64& a, const F32F64& b); [[nodiscard]] F32F64 FPSub(const F32F64& a, const F32F64& b); diff --git a/src/shader_recompiler/ir/opcodes.inc b/src/shader_recompiler/ir/opcodes.inc index 63a4e1e62..6750be5a6 100644 --- a/src/shader_recompiler/ir/opcodes.inc +++ b/src/shader_recompiler/ir/opcodes.inc @@ -187,6 +187,14 @@ OPCODE(PackFloat2x16, U32, F16x OPCODE(UnpackFloat2x16, F16x2, U32, ) OPCODE(PackHalf2x16, U32, F32x2, ) OPCODE(UnpackHalf2x16, F32x2, U32, ) +OPCODE(PackUnorm2x16, U32, F32x2, ) +OPCODE(UnpackUnorm2x16, F32x2, U32, ) +OPCODE(PackSnorm2x16, U32, F32x2, ) +OPCODE(UnpackSnorm2x16, F32x2, U32, ) +OPCODE(PackUint2x16, U32, U32x2, ) +OPCODE(UnpackUint2x16, U32x2, U32, ) +OPCODE(PackSint2x16, U32, U32x2, ) +OPCODE(UnpackSint2x16, U32x2, U32, ) // Floating-point operations OPCODE(FPAbs32, F32, F32, ) diff --git a/src/shader_recompiler/ir/passes/constant_propagation_pass.cpp b/src/shader_recompiler/ir/passes/constant_propagation_pass.cpp index 12a1b56e9..c72b9e835 100644 --- a/src/shader_recompiler/ir/passes/constant_propagation_pass.cpp +++ b/src/shader_recompiler/ir/passes/constant_propagation_pass.cpp @@ -348,6 +348,22 @@ void ConstantPropagation(IR::Block& block, IR::Inst& inst) { return FoldInverseFunc(inst, IR::Opcode::UnpackFloat2x16); case IR::Opcode::UnpackFloat2x16: return FoldInverseFunc(inst, IR::Opcode::PackFloat2x16); + case IR::Opcode::PackUnorm2x16: + return FoldInverseFunc(inst, IR::Opcode::UnpackUnorm2x16); + case IR::Opcode::UnpackUnorm2x16: + return FoldInverseFunc(inst, IR::Opcode::PackUnorm2x16); + case IR::Opcode::PackSnorm2x16: + return FoldInverseFunc(inst, IR::Opcode::UnpackSnorm2x16); + case IR::Opcode::UnpackSnorm2x16: + return FoldInverseFunc(inst, IR::Opcode::PackSnorm2x16); + case IR::Opcode::PackUint2x16: + return FoldInverseFunc(inst, IR::Opcode::UnpackUint2x16); + case IR::Opcode::UnpackUint2x16: + return FoldInverseFunc(inst, IR::Opcode::PackUint2x16); + case IR::Opcode::PackSint2x16: + return FoldInverseFunc(inst, IR::Opcode::UnpackSint2x16); + case IR::Opcode::UnpackSint2x16: + return FoldInverseFunc(inst, IR::Opcode::PackSint2x16); case IR::Opcode::SelectU1: case IR::Opcode::SelectU8: case IR::Opcode::SelectU16: diff --git a/src/shader_recompiler/runtime_info.h b/src/shader_recompiler/runtime_info.h index 2bf5e3f0a..103c1faa8 100644 --- a/src/shader_recompiler/runtime_info.h +++ b/src/shader_recompiler/runtime_info.h @@ -184,6 +184,7 @@ struct FragmentRuntimeInfo { AmdGpu::NumberFormat num_format; AmdGpu::NumberConversion num_conversion; AmdGpu::CompMapping swizzle; + AmdGpu::Liverpool::ShaderExportFormat export_format; auto operator<=>(const PsColorBuffer&) const noexcept = default; }; diff --git a/src/video_core/amdgpu/liverpool.h b/src/video_core/amdgpu/liverpool.h index ec9c92ef1..67821b0f2 100644 --- a/src/video_core/amdgpu/liverpool.h +++ b/src/video_core/amdgpu/liverpool.h @@ -266,6 +266,10 @@ struct Liverpool { BitField<20, 4, ShaderExportFormat> col5; BitField<24, 4, ShaderExportFormat> col6; BitField<28, 4, ShaderExportFormat> col7; + + [[nodiscard]] ShaderExportFormat GetFormat(const u32 buf_idx) const { + return static_cast((raw >> (buf_idx * 4)) & 0xfu); + } }; union VsOutputControl { diff --git a/src/video_core/renderer_vulkan/vk_graphics_pipeline.h b/src/video_core/renderer_vulkan/vk_graphics_pipeline.h index 9a20f94c1..8c5cb1f3b 100644 --- a/src/video_core/renderer_vulkan/vk_graphics_pipeline.h +++ b/src/video_core/renderer_vulkan/vk_graphics_pipeline.h @@ -35,9 +35,8 @@ struct GraphicsPipelineKey { std::array stage_hashes; u32 num_color_attachments; std::array color_formats; - std::array color_num_formats; - std::array color_num_conversions; - std::array color_swizzles; + std::array + color_buffers; vk::Format depth_format; vk::Format stencil_format; diff --git a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp index c6a56745d..3728a55fb 100644 --- a/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp +++ b/src/video_core/renderer_vulkan/vk_pipeline_cache.cpp @@ -167,11 +167,7 @@ const Shader::RuntimeInfo& PipelineCache::BuildRuntimeInfo(Stage stage, LogicalS }; } for (u32 i = 0; i < Shader::MaxColorBuffers; i++) { - info.fs_info.color_buffers[i] = { - .num_format = graphics_key.color_num_formats[i], - .num_conversion = graphics_key.color_num_conversions[i], - .swizzle = graphics_key.color_swizzles[i], - }; + info.fs_info.color_buffers[i] = graphics_key.color_buffers[i]; } break; } @@ -309,11 +305,9 @@ bool PipelineCache::RefreshGraphicsKey() { // order. We need to do some arrays compaction at this stage key.num_color_attachments = 0; key.color_formats.fill(vk::Format::eUndefined); - key.color_num_formats.fill(AmdGpu::NumberFormat::Unorm); - key.color_num_conversions.fill(AmdGpu::NumberConversion::None); + key.color_buffers.fill({}); key.blend_controls.fill({}); key.write_masks.fill({}); - key.color_swizzles.fill({}); key.vertex_buffer_formats.fill(vk::Format::eUndefined); key.patch_control_points = 0; @@ -338,9 +332,12 @@ bool PipelineCache::RefreshGraphicsKey() { key.color_formats[remapped_cb] = LiverpoolToVK::SurfaceFormat(col_buf.GetDataFmt(), col_buf.GetNumberFmt()); - key.color_num_formats[remapped_cb] = col_buf.GetNumberFmt(); - key.color_num_conversions[remapped_cb] = col_buf.GetNumberConversion(); - key.color_swizzles[remapped_cb] = col_buf.Swizzle(); + key.color_buffers[remapped_cb] = { + .num_format = col_buf.GetNumberFmt(), + .num_conversion = col_buf.GetNumberConversion(), + .swizzle = col_buf.Swizzle(), + .export_format = regs.color_export_format.GetFormat(cb), + }; } fetch_shader = std::nullopt; @@ -456,7 +453,7 @@ bool PipelineCache::RefreshGraphicsKey() { // of the latter we need to change format to undefined, and either way we need to // increment the index for the null attachment binding. key.color_formats[remapped_cb] = vk::Format::eUndefined; - key.color_swizzles[remapped_cb] = {}; + key.color_buffers[remapped_cb] = {}; ++remapped_cb; continue; } From a51c8c17e07063065fe1780d648c3b4808f31d59 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Fri, 24 Jan 2025 12:47:04 -0800 Subject: [PATCH 64/99] shader_recompiler: Fix image write swizzles. (#2236) --- .../ir/passes/resource_tracking_pass.cpp | 4 +-- src/video_core/amdgpu/types.h | 31 ++++++++++++++++--- 2 files changed, 29 insertions(+), 6 deletions(-) diff --git a/src/shader_recompiler/ir/passes/resource_tracking_pass.cpp b/src/shader_recompiler/ir/passes/resource_tracking_pass.cpp index d94c5223a..43d125bf0 100644 --- a/src/shader_recompiler/ir/passes/resource_tracking_pass.cpp +++ b/src/shader_recompiler/ir/passes/resource_tracking_pass.cpp @@ -569,7 +569,7 @@ void PatchTextureBufferArgs(IR::Block& block, IR::Inst& inst, Info& info) { inst.SetArg(1, CalculateBufferAddress(ir, inst, info, buffer, 1U)); if (inst.GetOpcode() == IR::Opcode::StoreBufferFormatF32) { - const auto swizzled = ApplySwizzle(ir, inst.Arg(2), buffer.DstSelect()); + const auto swizzled = ApplySwizzle(ir, inst.Arg(2), buffer.DstSelect().Inverse()); const auto converted = ApplyWriteNumberConversionVec4(ir, swizzled, buffer.GetNumberConversion()); inst.SetArg(2, converted); @@ -829,7 +829,7 @@ void PatchImageArgs(IR::Block& block, IR::Inst& inst, Info& info) { auto texel = inst.Arg(4); if (is_storage) { // Storage image requires shader swizzle. - texel = ApplySwizzle(ir, texel, image.DstSelect()); + texel = ApplySwizzle(ir, texel, image.DstSelect().Inverse()); } const auto converted = ApplyWriteNumberConversionVec4(ir, texel, image.GetNumberConversion()); diff --git a/src/video_core/amdgpu/types.h b/src/video_core/amdgpu/types.h index 63e184cc5..b442b2f1e 100644 --- a/src/video_core/amdgpu/types.h +++ b/src/video_core/amdgpu/types.h @@ -200,10 +200,10 @@ enum class NumberConversion : u32 { }; struct CompMapping { - CompSwizzle r : 3; - CompSwizzle g : 3; - CompSwizzle b : 3; - CompSwizzle a : 3; + CompSwizzle r; + CompSwizzle g; + CompSwizzle b; + CompSwizzle a; auto operator<=>(const CompMapping& other) const = default; @@ -217,6 +217,15 @@ struct CompMapping { }; } + [[nodiscard]] CompMapping Inverse() const { + CompMapping result{}; + InverseSingle(result.r, CompSwizzle::Red); + InverseSingle(result.g, CompSwizzle::Green); + InverseSingle(result.b, CompSwizzle::Blue); + InverseSingle(result.a, CompSwizzle::Alpha); + return result; + } + private: template T ApplySingle(const std::array& data, const CompSwizzle swizzle) const { @@ -237,6 +246,20 @@ private: UNREACHABLE(); } } + + void InverseSingle(CompSwizzle& dst, const CompSwizzle target) const { + if (r == target) { + dst = CompSwizzle::Red; + } else if (g == target) { + dst = CompSwizzle::Green; + } else if (b == target) { + dst = CompSwizzle::Blue; + } else if (a == target) { + dst = CompSwizzle::Alpha; + } else { + dst = CompSwizzle::Zero; + } + } }; inline DataFormat RemapDataFormat(const DataFormat format) { From 361532418ce8a252fd873eacff0d0b83504eeffb Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Fri, 24 Jan 2025 12:47:24 -0800 Subject: [PATCH 65/99] externals: Update SPIRV-Cross for MoltenVK (#2237) --- externals/MoltenVK/SPIRV-Cross | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/externals/MoltenVK/SPIRV-Cross b/externals/MoltenVK/SPIRV-Cross index 6173e24b3..1a7b7ef6d 160000 --- a/externals/MoltenVK/SPIRV-Cross +++ b/externals/MoltenVK/SPIRV-Cross @@ -1 +1 @@ -Subproject commit 6173e24b31f09a0c3217103a130e74c4ddec14a6 +Subproject commit 1a7b7ef6de02cf6767e42b10ddad217c45e90d47 From 7072dfc99fdca87e833bf588587debef3e9b08bd Mon Sep 17 00:00:00 2001 From: hspir404 Date: Fri, 24 Jan 2025 21:56:21 +0000 Subject: [PATCH 66/99] Fix stale heap read in UnmapMemoryImpl (#2232) --- src/core/memory.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/core/memory.cpp b/src/core/memory.cpp index a8dd72acc..271092eaf 100644 --- a/src/core/memory.cpp +++ b/src/core/memory.cpp @@ -418,8 +418,9 @@ u64 MemoryManager::UnmapBytesFromEntry(VAddr virtual_addr, VirtualMemoryArea vma vma.phys_base = 0; vma.disallow_merge = false; vma.name = ""; - MergeAdjacent(vma_map, new_it); - bool readonly_file = vma.prot == MemoryProt::CpuRead && type == VMAType::File; + const auto post_merge_it = MergeAdjacent(vma_map, new_it); + auto& post_merge_vma = post_merge_it->second; + bool readonly_file = post_merge_vma.prot == MemoryProt::CpuRead && type == VMAType::File; if (type != VMAType::Reserved && type != VMAType::PoolReserved) { // Unmap the memory region. impl.Unmap(vma_base_addr, vma_base_size, start_in_vma, start_in_vma + adjusted_size, From 73b7d344600a6a7aabb55d44dfe888deb8df312f Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Fri, 24 Jan 2025 19:55:27 -0800 Subject: [PATCH 67/99] hotfix: Drop scePadSetLightBar log to debug level. Some games like to spam this a lot, and we already handle it. --- src/core/libraries/pad/pad.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/libraries/pad/pad.cpp b/src/core/libraries/pad/pad.cpp index f2b81fbe0..d940d0cfa 100644 --- a/src/core/libraries/pad/pad.cpp +++ b/src/core/libraries/pad/pad.cpp @@ -473,7 +473,7 @@ int PS4_SYSV_ABI scePadSetForceIntercepted() { int PS4_SYSV_ABI scePadSetLightBar(s32 handle, const OrbisPadLightBarParam* pParam) { if (pParam != nullptr) { - LOG_INFO(Lib_Pad, "scePadSetLightBar called handle = {} rgb = {} {} {}", handle, pParam->r, + LOG_DEBUG(Lib_Pad, "called handle = {} rgb = {} {} {}", handle, pParam->r, pParam->g, pParam->b); if (pParam->r < 0xD && pParam->g < 0xD && pParam->b < 0xD) { From e433f3116dd9a36a353d054e1a371e7ff257f87a Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Fri, 24 Jan 2025 19:57:04 -0800 Subject: [PATCH 68/99] hotfix 2: clang format --- src/core/libraries/pad/pad.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/libraries/pad/pad.cpp b/src/core/libraries/pad/pad.cpp index d940d0cfa..18709bcb2 100644 --- a/src/core/libraries/pad/pad.cpp +++ b/src/core/libraries/pad/pad.cpp @@ -473,8 +473,8 @@ int PS4_SYSV_ABI scePadSetForceIntercepted() { int PS4_SYSV_ABI scePadSetLightBar(s32 handle, const OrbisPadLightBarParam* pParam) { if (pParam != nullptr) { - LOG_DEBUG(Lib_Pad, "called handle = {} rgb = {} {} {}", handle, pParam->r, - pParam->g, pParam->b); + LOG_DEBUG(Lib_Pad, "called handle = {} rgb = {} {} {}", handle, pParam->r, pParam->g, + pParam->b); if (pParam->r < 0xD && pParam->g < 0xD && pParam->b < 0xD) { LOG_INFO(Lib_Pad, "Invalid lightbar setting"); From 564dbc7b94b02c70febd901f613ccb567923cb5e Mon Sep 17 00:00:00 2001 From: Ian Carpenter Date: Sat, 25 Jan 2025 04:00:52 -0500 Subject: [PATCH 69/99] system_service: Add simple event queue and push an EntitlementUpdate event to it when app content is initialized (#2238) --- .../libraries/app_content/app_content.cpp | 10 ++++++++ src/core/libraries/system/systemservice.cpp | 23 ++++++++++++++++--- src/core/libraries/system/systemservice.h | 4 ++++ 3 files changed, 34 insertions(+), 3 deletions(-) diff --git a/src/core/libraries/app_content/app_content.cpp b/src/core/libraries/app_content/app_content.cpp index 1d23e7f44..1223022c5 100644 --- a/src/core/libraries/app_content/app_content.cpp +++ b/src/core/libraries/app_content/app_content.cpp @@ -12,6 +12,7 @@ #include "core/file_sys/fs.h" #include "core/libraries/app_content/app_content_error.h" #include "core/libraries/libs.h" +#include "core/libraries/system/systemservice.h" namespace Libraries::AppContent { @@ -262,6 +263,15 @@ int PS4_SYSV_ABI sceAppContentInitialize(const OrbisAppContentInitParam* initPar entitlement_label.copy(info.entitlement_label, sizeof(info.entitlement_label)); } } + + if (addcont_count > 0) { + SystemService::OrbisSystemServiceEvent event{}; + event.event_type = SystemService::OrbisSystemServiceEventType::EntitlementUpdate; + event.service_entitlement_update.user_id = 0; + event.service_entitlement_update.np_service_label = 0; + SystemService::PushSystemServiceEvent(event); + } + return ORBIS_OK; } diff --git a/src/core/libraries/system/systemservice.cpp b/src/core/libraries/system/systemservice.cpp index ebb9f4392..a67b9a2fc 100644 --- a/src/core/libraries/system/systemservice.cpp +++ b/src/core/libraries/system/systemservice.cpp @@ -10,6 +10,8 @@ namespace Libraries::SystemService { bool g_splash_status{true}; +std::queue g_event_queue; +std::mutex g_event_queue_mutex; bool IsSplashVisible() { return Config::showSplash() && g_splash_status; @@ -1772,7 +1774,9 @@ s32 PS4_SYSV_ABI sceSystemServiceGetStatus(OrbisSystemServiceStatus* status) { LOG_ERROR(Lib_SystemService, "OrbisSystemServiceStatus is null"); return ORBIS_SYSTEM_SERVICE_ERROR_PARAMETER; } - status->event_num = 0; + + std::lock_guard lock(g_event_queue_mutex); + status->event_num = static_cast(g_event_queue.size()); status->is_system_ui_overlaid = false; status->is_in_background_execution = false; status->is_cpu_mode7_cpu_normal = true; @@ -1940,11 +1944,19 @@ int PS4_SYSV_ABI sceSystemServiceRaiseExceptionLocalProcess() { } s32 PS4_SYSV_ABI sceSystemServiceReceiveEvent(OrbisSystemServiceEvent* event) { - LOG_ERROR(Lib_SystemService, "(STUBBED) called"); + LOG_TRACE(Lib_SystemService, "called"); if (event == nullptr) { return ORBIS_SYSTEM_SERVICE_ERROR_PARAMETER; } - return ORBIS_SYSTEM_SERVICE_ERROR_NO_EVENT; + + std::lock_guard lock(g_event_queue_mutex); + if (g_event_queue.empty()) { + return ORBIS_SYSTEM_SERVICE_ERROR_NO_EVENT; + } + + *event = g_event_queue.front(); + g_event_queue.pop(); + return ORBIS_OK; } int PS4_SYSV_ABI sceSystemServiceReenableMusicPlayer() { @@ -2412,6 +2424,11 @@ int PS4_SYSV_ABI Func_CB5E885E225F69F0() { return ORBIS_OK; } +void PushSystemServiceEvent(const OrbisSystemServiceEvent& event) { + std::lock_guard lock(g_event_queue_mutex); + g_event_queue.push(event); +} + void RegisterlibSceSystemService(Core::Loader::SymbolsResolver* sym) { LIB_FUNCTION("alZfRdr2RP8", "libSceAppMessaging", 1, "libSceSystemService", 1, 1, sceAppMessagingClearEventFlag); diff --git a/src/core/libraries/system/systemservice.h b/src/core/libraries/system/systemservice.h index cdd3c15e8..c22ccc88f 100644 --- a/src/core/libraries/system/systemservice.h +++ b/src/core/libraries/system/systemservice.h @@ -4,6 +4,8 @@ // https://github.com/OpenOrbis/OpenOrbis-PS4-Toolchain/blob/master/include/orbis/_types/sys_service.h #pragma once +#include +#include #include "common/types.h" namespace Core::Loader { @@ -603,5 +605,7 @@ int PS4_SYSV_ABI sceSystemServiceReenableVoiceRecognition(); int PS4_SYSV_ABI Func_6B1CDB955F0EBD65(); int PS4_SYSV_ABI Func_CB5E885E225F69F0(); +void PushSystemServiceEvent(const OrbisSystemServiceEvent& event); + void RegisterlibSceSystemService(Core::Loader::SymbolsResolver* sym); } // namespace Libraries::SystemService From a5a1253185fc6b3231e30477ebb8dba5375ac936 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sat, 25 Jan 2025 04:12:18 -0800 Subject: [PATCH 70/99] liverpool: Implement PM4 MEM_SEMAPHORE. (#2235) --- src/video_core/amdgpu/liverpool.cpp | 24 ++++++++++++ src/video_core/amdgpu/pm4_cmds.h | 61 +++++++++++++++++++++++++++++ 2 files changed, 85 insertions(+) diff --git a/src/video_core/amdgpu/liverpool.cpp b/src/video_core/amdgpu/liverpool.cpp index 8355dd1e6..2f40d4136 100644 --- a/src/video_core/amdgpu/liverpool.cpp +++ b/src/video_core/amdgpu/liverpool.cpp @@ -636,6 +636,18 @@ Liverpool::Task Liverpool::ProcessGraphics(std::span dcb, std::span(header); + if (mem_semaphore->IsSignaling()) { + mem_semaphore->Signal(); + } else { + while (!mem_semaphore->Signaled()) { + YIELD_GFX(); + } + mem_semaphore->Decrement(); + } + break; + } case PM4ItOpcode::AcquireMem: { // const auto* acquire_mem = reinterpret_cast(header); break; @@ -848,6 +860,18 @@ Liverpool::Task Liverpool::ProcessCompute(std::span acb, u32 vqid) { } break; } + case PM4ItOpcode::MemSemaphore: { + const auto* mem_semaphore = reinterpret_cast(header); + if (mem_semaphore->IsSignaling()) { + mem_semaphore->Signal(); + } else { + while (!mem_semaphore->Signaled()) { + YIELD_ASC(vqid); + } + mem_semaphore->Decrement(); + } + break; + } case PM4ItOpcode::WaitRegMem: { const auto* wait_reg_mem = reinterpret_cast(header); ASSERT(wait_reg_mem->engine.Value() == PM4CmdWaitRegMem::Engine::Me); diff --git a/src/video_core/amdgpu/pm4_cmds.h b/src/video_core/amdgpu/pm4_cmds.h index 311f4d4d0..e92ba17fa 100644 --- a/src/video_core/amdgpu/pm4_cmds.h +++ b/src/video_core/amdgpu/pm4_cmds.h @@ -884,4 +884,65 @@ struct PM4CmdDrawIndexIndirectMulti { u32 draw_initiator; ///< Draw Initiator Register }; +struct PM4CmdMemSemaphore { + enum class ClientCode : u32 { + CommandProcessor = 0u, + CommandBuffer = 1u, + DataBuffer = 2u, + }; + enum class Select : u32 { + SignalSemaphore = 6u, + WaitSemaphore = 7u, + }; + enum class SignalType : u32 { + Increment = 0u, + Write = 1u, + }; + + PM4Type3Header header; ///< header + union { + u32 dw1; + BitField<3, 29, u32> addr_lo; ///< Semaphore address bits [31:3] + }; + union { + u32 dw2; + BitField<0, 8, u32> addr_hi; ///< Semaphore address bits [39:32] + BitField<16, 1, u32> use_mailbox; ///< Enables waiting until mailbox is written to + BitField<20, 1, SignalType> signal_type; ///< Indicates the type of signal sent + BitField<24, 2, ClientCode> client_code; + BitField<29, 3, Select> sem_sel; ///< Indicates whether to do a signal or wait operation + }; + + template + [[nodiscard]] T Address() const { + return std::bit_cast(u64(addr_lo) << 3 | (u64(addr_hi) << 32)); + } + + [[nodiscard]] bool IsSignaling() const { + return sem_sel == Select::SignalSemaphore; + } + + [[nodiscard]] bool Signaled() const { + return *Address() > 0; + } + + void Decrement() const { + *Address() -= 1; + } + + void Signal() const { + auto* ptr = Address(); + switch (signal_type) { + case SignalType::Increment: + *ptr += 1; + break; + case SignalType::Write: + *ptr = 1; + break; + default: + UNREACHABLE_MSG("Unknown signal type {}", static_cast(signal_type.Value())); + } + } +}; + } // namespace AmdGpu From f1bc3b4f3dc492f4c067693a97e5932c8be38491 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sat, 25 Jan 2025 14:59:18 -0800 Subject: [PATCH 71/99] shader_recompiler: Add another constant propagation pass near the end. (#2231) --- src/shader_recompiler/recompiler.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/shader_recompiler/recompiler.cpp b/src/shader_recompiler/recompiler.cpp index bb027a11e..01518ab8f 100644 --- a/src/shader_recompiler/recompiler.cpp +++ b/src/shader_recompiler/recompiler.cpp @@ -90,6 +90,7 @@ IR::Program TranslateProgram(std::span code, Pools& pools, Info& info Shader::Optimization::ResourceTrackingPass(program); Shader::Optimization::IdentityRemovalPass(program.blocks); Shader::Optimization::DeadCodeEliminationPass(program); + Shader::Optimization::ConstantPropagationPass(program.post_order_blocks); Shader::Optimization::CollectShaderInfoPass(program); Shader::Optimization::SharedMemoryBarrierPass(program, profile); From 3960283a67af70fbaf2a64a1ac97f695acf47a16 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sun, 26 Jan 2025 01:00:22 -0800 Subject: [PATCH 72/99] hotfix: Fix missing embedded PS shader address bits. If the emulator code is above a 40-bit address, the embedded shaders need to use address-hi to work. Embedded VS shader already supplies it, PS shader should as well. --- src/core/libraries/gnmdriver/gnmdriver.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/libraries/gnmdriver/gnmdriver.cpp b/src/core/libraries/gnmdriver/gnmdriver.cpp index fdc3a1acd..06124167c 100644 --- a/src/core/libraries/gnmdriver/gnmdriver.cpp +++ b/src/core/libraries/gnmdriver/gnmdriver.cpp @@ -1366,7 +1366,7 @@ s32 PS4_SYSV_ABI sceGnmSetEmbeddedPsShader(u32* cmdbuf, u32 size, u32 shader_id, // pointer to a stack memory, so the check will likely fail. To workaround it we will // repeat set shader functionality here as it is trivial. cmdbuf = PM4CmdSetData::SetShReg(cmdbuf, 8u, ps_regs[0], - 0u); // SPI_SHADER_PGM_LO_PS/SPI_SHADER_PGM_HI_PS + ps_regs[1]); // SPI_SHADER_PGM_LO_PS/SPI_SHADER_PGM_HI_PS cmdbuf = PM4CmdSetData::SetShReg(cmdbuf, 10u, ps_regs[2], ps_regs[3]); // SPI_SHADER_PGM_RSRC1_PS/SPI_SHADER_PGM_RSRC2_PS cmdbuf = PM4CmdSetData::SetContextReg(cmdbuf, 0x1c4u, ps_regs[4], From 461148c22706ea35c8ae4985f21d695e46be01ff Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sun, 26 Jan 2025 04:32:14 -0800 Subject: [PATCH 73/99] qt: Prevent interacting with empty grid cells. (#2243) --- src/qt_gui/game_grid_frame.cpp | 3 ++- src/qt_gui/gui_context_menus.h | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/qt_gui/game_grid_frame.cpp b/src/qt_gui/game_grid_frame.cpp index 2ebb09e5d..d719ac878 100644 --- a/src/qt_gui/game_grid_frame.cpp +++ b/src/qt_gui/game_grid_frame.cpp @@ -38,17 +38,18 @@ GameGridFrame::GameGridFrame(std::shared_ptr game_info_get, void GameGridFrame::onCurrentCellChanged(int currentRow, int currentColumn, int previousRow, int previousColumn) { - cellClicked = true; crtRow = currentRow; crtColumn = currentColumn; columnCnt = this->columnCount(); auto itemID = (crtRow * columnCnt) + currentColumn; if (itemID > m_game_info->m_games.count() - 1) { + cellClicked = false; validCellSelected = false; BackgroundMusicPlayer::getInstance().stopMusic(); return; } + cellClicked = true; validCellSelected = true; SetGridBackgroundImage(crtRow, crtColumn); auto snd0Path = QString::fromStdString(m_game_info->m_games[itemID].snd0_path.string()); diff --git a/src/qt_gui/gui_context_menus.h b/src/qt_gui/gui_context_menus.h index 0e8675c0c..72affeca7 100644 --- a/src/qt_gui/gui_context_menus.h +++ b/src/qt_gui/gui_context_menus.h @@ -41,8 +41,8 @@ public: itemID = widget->currentRow() * widget->columnCount() + widget->currentColumn(); } - // Do not show the menu if an item is selected - if (itemID == -1) { + // Do not show the menu if no item is selected + if (itemID < 0 || itemID >= m_games.size()) { return; } From 46b5437fdfea7e7b3add555d62540766daa4534d Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sun, 26 Jan 2025 08:01:15 -0800 Subject: [PATCH 74/99] emulator: Use correct game folder mount when opening update eboot directly. (#2244) --- src/emulator.cpp | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/src/emulator.cpp b/src/emulator.cpp index e77c2b87f..97215c06f 100644 --- a/src/emulator.cpp +++ b/src/emulator.cpp @@ -100,9 +100,21 @@ Emulator::~Emulator() { } void Emulator::Run(const std::filesystem::path& file, const std::vector args) { + const auto eboot_name = file.filename().string(); + auto game_folder = file.parent_path(); + if (const auto game_folder_name = game_folder.filename().string(); + game_folder_name.ends_with("-UPDATE")) { + // If an executable was launched from a separate update directory, + // use the base game directory as the game folder. + const auto base_name = game_folder_name.substr(0, game_folder_name.size() - 7); + const auto base_path = game_folder.parent_path() / base_name; + if (std::filesystem::is_directory(base_path)) { + game_folder = base_path; + } + } + // Applications expect to be run from /app0 so mount the file's parent path as app0. auto* mnt = Common::Singleton::Instance(); - const auto game_folder = file.parent_path(); mnt->Mount(game_folder, "/app0"); // Certain games may use /hostapp as well such as CUSA001100 mnt->Mount(game_folder, "/hostapp"); @@ -223,7 +235,7 @@ void Emulator::Run(const std::filesystem::path& file, const std::vectorGetHLESymbols()); // Load the module with the linker - const auto eboot_path = mnt->GetHostPath("/app0/" + file.filename().string()); + const auto eboot_path = mnt->GetHostPath("/app0/" + eboot_name); linker->LoadModule(eboot_path); // check if we have system modules to load From 7d1631f9f43f3b781a20dd91d7ebc0980b55b8ee Mon Sep 17 00:00:00 2001 From: Ian Carpenter Date: Sun, 26 Jan 2025 18:46:59 -0500 Subject: [PATCH 75/99] memory_patcher: Remove hardcoded repositories when loading patches (#2241) --- src/common/memory_patcher.cpp | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/src/common/memory_patcher.cpp b/src/common/memory_patcher.cpp index 6b79edb9f..f81a0ed83 100644 --- a/src/common/memory_patcher.cpp +++ b/src/common/memory_patcher.cpp @@ -7,6 +7,7 @@ #include #include #ifdef ENABLE_QT_GUI +#include #include #include #include @@ -189,14 +190,16 @@ void OnGameLoaded() { // We use the QT headers for the xml and json parsing, this define is only true on QT builds QString patchDir; Common::FS::PathToQString(patchDir, Common::FS::GetUserPath(Common::FS::PathType::PatchesDir)); - QString repositories[] = {"GoldHEN", "shadPS4"}; + QDir dir(patchDir); + QStringList folders = dir.entryList(QDir::Dirs | QDir::NoDotAndDotDot); - for (const QString& repository : repositories) { - QString filesJsonPath = patchDir + "/" + repository + "/files.json"; + for (const QString& folder : folders) { + QString filesJsonPath = patchDir + "/" + folder + "/files.json"; QFile jsonFile(filesJsonPath); if (!jsonFile.open(QIODevice::ReadOnly)) { - LOG_ERROR(Loader, "Unable to open files.json for reading."); + LOG_ERROR(Loader, "Unable to open files.json for reading in repository {}", + folder.toStdString()); continue; } @@ -220,11 +223,12 @@ void OnGameLoaded() { } if (selectedFileName.isEmpty()) { - LOG_ERROR(Loader, "No patch file found for the current serial."); + LOG_ERROR(Loader, "No patch file found for the current serial in repository {}", + folder.toStdString()); continue; } - QString filePath = patchDir + "/" + repository + "/" + selectedFileName; + QString filePath = patchDir + "/" + folder + "/" + selectedFileName; QFile file(filePath); if (!file.open(QIODevice::ReadOnly | QIODevice::Text)) { LOG_ERROR(Loader, "Unable to open the file for reading."); From 6f04ea18e4f3d87e9a89f0fefcc1c8c722a87de6 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Sun, 26 Jan 2025 19:28:58 -0800 Subject: [PATCH 76/99] externals: Update MoltenVK (#2249) Fixes broken vertex binding dynamic stride when used with tessellation. --- externals/MoltenVK/MoltenVK | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/externals/MoltenVK/MoltenVK b/externals/MoltenVK/MoltenVK index 2473ce6f0..6fa077fb8 160000 --- a/externals/MoltenVK/MoltenVK +++ b/externals/MoltenVK/MoltenVK @@ -1 +1 @@ -Subproject commit 2473ce6f0ab7d5d8a49aa91b2e37f3447a939f18 +Subproject commit 6fa077fb8ed8dac4e4cd66b6b1ebd7b4d955a754 From 191e64bfa11e45992e869e7a9df787d6fbe5038b Mon Sep 17 00:00:00 2001 From: Vladislav Mikhalin Date: Mon, 27 Jan 2025 11:17:23 +0300 Subject: [PATCH 77/99] renderer: respect zmin/zmax even if clipping is disabled (#2250) --- src/video_core/renderer_vulkan/vk_rasterizer.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/video_core/renderer_vulkan/vk_rasterizer.cpp b/src/video_core/renderer_vulkan/vk_rasterizer.cpp index 88b510eca..7a0652ed7 100644 --- a/src/video_core/renderer_vulkan/vk_rasterizer.cpp +++ b/src/video_core/renderer_vulkan/vk_rasterizer.cpp @@ -1172,6 +1172,8 @@ void Rasterizer::UpdateViewportScissorState(const GraphicsPipeline& pipeline) { continue; } + const auto zoffset = vp_ctl.zoffset_enable ? vp.zoffset : 0.f; + const auto zscale = vp_ctl.zscale_enable ? vp.zscale : 1.f; if (pipeline.IsClipDisabled()) { // In case if clipping is disabled we patch the shader to convert vertex position // from screen space coordinates to NDC by defining a render space as full hardware @@ -1181,16 +1183,14 @@ void Rasterizer::UpdateViewportScissorState(const GraphicsPipeline& pipeline) { .y = 0.f, .width = float(std::min(instance.GetMaxViewportWidth(), 16_KB)), .height = float(std::min(instance.GetMaxViewportHeight(), 16_KB)), - .minDepth = 0.0, - .maxDepth = 1.0, + .minDepth = zoffset - zscale * reduce_z, + .maxDepth = zscale + zoffset, }); } else { const auto xoffset = vp_ctl.xoffset_enable ? vp.xoffset : 0.f; const auto xscale = vp_ctl.xscale_enable ? vp.xscale : 1.f; const auto yoffset = vp_ctl.yoffset_enable ? vp.yoffset : 0.f; const auto yscale = vp_ctl.yscale_enable ? vp.yscale : 1.f; - const auto zoffset = vp_ctl.zoffset_enable ? vp.zoffset : 0.f; - const auto zscale = vp_ctl.zscale_enable ? vp.zscale : 1.f; viewports.push_back({ .x = xoffset - xscale, .y = yoffset - yscale, From 665261efc574562aad240466a9eed8b05b6b9a50 Mon Sep 17 00:00:00 2001 From: F1219R <109141852+F1219R@users.noreply.github.com> Date: Mon, 27 Jan 2025 16:39:27 +0100 Subject: [PATCH 78/99] Update sq translation (#2251) --- src/qt_gui/translations/sq.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/qt_gui/translations/sq.ts b/src/qt_gui/translations/sq.ts index 2f88b4390..15c18d2f6 100644 --- a/src/qt_gui/translations/sq.ts +++ b/src/qt_gui/translations/sq.ts @@ -249,7 +249,7 @@ Open shadPS4 Folder - Open shadPS4 Folder + Hap dosjen e shadPS4 Exit @@ -542,7 +542,7 @@ Fullscreen Mode - Modaliteti i Plotë + Mënyra me ekran të plotë Enable Separate Update Folder @@ -550,7 +550,7 @@ Default tab when opening settings - Skeda e parazgjedhur kur hapni cilësimet + Skeda e parazgjedhur kur hapen cilësimet Show Game Size In List @@ -594,7 +594,7 @@ Open Log Location - Hap vendndodhjen e regjistrit + Hap vendndodhjen e Ditarit Input @@ -630,11 +630,11 @@ Gui - Ndërfaqe + Ndërfaqja User - Përdorues + Përdoruesi Graphics Device @@ -822,7 +822,7 @@ GUIMusicGroupBox - Luaj muzikën e titullit:\nNëse një lojë e mbështet, aktivizohet luajtja e muzikës të veçantë kur të zgjidhësh lojën në GUI. + Luaj muzikën e titullit:\nNëse një lojë e mbështet, aktivizohet luajtja e muzikës të veçantë kur të zgjidhësh lojën në ndërfaqe. disableTrophycheckBox From 2837d848eddf2c4b2b361626c220aa415f8b241c Mon Sep 17 00:00:00 2001 From: panzone91 <150828896+panzone91@users.noreply.github.com> Date: Mon, 27 Jan 2025 21:40:58 +0100 Subject: [PATCH 79/99] linker: handle relocation for exported modules (#2247) --- src/core/linker.h | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/core/linker.h b/src/core/linker.h index 00da3a08c..357b39664 100644 --- a/src/core/linker.h +++ b/src/core/linker.h @@ -109,10 +109,13 @@ public: void RelocateAnyImports(Module* m) { Relocate(m); - for (auto& module : m_modules) { - const auto imports = module->GetImportModules(); - if (std::ranges::contains(imports, m->name, &ModuleInfo::name)) { - Relocate(module.get()); + const auto exports = m->GetExportModules(); + for (auto& export_mod : exports) { + for (auto& module : m_modules) { + const auto imports = module->GetImportModules(); + if (std::ranges::contains(imports, export_mod.name, &ModuleInfo::name)) { + Relocate(module.get()); + } } } } From d2127b38deace732f0c41b6cc1881e21f4ed268b Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Tue, 28 Jan 2025 00:12:48 -0800 Subject: [PATCH 80/99] vk_rasterizer: Keep viewport depth offset even without native depth clip control. (#2257) --- src/video_core/renderer_vulkan/vk_rasterizer.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/video_core/renderer_vulkan/vk_rasterizer.cpp b/src/video_core/renderer_vulkan/vk_rasterizer.cpp index 7a0652ed7..7c77f2519 100644 --- a/src/video_core/renderer_vulkan/vk_rasterizer.cpp +++ b/src/video_core/renderer_vulkan/vk_rasterizer.cpp @@ -1155,10 +1155,7 @@ void Rasterizer::UpdateViewportScissorState(const GraphicsPipeline& pipeline) { const auto& vp_ctl = regs.viewport_control; const float reduce_z = - instance.IsDepthClipControlSupported() && - regs.clipper_control.clip_space == AmdGpu::Liverpool::ClipSpace::MinusWToW - ? 1.0f - : 0.0f; + regs.clipper_control.clip_space == AmdGpu::Liverpool::ClipSpace::MinusWToW ? 1.0f : 0.0f; if (regs.polygon_control.enable_window_offset) { LOG_ERROR(Render_Vulkan, From 8379922f8ab1209d25b4cbec14303401aa75eec9 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Tue, 28 Jan 2025 02:31:26 -0800 Subject: [PATCH 81/99] hotfix: Reduce requested videodec memory block sizes. This really needs a more accurate implementation, but for the stub lowering the value helps games that run out of memory space if it is too large. --- src/core/libraries/videodec/videodec.cpp | 2 +- src/core/libraries/videodec/videodec2.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/libraries/videodec/videodec.cpp b/src/core/libraries/videodec/videodec.cpp index 6c9a9b8c0..79001e76f 100644 --- a/src/core/libraries/videodec/videodec.cpp +++ b/src/core/libraries/videodec/videodec.cpp @@ -9,7 +9,7 @@ namespace Libraries::Videodec { -static constexpr u64 kMinimumMemorySize = 32_MB; ///> Fake minimum memory size for querying +static constexpr u64 kMinimumMemorySize = 8_MB; ///> Fake minimum memory size for querying int PS4_SYSV_ABI sceVideodecCreateDecoder(const OrbisVideodecConfigInfo* pCfgInfoIn, const OrbisVideodecResourceInfo* pRsrcInfoIn, diff --git a/src/core/libraries/videodec/videodec2.cpp b/src/core/libraries/videodec/videodec2.cpp index 07f7a274b..be0db4ea3 100644 --- a/src/core/libraries/videodec/videodec2.cpp +++ b/src/core/libraries/videodec/videodec2.cpp @@ -10,7 +10,7 @@ namespace Libraries::Vdec2 { -static constexpr u64 kMinimumMemorySize = 32_MB; ///> Fake minimum memory size for querying +static constexpr u64 kMinimumMemorySize = 8_MB; ///> Fake minimum memory size for querying s32 PS4_SYSV_ABI sceVideodec2QueryComputeMemoryInfo(OrbisVideodec2ComputeMemoryInfo* computeMemInfo) { From 4b93b8b57460c83421d0d859e243dd05a864bdc1 Mon Sep 17 00:00:00 2001 From: Martin <67326368+Martini-141@users.noreply.github.com> Date: Tue, 28 Jan 2025 17:47:00 +0100 Subject: [PATCH 82/99] add missing translations and other corrections nb (#2253) --- src/qt_gui/translations/nb.ts | 42 +++++++++++++++++------------------ 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/src/qt_gui/translations/nb.ts b/src/qt_gui/translations/nb.ts index d6d4090df..0b7d2699a 100644 --- a/src/qt_gui/translations/nb.ts +++ b/src/qt_gui/translations/nb.ts @@ -98,7 +98,7 @@ Open Folder... - Åpne mappen... + Åpne mappe... Open Game Folder @@ -126,7 +126,7 @@ Copy All - Kopier alle + Kopier alt Delete... @@ -146,19 +146,19 @@ Compatibility... - Compatibility... + Kompatibilitet... Update database - Update database + Oppdater database View report - View report + Vis rapport Submit a report - Submit a report + Send inn en rapport Shortcut creation @@ -574,11 +574,11 @@ Trophy Key - Trophy Key + Trofénøkkel Trophy - Trophy + Trofé Logger @@ -658,7 +658,7 @@ Enable Shaders Dumping - Aktiver dumping av skyggelegger + Aktiver skyggeleggerdumping Enable NULL GPU @@ -666,7 +666,7 @@ Paths - Stier + Mapper Game Folders @@ -686,7 +686,7 @@ Enable Debug Dumping - Aktiver dumping av feilretting + Aktiver feilrettingsdumping Enable Vulkan Validation Layers @@ -718,7 +718,7 @@ GUI Settings - GUI-innstillinger + Grensesnitt-innstillinger Disable Trophy Pop-ups @@ -730,7 +730,7 @@ Update Compatibility Database On Startup - Oppdater kompatibilitets-database ved oppstart + Oppdater database ved oppstart Game Compatibility @@ -750,7 +750,7 @@ Audio Backend - Audio Backend + Lydsystem Save @@ -806,7 +806,7 @@ TrophyKey - Trophy Key:\nKey used to decrypt trophies. Must be obtained from your jailbroken console.\nMust contain only hex characters. + Trofénøkkel:\nNøkkel brukes til å dekryptere trofeer. Må hentes fra din konsoll (jailbroken).\nMå bare inneholde sekskantede tegn. logTypeGroupBox @@ -846,7 +846,7 @@ checkCompatibilityOnStartupCheckBox - Oppdater kompatibilitets-data ved oppstart:\nOppdaterer kompatibilitets-databasen automatisk når shadPS4 starter. + Oppdater database ved oppstart:\nOppdaterer kompatibilitets-databasen automatisk når shadPS4 starter. updateCompatibilityButton @@ -894,7 +894,7 @@ dumpShadersCheckBox - Aktiver dumping av skyggelegger:\nFor teknisk feilsøking lagrer skyggeleggerne fra spillet i en mappe mens de gjengis. + Aktiver skyggeleggerdumping:\nFor teknisk feilsøking lagrer skyggeleggerne fra spillet i en mappe mens de gjengis. nullGpuCheckBox @@ -914,7 +914,7 @@ debugDump - Aktiver dumping av feilsøking:\nLagrer import- og eksport-symbolene og filoverskriftsinformasjonen til det nåværende kjørende PS4-programmet i en katalog. + Aktiver feilrettingsdumping:\nLagrer import- og eksport-symbolene og filoverskriftsinformasjonen til det nåværende kjørende PS4-programmet i en katalog. vkValidationCheckBox @@ -1188,7 +1188,7 @@ Path - Sti + Adresse Play Time @@ -1232,7 +1232,7 @@ Game can be completed with playable performance and no major glitches - Spillet kan fullføres med spillbar ytelse og ingen store feil + Spillet kan fullføres med spillbar ytelse og uten store feil
@@ -1361,4 +1361,4 @@ TB - \ No newline at end of file + From 2cdd873681dd3b03d0752bda5c84412f06f4f0b8 Mon Sep 17 00:00:00 2001 From: slick-daddy <129640104+slick-daddy@users.noreply.github.com> Date: Tue, 28 Jan 2025 19:47:12 +0300 Subject: [PATCH 83/99] Update tr_TR.ts (#2255) --- src/qt_gui/translations/tr_TR.ts | 54 ++++++++++++++++---------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/src/qt_gui/translations/tr_TR.ts b/src/qt_gui/translations/tr_TR.ts index 6436278de..a2368bfee 100644 --- a/src/qt_gui/translations/tr_TR.ts +++ b/src/qt_gui/translations/tr_TR.ts @@ -546,7 +546,7 @@ Enable Separate Update Folder - Enable Separate Update Folder + Ayrı Güncelleme Klasörünü Etkinleştir Default tab when opening settings @@ -554,7 +554,7 @@ Show Game Size In List - Göster oyun boyutunu listede + Oyun Boyutunu Listede Göster Show Splash @@ -574,11 +574,11 @@ Trophy Key - Trophy Key + Kupa Anahtarı Trophy - Trophy + Kupa Logger @@ -722,7 +722,7 @@ Disable Trophy Pop-ups - Disable Trophy Pop-ups + Kupa Açılır Pencerelerini Devre Dışı Bırak Play title music @@ -730,23 +730,23 @@ Update Compatibility Database On Startup - Update Compatibility Database On Startup + Başlangıçta Uyumluluk Veritabanını Güncelle Game Compatibility - Game Compatibility + Oyun Uyumluluğu Display Compatibility Data - Display Compatibility Data + Uyumluluk Verilerini Göster Update Compatibility Database - Update Compatibility Database + Uyumluluk Veritabanını Güncelle Volume - Ses seviyesi + Ses Seviyesi Audio Backend @@ -1105,11 +1105,11 @@ The game is in version: %1 - Oyun sürümde: %1 + Oyun sürümü: %1 The downloaded patch only works on version: %1 - İndirilen yamanın sadece sürümde çalışıyor: %1 + İndirilen yama sadece şu sürümde çalışıyor: %1 You may need to update your game. @@ -1168,7 +1168,7 @@ Compatibility - Compatibility + Uyumluluk Region @@ -1196,35 +1196,35 @@ Never Played - Never Played + Hiç Oynanmadı h - h + sa m - m + dk s - s + sn Compatibility is untested - Compatibility is untested + Uyumluluk test edilmemiş Game does not initialize properly / crashes the emulator - Game does not initialize properly / crashes the emulator + Oyun düzgün bir şekilde başlatılamıyor / emülatörü çökertiyor Game boots, but only displays a blank screen - Game boots, but only displays a blank screen + Oyun başlatılabiliyor ancak yalnızca boş bir ekran gösteriyor Game displays an image but does not go past the menu - Game displays an image but does not go past the menu + Oyun bir resim gösteriyor ancak menüleri geçemiyor Game has game-breaking glitches or unplayable performance @@ -1232,7 +1232,7 @@ Game can be completed with playable performance and no major glitches - Game can be completed with playable performance and no major glitches + Oyun, oynanabilir performansla tamamlanabilir ve büyük aksaklık yok @@ -1267,7 +1267,7 @@ Your version is already up to date! - Versiyonunuz zaten güncel! + Sürümünüz zaten güncel! Update Available @@ -1279,11 +1279,11 @@ Current Version - Mevcut Versiyon + Mevcut Sürüm Latest Version - Son Versiyon + Son Sürüm Do you want to update? @@ -1335,7 +1335,7 @@ Failed to create the update script file - Güncelleme betiği dosyası oluşturulamadı + Güncelleme komut dosyası oluşturulamadı @@ -1361,4 +1361,4 @@ TB - \ No newline at end of file + From a78f8afe58a995cecdb4eb1f1e6d6e58320444f6 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Tue, 28 Jan 2025 08:48:19 -0800 Subject: [PATCH 84/99] libraries: Implement libSceZlib. (#2256) * libraries: add zlib hle skeleton/stub * libraries: Implement libSceZlib. * zlib: Make variables static. --------- Co-authored-by: Nenkai --- CMakeLists.txt | 6 + src/common/logging/filter.cpp | 1 + src/common/logging/types.h | 1 + src/core/libraries/libs.cpp | 2 + src/core/libraries/zlib/zlib.cpp | 183 +++++++++++++++++++++++++++ src/core/libraries/zlib/zlib_error.h | 18 +++ src/core/libraries/zlib/zlib_sce.h | 21 +++ 7 files changed, 232 insertions(+) create mode 100644 src/core/libraries/zlib/zlib.cpp create mode 100644 src/core/libraries/zlib/zlib_error.h create mode 100644 src/core/libraries/zlib/zlib_sce.h diff --git a/CMakeLists.txt b/CMakeLists.txt index 4c9dad307..78e3c7997 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -440,6 +440,11 @@ set(NP_LIBS src/core/libraries/np_common/np_common.cpp src/core/libraries/np_party/np_party.h ) +set(ZLIB_LIB src/core/libraries/zlib/zlib.cpp + src/core/libraries/zlib/zlib_sce.h + src/core/libraries/zlib/zlib_error.h +) + set(MISC_LIBS src/core/libraries/screenshot/screenshot.cpp src/core/libraries/screenshot/screenshot.h src/core/libraries/move/move.cpp @@ -612,6 +617,7 @@ set(CORE src/core/aerolib/stubs.cpp ${PLAYGO_LIB} ${RANDOM_LIB} ${USBD_LIB} + ${ZLIB_LIB} ${MISC_LIBS} ${IME_LIB} ${FIBER_LIB} diff --git a/src/common/logging/filter.cpp b/src/common/logging/filter.cpp index f1d3a9499..dd708c528 100644 --- a/src/common/logging/filter.cpp +++ b/src/common/logging/filter.cpp @@ -133,6 +133,7 @@ bool ParseFilterRule(Filter& instance, Iterator begin, Iterator end) { SUB(Lib, Mouse) \ SUB(Lib, WebBrowserDialog) \ SUB(Lib, NpParty) \ + SUB(Lib, Zlib) \ CLS(Frontend) \ CLS(Render) \ SUB(Render, Vulkan) \ diff --git a/src/common/logging/types.h b/src/common/logging/types.h index d5530312c..54f8cdd0b 100644 --- a/src/common/logging/types.h +++ b/src/common/logging/types.h @@ -100,6 +100,7 @@ enum class Class : u8 { Lib_Mouse, ///< The LibSceMouse implementation Lib_WebBrowserDialog, ///< The LibSceWebBrowserDialog implementation Lib_NpParty, ///< The LibSceNpParty implementation + Lib_Zlib, ///< The LibSceZlib implementation. Frontend, ///< Emulator UI Render, ///< Video Core Render_Vulkan, ///< Vulkan backend diff --git a/src/core/libraries/libs.cpp b/src/core/libraries/libs.cpp index e09de1cee..8cf286d13 100644 --- a/src/core/libraries/libs.cpp +++ b/src/core/libraries/libs.cpp @@ -54,6 +54,7 @@ #include "core/libraries/videodec/videodec2.h" #include "core/libraries/videoout/video_out.h" #include "core/libraries/web_browser_dialog/webbrowserdialog.h" +#include "core/libraries/zlib/zlib_sce.h" #include "fiber/fiber.h" #include "jpeg/jpegenc.h" @@ -111,6 +112,7 @@ void InitHLELibs(Core::Loader::SymbolsResolver* sym) { Libraries::Mouse::RegisterlibSceMouse(sym); Libraries::WebBrowserDialog::RegisterlibSceWebBrowserDialog(sym); Libraries::NpParty::RegisterlibSceNpParty(sym); + Libraries::Zlib::RegisterlibSceZlib(sym); } } // namespace Libraries diff --git a/src/core/libraries/zlib/zlib.cpp b/src/core/libraries/zlib/zlib.cpp new file mode 100644 index 000000000..899cb5bf6 --- /dev/null +++ b/src/core/libraries/zlib/zlib.cpp @@ -0,0 +1,183 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#include +#include +#include +#include +#include +#include + +#include "common/logging/log.h" +#include "common/thread.h" +#include "core/libraries/kernel/threads.h" +#include "core/libraries/libs.h" +#include "core/libraries/zlib/zlib_error.h" +#include "core/libraries/zlib/zlib_sce.h" + +namespace Libraries::Zlib { + +struct InflateTask { + u64 request_id; + const void* src; + u32 src_length; + void* dst; + u32 dst_length; +}; + +struct InflateResult { + u32 length; + s32 status; +}; + +static Kernel::Thread task_thread; + +static std::mutex mutex; +static std::queue task_queue; +static std::condition_variable_any task_queue_cv; +static std::queue done_queue; +static std::condition_variable_any done_queue_cv; +static std::unordered_map results; +static u64 next_request_id; + +void ZlibTaskThread(const std::stop_token& stop) { + Common::SetCurrentThreadName("shadPS4:ZlibTaskThread"); + + while (!stop.stop_requested()) { + InflateTask task; + { + // Lock and pop from the task queue, unless stop has been requested. + std::unique_lock lock(mutex); + if (!task_queue_cv.wait(lock, stop, [&] { return !task_queue.empty(); })) { + break; + } + task = task_queue.back(); + task_queue.pop(); + } + + uLongf decompressed_length = task.dst_length; + const auto ret = uncompress(static_cast(task.dst), &decompressed_length, + static_cast(task.src), task.src_length); + + { + // Lock, insert the new result, and push the finished request ID to the done queue. + std::unique_lock lock(mutex); + results[task.request_id] = InflateResult{ + .length = static_cast(decompressed_length), + .status = ret == Z_BUF_ERROR ? ORBIS_ZLIB_ERROR_NOSPACE + : ret == Z_OK ? ORBIS_OK + : ORBIS_ZLIB_ERROR_FATAL, + }; + done_queue.push(task.request_id); + } + done_queue_cv.notify_one(); + } +} + +s32 PS4_SYSV_ABI sceZlibInitialize(const void* buffer, u32 length) { + LOG_INFO(Lib_Zlib, "called"); + if (task_thread.Joinable()) { + return ORBIS_ZLIB_ERROR_ALREADY_INITIALIZED; + } + + // Initialize with empty task data + task_queue = std::queue(); + done_queue = std::queue(); + results.clear(); + next_request_id = 1; + + task_thread.Run([](const std::stop_token& stop) { ZlibTaskThread(stop); }); + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceZlibInflate(const void* src, u32 src_len, void* dst, u32 dst_len, + u64* request_id) { + LOG_DEBUG(Lib_Zlib, "(STUBBED) called"); + if (!task_thread.Joinable()) { + return ORBIS_ZLIB_ERROR_NOT_INITIALIZED; + } + if (!src || !src_len || !dst || !dst_len || !request_id || dst_len > 64_KB || + dst_len % 2_KB != 0) { + return ORBIS_ZLIB_ERROR_INVALID; + } + + { + std::unique_lock lock(mutex); + *request_id = next_request_id++; + task_queue.emplace(InflateTask{ + .request_id = *request_id, + .src = src, + .src_length = src_len, + .dst = dst, + .dst_length = dst_len, + }); + task_queue_cv.notify_one(); + } + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceZlibWaitForDone(u64* request_id, const u32* timeout) { + LOG_DEBUG(Lib_Zlib, "(STUBBED) called"); + if (!task_thread.Joinable()) { + return ORBIS_ZLIB_ERROR_NOT_INITIALIZED; + } + if (!request_id) { + return ORBIS_ZLIB_ERROR_INVALID; + } + + { + // Pop from the done queue, unless the timeout is reached. + std::unique_lock lock(mutex); + const auto pred = [] { return !done_queue.empty(); }; + if (timeout) { + if (!done_queue_cv.wait_for(lock, std::chrono::milliseconds(*timeout), pred)) { + return ORBIS_ZLIB_ERROR_TIMEDOUT; + } + } else { + done_queue_cv.wait(lock, pred); + } + *request_id = done_queue.back(); + done_queue.pop(); + } + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceZlibGetResult(const u64 request_id, u32* dst_length, s32* status) { + LOG_DEBUG(Lib_Zlib, "(STUBBED) called"); + if (!task_thread.Joinable()) { + return ORBIS_ZLIB_ERROR_NOT_INITIALIZED; + } + if (!dst_length || !status) { + return ORBIS_ZLIB_ERROR_INVALID; + } + + { + std::unique_lock lock(mutex); + if (!results.contains(request_id)) { + return ORBIS_ZLIB_ERROR_NOT_FOUND; + } + const auto result = results[request_id]; + *dst_length = result.length; + *status = result.status; + } + return ORBIS_OK; +} + +s32 PS4_SYSV_ABI sceZlibFinalize() { + LOG_INFO(Lib_Zlib, "called"); + if (!task_thread.Joinable()) { + return ORBIS_ZLIB_ERROR_NOT_INITIALIZED; + } + task_thread.Stop(); + return ORBIS_OK; +} + +void RegisterlibSceZlib(Core::Loader::SymbolsResolver* sym) { + LIB_FUNCTION("m1YErdIXCp4", "libSceZlib", 1, "libSceZlib", 1, 1, sceZlibInitialize); + LIB_FUNCTION("6na+Sa-B83w", "libSceZlib", 1, "libSceZlib", 1, 1, sceZlibFinalize); + LIB_FUNCTION("TLar1HULv1Q", "libSceZlib", 1, "libSceZlib", 1, 1, sceZlibInflate); + LIB_FUNCTION("uB8VlDD4e0s", "libSceZlib", 1, "libSceZlib", 1, 1, sceZlibWaitForDone); + LIB_FUNCTION("2eDcGHC0YaM", "libSceZlib", 1, "libSceZlib", 1, 1, sceZlibGetResult); +}; + +} // namespace Libraries::Zlib diff --git a/src/core/libraries/zlib/zlib_error.h b/src/core/libraries/zlib/zlib_error.h new file mode 100644 index 000000000..59574f0b2 --- /dev/null +++ b/src/core/libraries/zlib/zlib_error.h @@ -0,0 +1,18 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#include "core/libraries/error_codes.h" + +// Zlib library +constexpr int ORBIS_ZLIB_ERROR_NOT_FOUND = 0x81120002; +constexpr int ORBIS_ZLIB_ERROR_BUSY = 0x8112000B; +constexpr int ORBIS_ZLIB_ERROR_FAULT = 0x8112000E; +constexpr int ORBIS_ZLIB_ERROR_INVALID = 0x81120016; +constexpr int ORBIS_ZLIB_ERROR_NOSPACE = 0x8112001C; +constexpr int ORBIS_ZLIB_ERROR_NOT_SUPPORTED = 0x81120025; +constexpr int ORBIS_ZLIB_ERROR_TIMEDOUT = 0x81120027; +constexpr int ORBIS_ZLIB_ERROR_NOT_INITIALIZED = 0x81120032; +constexpr int ORBIS_ZLIB_ERROR_ALREADY_INITIALIZED = 0x81120033; +constexpr int ORBIS_ZLIB_ERROR_FATAL = 0x811200FF; diff --git a/src/core/libraries/zlib/zlib_sce.h b/src/core/libraries/zlib/zlib_sce.h new file mode 100644 index 000000000..6f8cf9468 --- /dev/null +++ b/src/core/libraries/zlib/zlib_sce.h @@ -0,0 +1,21 @@ +// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project +// SPDX-License-Identifier: GPL-2.0-or-later + +#pragma once + +#include "common/types.h" + +namespace Core::Loader { +class SymbolsResolver; +} +namespace Libraries::Zlib { + +s32 PS4_SYSV_ABI sceZlibInitialize(const void* buffer, u32 length); +s32 PS4_SYSV_ABI sceZlibInflate(const void* src, u32 src_len, void* dst, u32 dst_len, + u64* request_id); +s32 PS4_SYSV_ABI sceZlibWaitForDone(u64* request_id, const u32* timeout); +s32 PS4_SYSV_ABI sceZlibGetResult(u64 request_id, u32* dst_length, s32* status); +s32 PS4_SYSV_ABI sceZlibFinalize(); + +void RegisterlibSceZlib(Core::Loader::SymbolsResolver* sym); +} // namespace Libraries::Zlib \ No newline at end of file From 0575853be18d8f0504482b4a5a407fb14a23d492 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Tue, 28 Jan 2025 17:56:05 -0800 Subject: [PATCH 85/99] externals: Update MoltenVK. (#2264) Adds support for VK_EXT_depth_clip_control --- externals/MoltenVK/MoltenVK | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/externals/MoltenVK/MoltenVK b/externals/MoltenVK/MoltenVK index 6fa077fb8..aba997657 160000 --- a/externals/MoltenVK/MoltenVK +++ b/externals/MoltenVK/MoltenVK @@ -1 +1 @@ -Subproject commit 6fa077fb8ed8dac4e4cd66b6b1ebd7b4d955a754 +Subproject commit aba997657b94d6de1794ebad36ce5634341252c7 From 78a0a755c5f2ff06c340ec0dc3431fc247aaa3e4 Mon Sep 17 00:00:00 2001 From: ElBread3 <92335081+ElBread3@users.noreply.github.com> Date: Tue, 28 Jan 2025 21:14:47 -0600 Subject: [PATCH 86/99] qt_gui: Some game install features and fixes (#2261) * open update folder + delete save folder + bulk install checkbox * delete pkg on install checkbox + use game icon for finish window --- src/qt_gui/gui_context_menus.h | 45 ++++++++++++++++++++++++++++--- src/qt_gui/install_dir_select.cpp | 24 ++++++++++++++--- src/qt_gui/install_dir_select.h | 12 +++++++++ src/qt_gui/main_window.cpp | 26 +++++++++++++++--- src/qt_gui/main_window.h | 4 +++ 5 files changed, 101 insertions(+), 10 deletions(-) diff --git a/src/qt_gui/gui_context_menus.h b/src/qt_gui/gui_context_menus.h index 72affeca7..bdc2aec0c 100644 --- a/src/qt_gui/gui_context_menus.h +++ b/src/qt_gui/gui_context_menus.h @@ -52,10 +52,12 @@ public: // "Open Folder..." submenu QMenu* openFolderMenu = new QMenu(tr("Open Folder..."), widget); QAction* openGameFolder = new QAction(tr("Open Game Folder"), widget); + QAction* openUpdateFolder = new QAction(tr("Open Update Folder"), widget); QAction* openSaveDataFolder = new QAction(tr("Open Save Data Folder"), widget); QAction* openLogFolder = new QAction(tr("Open Log Folder"), widget); openFolderMenu->addAction(openGameFolder); + openFolderMenu->addAction(openUpdateFolder); openFolderMenu->addAction(openSaveDataFolder); openFolderMenu->addAction(openLogFolder); @@ -87,10 +89,12 @@ public: QMenu* deleteMenu = new QMenu(tr("Delete..."), widget); QAction* deleteGame = new QAction(tr("Delete Game"), widget); QAction* deleteUpdate = new QAction(tr("Delete Update"), widget); + QAction* deleteSaveData = new QAction(tr("Delete Save Data"), widget); QAction* deleteDLC = new QAction(tr("Delete DLC"), widget); deleteMenu->addAction(deleteGame); deleteMenu->addAction(deleteUpdate); + deleteMenu->addAction(deleteSaveData); deleteMenu->addAction(deleteDLC); menu.addMenu(deleteMenu); @@ -122,6 +126,18 @@ public: QDesktopServices::openUrl(QUrl::fromLocalFile(folderPath)); } + if (selected == openUpdateFolder) { + QString open_update_path; + Common::FS::PathToQString(open_update_path, m_games[itemID].path); + open_update_path += "-UPDATE"; + if (!std::filesystem::exists(Common::FS::PathFromQString(open_update_path))) { + QMessageBox::critical(nullptr, tr("Error"), + QString(tr("This game has no update folder to open!"))); + } else { + QDesktopServices::openUrl(QUrl::fromLocalFile(open_update_path)); + } + } + if (selected == openSaveDataFolder) { QString userPath; Common::FS::PathToQString(userPath, @@ -143,7 +159,7 @@ public: PSF psf; std::filesystem::path game_folder_path = m_games[itemID].path; std::filesystem::path game_update_path = game_folder_path; - game_update_path += "UPDATE"; + game_update_path += "-UPDATE"; if (std::filesystem::exists(game_update_path)) { game_folder_path = game_update_path; } @@ -238,6 +254,11 @@ public: QString trophyPath, gameTrpPath; Common::FS::PathToQString(trophyPath, m_games[itemID].serial); Common::FS::PathToQString(gameTrpPath, m_games[itemID].path); + auto game_update_path = Common::FS::PathFromQString(gameTrpPath); + game_update_path += "-UPDATE"; + if (std::filesystem::exists(game_update_path)) { + Common::FS::PathToQString(gameTrpPath, game_update_path); + } TrophyViewer* trophyViewer = new TrophyViewer(trophyPath, gameTrpPath); trophyViewer->show(); connect(widget->parent(), &QWidget::destroyed, trophyViewer, @@ -335,14 +356,18 @@ public: clipboard->setText(combinedText); } - if (selected == deleteGame || selected == deleteUpdate || selected == deleteDLC) { + if (selected == deleteGame || selected == deleteUpdate || selected == deleteDLC || + selected == deleteSaveData) { bool error = false; - QString folder_path, game_update_path, dlc_path; + QString folder_path, game_update_path, dlc_path, save_data_path; Common::FS::PathToQString(folder_path, m_games[itemID].path); game_update_path = folder_path + "-UPDATE"; Common::FS::PathToQString( dlc_path, Config::getAddonInstallDir() / Common::FS::PathFromQString(folder_path).parent_path().filename()); + Common::FS::PathToQString(save_data_path, + Common::FS::GetUserPath(Common::FS::PathType::UserDir) / + "savedata/1" / m_games[itemID].serial); QString message_type = tr("Game"); if (selected == deleteUpdate) { @@ -363,6 +388,15 @@ public: folder_path = dlc_path; message_type = tr("DLC"); } + } else if (selected == deleteSaveData) { + if (!std::filesystem::exists(Common::FS::PathFromQString(save_data_path))) { + QMessageBox::critical(nullptr, tr("Error"), + QString(tr("This game has no save data to delete!"))); + error = true; + } else { + folder_path = save_data_path; + message_type = tr("Save Data"); + } } if (!error) { QString gameName = QString::fromStdString(m_games[itemID].name); @@ -374,7 +408,10 @@ public: QMessageBox::Yes | QMessageBox::No); if (reply == QMessageBox::Yes) { dir.removeRecursively(); - widget->removeRow(itemID); + if (selected == deleteGame) { + widget->removeRow(itemID); + m_games.removeAt(itemID); + } } } } diff --git a/src/qt_gui/install_dir_select.cpp b/src/qt_gui/install_dir_select.cpp index e0951b123..e90a10ee6 100644 --- a/src/qt_gui/install_dir_select.cpp +++ b/src/qt_gui/install_dir_select.cpp @@ -1,6 +1,7 @@ // SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project // SPDX-License-Identifier: GPL-2.0-or-later +#include #include #include #include @@ -15,10 +16,11 @@ #include "install_dir_select.h" InstallDirSelect::InstallDirSelect() : selected_dir() { - selected_dir = Config::getGameInstallDirs().empty() ? "" : Config::getGameInstallDirs().front(); + auto install_dirs = Config::getGameInstallDirs(); + selected_dir = install_dirs.empty() ? "" : install_dirs.front(); - if (!Config::getGameInstallDirs().empty() && Config::getGameInstallDirs().size() == 1) { - reject(); + if (!install_dirs.empty() && install_dirs.size() == 1) { + accept(); } auto layout = new QVBoxLayout(this); @@ -53,6 +55,14 @@ QWidget* InstallDirSelect::SetupInstallDirList() { vlayout->addWidget(m_path_list); + auto checkbox = new QCheckBox(tr("Install All Queued to Selected Folder")); + connect(checkbox, &QCheckBox::toggled, this, &InstallDirSelect::setUseForAllQueued); + vlayout->addWidget(checkbox); + + auto checkbox2 = new QCheckBox(tr("Delete PKG File on Install")); + connect(checkbox2, &QCheckBox::toggled, this, &InstallDirSelect::setDeleteFileOnInstall); + vlayout->addWidget(checkbox2); + group->setLayout(vlayout); return group; } @@ -66,6 +76,14 @@ void InstallDirSelect::setSelectedDirectory(QListWidgetItem* item) { } } +void InstallDirSelect::setUseForAllQueued(bool enabled) { + use_for_all_queued = enabled; +} + +void InstallDirSelect::setDeleteFileOnInstall(bool enabled) { + delete_file_on_install = enabled; +} + QWidget* InstallDirSelect::SetupDialogActions() { auto actions = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel); diff --git a/src/qt_gui/install_dir_select.h b/src/qt_gui/install_dir_select.h index e3e81575a..e11cbf381 100644 --- a/src/qt_gui/install_dir_select.h +++ b/src/qt_gui/install_dir_select.h @@ -22,9 +22,21 @@ public: return selected_dir; } + bool useForAllQueued() { + return use_for_all_queued; + } + + bool deleteFileOnInstall() { + return delete_file_on_install; + } + private: QWidget* SetupInstallDirList(); QWidget* SetupDialogActions(); void setSelectedDirectory(QListWidgetItem* item); + void setDeleteFileOnInstall(bool enabled); + void setUseForAllQueued(bool enabled); std::filesystem::path selected_dir; + bool delete_file_on_install = false; + bool use_for_all_queued = false; }; diff --git a/src/qt_gui/main_window.cpp b/src/qt_gui/main_window.cpp index 3ee392613..3678b3a82 100644 --- a/src/qt_gui/main_window.cpp +++ b/src/qt_gui/main_window.cpp @@ -725,9 +725,20 @@ void MainWindow::InstallDragDropPkg(std::filesystem::path file, int pkgNum, int return; } auto category = psf.GetString("CATEGORY"); - InstallDirSelect ids; - ids.exec(); - auto game_install_dir = ids.getSelectedDirectory(); + + if (!use_for_all_queued || pkgNum == 1) { + InstallDirSelect ids; + const auto selected = ids.exec(); + if (selected == QDialog::Rejected) { + return; + } + + last_install_dir = ids.getSelectedDirectory(); + delete_file_on_install = ids.deleteFileOnInstall(); + use_for_all_queued = ids.useForAllQueued(); + } + std::filesystem::path game_install_dir = last_install_dir; + auto game_folder_path = game_install_dir / pkg.GetTitleID(); QString pkgType = QString::fromStdString(pkg.GetPkgFlags()); bool use_game_update = pkgType.contains("PATCH") && Config::getSeparateUpdateEnabled(); @@ -879,8 +890,14 @@ void MainWindow::InstallDragDropPkg(std::filesystem::path file, int pkgNum, int if (pkgNum == nPkg) { QString path; Common::FS::PathToQString(path, game_install_dir); + QIcon windowIcon( + Common::FS::PathToUTF8String(game_folder_path / "sce_sys/icon0.png") + .c_str()); QMessageBox extractMsgBox(this); extractMsgBox.setWindowTitle(tr("Extraction Finished")); + if (!windowIcon.isNull()) { + extractMsgBox.setWindowIcon(windowIcon); + } extractMsgBox.setText( QString(tr("Game successfully installed at %1")).arg(path)); extractMsgBox.addButton(QMessageBox::Ok); @@ -894,6 +911,9 @@ void MainWindow::InstallDragDropPkg(std::filesystem::path file, int pkgNum, int }); extractMsgBox.exec(); } + if (delete_file_on_install) { + std::filesystem::remove(file); + } }); connect(&dialog, &QProgressDialog::canceled, [&]() { futureWatcher.cancel(); }); connect(&futureWatcher, &QFutureWatcher::progressValueChanged, &dialog, diff --git a/src/qt_gui/main_window.h b/src/qt_gui/main_window.h index f4163defa..5ac56e44c 100644 --- a/src/qt_gui/main_window.h +++ b/src/qt_gui/main_window.h @@ -123,4 +123,8 @@ protected: } void resizeEvent(QResizeEvent* event) override; + + std::filesystem::path last_install_dir = ""; + bool delete_file_on_install = false; + bool use_for_all_queued = false; }; From 9bad66b24d4082240d00849a3d342d4d4a7c52d3 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Wed, 29 Jan 2025 01:29:52 -0800 Subject: [PATCH 87/99] hotfix: Raise videodec memory back up to 16MB. Found a game that needs more, still should be low enough compared to before to fix some games. --- src/core/libraries/videodec/videodec.cpp | 2 +- src/core/libraries/videodec/videodec2.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/libraries/videodec/videodec.cpp b/src/core/libraries/videodec/videodec.cpp index 79001e76f..02ea61509 100644 --- a/src/core/libraries/videodec/videodec.cpp +++ b/src/core/libraries/videodec/videodec.cpp @@ -9,7 +9,7 @@ namespace Libraries::Videodec { -static constexpr u64 kMinimumMemorySize = 8_MB; ///> Fake minimum memory size for querying +static constexpr u64 kMinimumMemorySize = 16_MB; ///> Fake minimum memory size for querying int PS4_SYSV_ABI sceVideodecCreateDecoder(const OrbisVideodecConfigInfo* pCfgInfoIn, const OrbisVideodecResourceInfo* pRsrcInfoIn, diff --git a/src/core/libraries/videodec/videodec2.cpp b/src/core/libraries/videodec/videodec2.cpp index be0db4ea3..a7e520b41 100644 --- a/src/core/libraries/videodec/videodec2.cpp +++ b/src/core/libraries/videodec/videodec2.cpp @@ -10,7 +10,7 @@ namespace Libraries::Vdec2 { -static constexpr u64 kMinimumMemorySize = 8_MB; ///> Fake minimum memory size for querying +static constexpr u64 kMinimumMemorySize = 16_MB; ///> Fake minimum memory size for querying s32 PS4_SYSV_ABI sceVideodec2QueryComputeMemoryInfo(OrbisVideodec2ComputeMemoryInfo* computeMemInfo) { From aa847de043e2e04512d5d01b4d9e40adc4706b0a Mon Sep 17 00:00:00 2001 From: isshininu Date: Wed, 29 Jan 2025 13:54:08 +0400 Subject: [PATCH 88/99] Update ru_RU translation (#2267) Several changes in ru_RU translation file. --- src/qt_gui/translations/ru_RU.ts | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/qt_gui/translations/ru_RU.ts b/src/qt_gui/translations/ru_RU.ts index 6423f5ba4..0fddb1e7f 100644 --- a/src/qt_gui/translations/ru_RU.ts +++ b/src/qt_gui/translations/ru_RU.ts @@ -126,11 +126,11 @@ Copy All - Копировать все + Копировать всё Delete... - Удаление... + Удалить... Delete Game @@ -158,7 +158,7 @@ Submit a report - Отправить отчет + Отправить отчёт Shortcut creation @@ -297,7 +297,7 @@ Elf Viewer - Elf + Исполняемый файл Game Install Directory @@ -542,7 +542,7 @@ Fullscreen Mode - Режим Полного Экран + Тип полноэкранного режима Enable Separate Update Folder @@ -574,11 +574,11 @@ Trophy Key - Trophy Key + Ключ трофеев Trophy - Trophy + Трофеи Logger @@ -750,7 +750,7 @@ Audio Backend - Звуковая Подсистема + Звуковая подсистема Save @@ -826,7 +826,7 @@ disableTrophycheckBox - Отключить уведомления о трофеях:\nОтключает внутриигровые уведомления о трофеях. Прогресс трофеев по прежнему можно отслеживать в меню Просмотр трофеев (правая кнопка мыши по игре в главном окне). + Отключить уведомления о трофеях:\nОтключает внутриигровые уведомления о трофеях. Прогресс трофеев по прежнему можно отслеживать в меню просмотра трофеев (правая кнопка мыши по игре в главном окне). hideCursorGroupBox @@ -1192,11 +1192,11 @@ Play Time - Времени в игре + Время в игре Never Played - Вы не играли + Нет h @@ -1361,4 +1361,4 @@ ТБ - \ No newline at end of file + From 4bb578f9fb73ce77680e26621717db460a93b0e8 Mon Sep 17 00:00:00 2001 From: Missake212 Date: Wed, 29 Jan 2025 11:45:44 +0100 Subject: [PATCH 89/99] updates french translation (#2262) * updates the french translation * fix space at the end * forgot to translate a line * final changes * final changes 2 --- src/qt_gui/translations/fr.ts | 66 +++++++++++++++++------------------ 1 file changed, 33 insertions(+), 33 deletions(-) diff --git a/src/qt_gui/translations/fr.ts b/src/qt_gui/translations/fr.ts index 601ece8b4..0f87b087b 100644 --- a/src/qt_gui/translations/fr.ts +++ b/src/qt_gui/translations/fr.ts @@ -146,19 +146,19 @@ Compatibility... - Compatibility... + Compatibilité... Update database - Update database + Mettre à jour la base de données View report - View report + Voir rapport Submit a report - Submit a report + Soumettre un rapport Shortcut creation @@ -186,7 +186,7 @@ requiresEnableSeparateUpdateFolder_MSG - This feature requires the 'Enable Separate Update Folder' config option to work. If you want to use this feature, please enable it. + Cette fonctionnalité nécessite l'option 'Dossier séparé pour les mises à jour' pour fonctionner. Si vous voulez utiliser cette fonctionnalité, veuillez l'activer. This game has no update to delete! @@ -546,7 +546,7 @@ Enable Separate Update Folder - Dossier séparé pour les mises à jours + Dossier séparé pour les mises à jour Default tab when opening settings @@ -574,11 +574,11 @@ Trophy Key - Trophy Key + Clé de trophée Trophy - Trophy + Trophée Logger @@ -586,11 +586,11 @@ Log Type - Type + Type de journal Log Filter - Filtre + Filtre du journal Open Log Location @@ -722,7 +722,7 @@ Disable Trophy Pop-ups - Disable Trophy Pop-ups + Désactiver les notifications de trophées Play title music @@ -730,19 +730,19 @@ Update Compatibility Database On Startup - Update Compatibility Database On Startup + Mettre à jour la base de données de compatibilité au lancement Game Compatibility - Game Compatibility + Compatibilité du jeu Display Compatibility Data - Display Compatibility Data + Afficher les données de compatibilité Update Compatibility Database - Update Compatibility Database + Mettre à jour la base de données de compatibilité Volume @@ -750,7 +750,7 @@ Audio Backend - Audio Backend + Back-end audio Save @@ -786,7 +786,7 @@ separateUpdatesCheckBox - Dossier séparé pour les mises à jours:\nInstalle les mises à jours des jeux dans un dossier séparé pour une gestion plus facile. + Dossier séparé pour les mises à jour:\nInstalle les mises à jours des jeux dans un dossier séparé pour une gestion plus facile. showSplashCheckBox @@ -806,7 +806,7 @@ TrophyKey - Trophy Key:\nKey used to decrypt trophies. Must be obtained from your jailbroken console.\nMust contain only hex characters. + Clé de trophées:\nClé utilisée pour décrypter les trophées. Doit être obtenu à partir de votre console jailbreakée.\nDoit contenir des caractères hexadécimaux uniquement. logTypeGroupBox @@ -826,7 +826,7 @@ disableTrophycheckBox - Disable Trophy Pop-ups:\nDisable in-game trophy notifications. Trophy progress can still be tracked using the Trophy Viewer (right-click the game in the main window). + Désactiver les notifications de trophées:\nDésactive les notifications de trophées en jeu. La progression des trophées peut toujours être suivie à l'aide de la Visionneuse de trophées (clique droit sur le jeu sur la fenêtre principale). hideCursorGroupBox @@ -842,15 +842,15 @@ enableCompatibilityCheckBox - Display Compatibility Data:\nDisplays game compatibility information in table view. Enable "Update Compatibility On Startup" to get up-to-date information. + Afficher les données de compatibilité:\nAffiche les informations de compatibilité des jeux dans une colonne dédiée. Activez "Mettre à jour la compatibilité au démarrage" pour avoir des informations à jour. checkCompatibilityOnStartupCheckBox - Update Compatibility On Startup:\nAutomatically update the compatibility database when shadPS4 starts. + Mettre à jour la compatibilité au démarrage:\nMettre à jour automatiquement la base de données de compatibilité au démarrage de shadPS4. updateCompatibilityButton - Update Compatibility Database:\nImmediately update the compatibility database. + Mettre à jour la compatibilité au démarrage:\nMet à jour immédiatement la base de données de compatibilité. Never @@ -1093,7 +1093,7 @@ DownloadComplete_MSG - Patchs téléchargés avec succès ! Tous les patches disponibles pour tous les jeux ont été téléchargés, il n'est pas nécessaire de les télécharger individuellement pour chaque jeu comme c'est le cas pour les Cheats. Si le correctif n'apparaît pas, il se peut qu'il n'existe pas pour le numéro de série et la version spécifiques du jeu. + Patchs téléchargés avec succès ! Tous les patches disponibles pour tous les jeux ont été téléchargés, il n'est pas nécessaire de les télécharger individuellement pour chaque jeu comme c'est le cas pour les Cheats. Si le correctif n'apparaît pas, il se peut qu'il n'existe pas pour la série et la version spécifiques du jeu. Failed to parse JSON data from HTML. @@ -1113,7 +1113,7 @@ You may need to update your game. - Vous devrez peut-être mettre à jour votre jeu. + Vous devriez peut-être mettre à jour votre jeu. Incompatibility Notice @@ -1137,7 +1137,7 @@ Directory does not exist: - Répertoire n'existe pas: + Le répertoire n'existe pas: Failed to open files.json for reading. @@ -1149,7 +1149,7 @@ Can't apply cheats before the game is started - Impossible d'appliquer les Cheats avant que le jeu ne commence. + Impossible d'appliquer les cheats avant que le jeu ne soit lancé @@ -1168,7 +1168,7 @@ Compatibility - Compatibility + Compatibilité Region @@ -1212,27 +1212,27 @@ Compatibility is untested - Compatibility is untested + La compatibilité n'a pas été testé Game does not initialize properly / crashes the emulator - Game does not initialize properly / crashes the emulator + Le jeu ne se lance pas correctement / crash l'émulateur Game boots, but only displays a blank screen - Game boots, but only displays a blank screen + Le jeu démarre, mais n'affiche qu'un écran noir Game displays an image but does not go past the menu - Game displays an image but does not go past the menu + Le jeu affiche une image mais ne dépasse pas le menu Game has game-breaking glitches or unplayable performance - Game has game-breaking glitches or unplayable performance + Le jeu a des problèmes majeurs ou des performances qui le rendent injouable Game can be completed with playable performance and no major glitches - Game can be completed with playable performance and no major glitches + Le jeu peut être terminé avec des performances acceptables et sans problèmes majeurs From 929e15260d8d7a618c10a5f396b1f9e872970425 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Wed, 29 Jan 2025 18:14:36 -0800 Subject: [PATCH 90/99] shader_recompiler: Fix cube sampling coordinates. (#2266) --- .../ir/passes/resource_tracking_pass.cpp | 25 ++++++++++++++----- src/shader_recompiler/specialization.h | 2 ++ 2 files changed, 21 insertions(+), 6 deletions(-) diff --git a/src/shader_recompiler/ir/passes/resource_tracking_pass.cpp b/src/shader_recompiler/ir/passes/resource_tracking_pass.cpp index 43d125bf0..c5f98e5b9 100644 --- a/src/shader_recompiler/ir/passes/resource_tracking_pass.cpp +++ b/src/shader_recompiler/ir/passes/resource_tracking_pass.cpp @@ -583,6 +583,18 @@ void PatchTextureBufferArgs(IR::Block& block, IR::Inst& inst, Info& info) { } } +IR::Value FixCubeCoords(IR::IREmitter& ir, const AmdGpu::Image& image, const IR::Value& x, + const IR::Value& y, const IR::Value& face) { + if (!image.IsCube()) { + return ir.CompositeConstruct(x, y, face); + } + // AMD cube math results in coordinates in the range [1.0, 2.0]. We need + // to convert this to the range [0.0, 1.0] to get correct results. + const auto fixed_x = ir.FPSub(IR::F32{x}, ir.Imm32(1.f)); + const auto fixed_y = ir.FPSub(IR::F32{y}, ir.Imm32(1.f)); + return ir.CompositeConstruct(fixed_x, fixed_y, face); +} + void PatchImageSampleArgs(IR::Block& block, IR::Inst& inst, Info& info, const ImageResource& image_res, const AmdGpu::Image& image) { const auto handle = inst.Arg(0); @@ -643,8 +655,8 @@ void PatchImageSampleArgs(IR::Block& block, IR::Inst& inst, Info& info, case AmdGpu::ImageType::Color1DArray: return read(0); case AmdGpu::ImageType::Color2D: - case AmdGpu::ImageType::Color2DArray: case AmdGpu::ImageType::Color2DMsaa: + case AmdGpu::ImageType::Color2DArray: return ir.CompositeConstruct(read(0), read(8)); case AmdGpu::ImageType::Color3D: return ir.CompositeConstruct(read(0), read(8), read(16)); @@ -665,8 +677,8 @@ void PatchImageSampleArgs(IR::Block& block, IR::Inst& inst, Info& info, addr_reg = addr_reg + 2; return {get_addr_reg(addr_reg - 2), get_addr_reg(addr_reg - 1)}; case AmdGpu::ImageType::Color2D: - case AmdGpu::ImageType::Color2DArray: case AmdGpu::ImageType::Color2DMsaa: + case AmdGpu::ImageType::Color2DArray: // (du/dx, dv/dx), (du/dy, dv/dy) addr_reg = addr_reg + 4; return {ir.CompositeConstruct(get_addr_reg(addr_reg - 4), get_addr_reg(addr_reg - 3)), @@ -711,12 +723,13 @@ void PatchImageSampleArgs(IR::Block& block, IR::Inst& inst, Info& info, case AmdGpu::ImageType::Color2D: // x, y addr_reg = addr_reg + 2; return ir.CompositeConstruct(get_coord(addr_reg - 2, 0), get_coord(addr_reg - 1, 1)); - case AmdGpu::ImageType::Color2DArray: // x, y, slice - [[fallthrough]]; case AmdGpu::ImageType::Color2DMsaa: // x, y, frag + [[fallthrough]]; + case AmdGpu::ImageType::Color2DArray: // x, y, slice addr_reg = addr_reg + 3; - return ir.CompositeConstruct(get_coord(addr_reg - 3, 0), get_coord(addr_reg - 2, 1), - get_addr_reg(addr_reg - 1)); + // Note we can use FixCubeCoords with fallthrough cases since it checks for image type. + return FixCubeCoords(ir, image, get_coord(addr_reg - 3, 0), get_coord(addr_reg - 2, 1), + get_addr_reg(addr_reg - 1)); case AmdGpu::ImageType::Color3D: // x, y, z addr_reg = addr_reg + 3; return ir.CompositeConstruct(get_coord(addr_reg - 3, 0), get_coord(addr_reg - 2, 1), diff --git a/src/shader_recompiler/specialization.h b/src/shader_recompiler/specialization.h index 523e63497..eb0085965 100644 --- a/src/shader_recompiler/specialization.h +++ b/src/shader_recompiler/specialization.h @@ -47,6 +47,7 @@ struct ImageSpecialization { AmdGpu::ImageType type = AmdGpu::ImageType::Color2D; bool is_integer = false; bool is_storage = false; + bool is_cube = false; AmdGpu::CompMapping dst_select{}; AmdGpu::NumberConversion num_conversion{}; @@ -127,6 +128,7 @@ struct StageSpecialization { spec.type = sharp.GetViewType(desc.is_array); spec.is_integer = AmdGpu::IsInteger(sharp.GetNumberFmt()); spec.is_storage = desc.is_written; + spec.is_cube = sharp.IsCube(); if (spec.is_storage) { spec.dst_select = sharp.DstSelect(); } From 0358271b93160a97079376c408b5c270e807826c Mon Sep 17 00:00:00 2001 From: Vinicius Rangel Date: Thu, 30 Jan 2025 04:45:48 -0300 Subject: [PATCH 91/99] Savefixes vii (#2279) * savedata: rewrite save memory functions to handle slot id & better backup management * savedata: auto-restore backup if needed * safe save backup shutdown replaced exit by quick_exit --- src/common/elf_info.h | 1 + src/core/libraries/save_data/save_backup.cpp | 21 +- src/core/libraries/save_data/save_backup.h | 2 + .../libraries/save_data/save_instance.cpp | 53 +-- src/core/libraries/save_data/save_instance.h | 5 +- src/core/libraries/save_data/save_memory.cpp | 365 ++++++++---------- src/core/libraries/save_data/save_memory.h | 36 +- src/core/libraries/save_data/savedata.cpp | 108 ++++-- src/emulator.cpp | 3 +- 9 files changed, 285 insertions(+), 309 deletions(-) diff --git a/src/common/elf_info.h b/src/common/elf_info.h index cb32679bb..d885709cd 100644 --- a/src/common/elf_info.h +++ b/src/common/elf_info.h @@ -80,6 +80,7 @@ public: static constexpr u32 FW_40 = 0x4000000; static constexpr u32 FW_45 = 0x4500000; static constexpr u32 FW_50 = 0x5000000; + static constexpr u32 FW_55 = 0x5500000; static constexpr u32 FW_80 = 0x8000000; static ElfInfo& Instance() { diff --git a/src/core/libraries/save_data/save_backup.cpp b/src/core/libraries/save_data/save_backup.cpp index 5261cdb11..f85845f70 100644 --- a/src/core/libraries/save_data/save_backup.cpp +++ b/src/core/libraries/save_data/save_backup.cpp @@ -121,15 +121,17 @@ static void BackupThreadBody() { std::scoped_lock lk{g_backup_queue_mutex}; g_backup_queue.front().done = true; } - std::this_thread::sleep_for(std::chrono::seconds(5)); // Don't backup too often { std::scoped_lock lk{g_backup_queue_mutex}; g_backup_queue.pop_front(); - g_result_queue.push_back(std::move(req)); - if (g_result_queue.size() > 20) { - g_result_queue.pop_front(); + if (req.origin != OrbisSaveDataEventType::__DO_NOT_SAVE) { + g_result_queue.push_back(std::move(req)); + if (g_result_queue.size() > 20) { + g_result_queue.pop_front(); + } } } + std::this_thread::sleep_for(std::chrono::seconds(5)); // Don't backup too often } g_backup_status = WorkerStatus::NotStarted; } @@ -141,6 +143,15 @@ void StartThread() { LOG_DEBUG(Lib_SaveData, "Starting backup thread"); g_backup_status = WorkerStatus::Waiting; g_backup_thread = std::jthread{BackupThreadBody}; + static std::once_flag flag; + std::call_once(flag, [] { + std::at_quick_exit([] { + StopThread(); + while (GetWorkerStatus() != WorkerStatus::NotStarted) { + std::this_thread::sleep_for(std::chrono::milliseconds(100)); + } + }); + }); } void StopThread() { @@ -148,12 +159,12 @@ void StopThread() { return; } LOG_DEBUG(Lib_SaveData, "Stopping backup thread"); + g_backup_status = WorkerStatus::Stopping; { std::scoped_lock lk{g_backup_queue_mutex}; g_backup_queue.emplace_back(BackupRequest{}); } g_backup_thread_semaphore.release(); - g_backup_status = WorkerStatus::Stopping; } bool NewRequest(OrbisUserServiceUserId user_id, std::string_view title_id, diff --git a/src/core/libraries/save_data/save_backup.h b/src/core/libraries/save_data/save_backup.h index e49c69f60..83a263c9b 100644 --- a/src/core/libraries/save_data/save_backup.h +++ b/src/core/libraries/save_data/save_backup.h @@ -25,6 +25,8 @@ enum class OrbisSaveDataEventType : u32 { UMOUNT_BACKUP = 1, BACKUP = 2, SAVE_DATA_MEMORY_SYNC = 3, + + __DO_NOT_SAVE = 1000000, // This value is only for the backup thread }; struct BackupRequest { diff --git a/src/core/libraries/save_data/save_instance.cpp b/src/core/libraries/save_data/save_instance.cpp index c2b7dca3c..26708d2d6 100644 --- a/src/core/libraries/save_data/save_instance.cpp +++ b/src/core/libraries/save_data/save_instance.cpp @@ -10,6 +10,7 @@ #include "common/path_util.h" #include "common/singleton.h" #include "core/file_sys/fs.h" +#include "save_backup.h" #include "save_instance.h" constexpr auto OrbisSaveDataBlocksMin2 = 96; // 3MiB @@ -45,14 +46,13 @@ static const std::unordered_map default_title = { namespace Libraries::SaveData { -std::filesystem::path SaveInstance::MakeTitleSavePath(OrbisUserServiceUserId user_id, - std::string_view game_serial) { +fs::path SaveInstance::MakeTitleSavePath(OrbisUserServiceUserId user_id, + std::string_view game_serial) { return Config::GetSaveDataPath() / std::to_string(user_id) / game_serial; } -std::filesystem::path SaveInstance::MakeDirSavePath(OrbisUserServiceUserId user_id, - std::string_view game_serial, - std::string_view dir_name) { +fs::path SaveInstance::MakeDirSavePath(OrbisUserServiceUserId user_id, std::string_view game_serial, + std::string_view dir_name) { return Config::GetSaveDataPath() / std::to_string(user_id) / game_serial / dir_name; } @@ -65,7 +65,7 @@ uint64_t SaveInstance::GetMaxBlockFromSFO(const PSF& psf) { return *(uint64_t*)value.data(); } -std::filesystem::path SaveInstance::GetParamSFOPath(const std::filesystem::path& dir_path) { +fs::path SaveInstance::GetParamSFOPath(const fs::path& dir_path) { return dir_path / sce_sys / "param.sfo"; } @@ -129,7 +129,6 @@ SaveInstance& SaveInstance::operator=(SaveInstance&& other) noexcept { save_path = std::move(other.save_path); param_sfo_path = std::move(other.param_sfo_path); corrupt_file_path = std::move(other.corrupt_file_path); - corrupt_file = std::move(other.corrupt_file); param_sfo = std::move(other.param_sfo); mount_point = std::move(other.mount_point); max_blocks = other.max_blocks; @@ -142,7 +141,8 @@ SaveInstance& SaveInstance::operator=(SaveInstance&& other) noexcept { return *this; } -void SaveInstance::SetupAndMount(bool read_only, bool copy_icon, bool ignore_corrupt) { +void SaveInstance::SetupAndMount(bool read_only, bool copy_icon, bool ignore_corrupt, + bool dont_restore_backup) { if (mounted) { UNREACHABLE_MSG("Save instance is already mounted"); } @@ -161,25 +161,27 @@ void SaveInstance::SetupAndMount(bool read_only, bool copy_icon, bool ignore_cor } exists = true; } else { + std::optional err; if (!ignore_corrupt && fs::exists(corrupt_file_path)) { - throw std::filesystem::filesystem_error( - "Corrupted save data", corrupt_file_path, - std::make_error_code(std::errc::illegal_byte_sequence)); + err = fs::filesystem_error("Corrupted save data", corrupt_file_path, + std::make_error_code(std::errc::illegal_byte_sequence)); + } else if (!param_sfo.Open(param_sfo_path)) { + err = fs::filesystem_error("Failed to read param.sfo", param_sfo_path, + std::make_error_code(std::errc::illegal_byte_sequence)); } - if (!param_sfo.Open(param_sfo_path)) { - throw std::filesystem::filesystem_error( - "Failed to read param.sfo", param_sfo_path, - std::make_error_code(std::errc::illegal_byte_sequence)); + if (err.has_value()) { + if (dont_restore_backup) { + throw err.value(); + } + if (Backup::Restore(save_path)) { + return SetupAndMount(read_only, copy_icon, ignore_corrupt, true); + } } } if (!ignore_corrupt && !read_only) { - int err = corrupt_file.Open(corrupt_file_path, Common::FS::FileAccessMode::Write); - if (err != 0) { - throw std::filesystem::filesystem_error( - "Failed to open corrupted file", corrupt_file_path, - std::make_error_code(std::errc::illegal_byte_sequence)); - } + Common::FS::IOFile f(corrupt_file_path, Common::FS::FileAccessMode::Write); + f.Close(); } max_blocks = static_cast(GetMaxBlockFromSFO(param_sfo)); @@ -197,12 +199,11 @@ void SaveInstance::Umount() { mounted = false; const bool ok = param_sfo.Encode(param_sfo_path); if (!ok) { - throw std::filesystem::filesystem_error("Failed to write param.sfo", param_sfo_path, - std::make_error_code(std::errc::permission_denied)); + throw fs::filesystem_error("Failed to write param.sfo", param_sfo_path, + std::make_error_code(std::errc::permission_denied)); } param_sfo = PSF(); - corrupt_file.Close(); fs::remove(corrupt_file_path); g_mnt->Unmount(save_path, mount_point); } @@ -216,8 +217,8 @@ void SaveInstance::CreateFiles() { const bool ok = param_sfo.Encode(param_sfo_path); if (!ok) { - throw std::filesystem::filesystem_error("Failed to write param.sfo", param_sfo_path, - std::make_error_code(std::errc::permission_denied)); + throw fs::filesystem_error("Failed to write param.sfo", param_sfo_path, + std::make_error_code(std::errc::permission_denied)); } } diff --git a/src/core/libraries/save_data/save_instance.h b/src/core/libraries/save_data/save_instance.h index 3be5c4595..6e7ac8f66 100644 --- a/src/core/libraries/save_data/save_instance.h +++ b/src/core/libraries/save_data/save_instance.h @@ -42,8 +42,6 @@ class SaveInstance { std::filesystem::path param_sfo_path; std::filesystem::path corrupt_file_path; - Common::FS::IOFile corrupt_file; - PSF param_sfo; std::string mount_point; @@ -80,7 +78,8 @@ public: SaveInstance& operator=(const SaveInstance& other) = delete; SaveInstance& operator=(SaveInstance&& other) noexcept; - void SetupAndMount(bool read_only = false, bool copy_icon = false, bool ignore_corrupt = false); + void SetupAndMount(bool read_only = false, bool copy_icon = false, bool ignore_corrupt = false, + bool dont_restore_backup = false); void Umount(); diff --git a/src/core/libraries/save_data/save_memory.cpp b/src/core/libraries/save_data/save_memory.cpp index 84179bc27..13e122c60 100644 --- a/src/core/libraries/save_data/save_memory.cpp +++ b/src/core/libraries/save_data/save_memory.cpp @@ -6,14 +6,16 @@ #include #include #include +#include #include #include #include #include "common/assert.h" +#include "common/elf_info.h" #include "common/logging/log.h" -#include "common/polyfill_thread.h" +#include "common/path_util.h" #include "common/singleton.h" #include "common/thread.h" #include "core/file_sys/fs.h" @@ -23,265 +25,202 @@ using Common::FS::IOFile; namespace fs = std::filesystem; constexpr std::string_view sce_sys = "sce_sys"; // system folder inside save -constexpr std::string_view DirnameSaveDataMemory = "sce_sdmemory"; +constexpr std::string_view StandardDirnameSaveDataMemory = "sce_sdmemory"; constexpr std::string_view FilenameSaveDataMemory = "memory.dat"; +constexpr std::string_view IconName = "icon0.png"; +constexpr std::string_view CorruptFileName = "corrupted"; namespace Libraries::SaveData::SaveMemory { static Core::FileSys::MntPoints* g_mnt = Common::Singleton::Instance(); -static OrbisUserServiceUserId g_user_id{}; -static std::string g_game_serial{}; -static std::filesystem::path g_save_path{}; -static std::filesystem::path g_param_sfo_path{}; -static PSF g_param_sfo; +struct SlotData { + OrbisUserServiceUserId user_id; + std::string game_serial; + std::filesystem::path folder_path; + PSF sfo; + std::vector memory_cache; +}; -static bool g_save_memory_initialized = false; -static std::mutex g_saving_memory_mutex; -static std::vector g_save_memory; +static std::mutex g_slot_mtx; +static std::unordered_map g_attached_slots; -static std::filesystem::path g_icon_path; -static std::vector g_icon_memory; +void PersistMemory(u32 slot_id, bool lock) { + std::unique_lock lck{g_slot_mtx, std::defer_lock}; + if (lock) { + lck.lock(); + } + auto& data = g_attached_slots[slot_id]; + auto memoryPath = data.folder_path / FilenameSaveDataMemory; + fs::create_directories(memoryPath.parent_path()); -static std::condition_variable g_trigger_save_memory; -static std::atomic_bool g_saving_memory = false; -static std::atomic_bool g_save_event = false; -static std::jthread g_save_memory_thread; - -static std::atomic_bool g_memory_dirty = false; -static std::atomic_bool g_param_dirty = false; -static std::atomic_bool g_icon_dirty = false; - -static void SaveFileSafe(void* buf, size_t count, const std::filesystem::path& path) { - const auto& dir = path.parent_path(); - const auto& name = path.filename(); - const auto tmp_path = dir / (name.string() + ".tmp"); - - IOFile file(tmp_path, Common::FS::FileAccessMode::Write); - file.WriteRaw(buf, count); - file.Close(); - - fs::remove(path); - fs::rename(tmp_path, path); -} - -[[noreturn]] void SaveThreadLoop() { - Common::SetCurrentThreadName("shadPS4:SaveData:SaveDataMemoryThread"); - std::mutex mtx; - while (true) { - { - std::unique_lock lk{mtx}; - g_trigger_save_memory.wait(lk); - } - // Save the memory - g_saving_memory = true; - std::scoped_lock lk{g_saving_memory_mutex}; + int n = 0; + std::string errMsg; + while (n++ < 10) { try { - LOG_DEBUG(Lib_SaveData, "Saving save data memory {}", fmt::UTF(g_save_path.u8string())); - - if (g_memory_dirty) { - g_memory_dirty = false; - SaveFileSafe(g_save_memory.data(), g_save_memory.size(), - g_save_path / FilenameSaveDataMemory); + IOFile f; + int r = f.Open(memoryPath, Common::FS::FileAccessMode::Write); + if (f.IsOpen()) { + f.WriteRaw(data.memory_cache.data(), data.memory_cache.size()); + f.Close(); + return; } - if (g_param_dirty) { - g_param_dirty = false; - static std::vector buf; - g_param_sfo.Encode(buf); - SaveFileSafe(buf.data(), buf.size(), g_param_sfo_path); - } - if (g_icon_dirty) { - g_icon_dirty = false; - SaveFileSafe(g_icon_memory.data(), g_icon_memory.size(), g_icon_path); - } - - if (g_save_event) { - Backup::PushBackupEvent(Backup::BackupRequest{ - .user_id = g_user_id, - .title_id = g_game_serial, - .dir_name = std::string{DirnameSaveDataMemory}, - .origin = Backup::OrbisSaveDataEventType::SAVE_DATA_MEMORY_SYNC, - .save_path = g_save_path, - }); - g_save_event = false; - } - } catch (const fs::filesystem_error& e) { - LOG_ERROR(Lib_SaveData, "Failed to save save data memory: {}", e.what()); - MsgDialog::ShowMsgDialog(MsgDialog::MsgDialogState{ - MsgDialog::MsgDialogState::UserState{ - .type = MsgDialog::ButtonType::OK, - .msg = fmt::format("Failed to save save data memory.\nCode: <{}>\n{}", - e.code().message(), e.what()), - }, - }); + const auto err = std::error_code{r, std::iostream_category()}; + throw std::filesystem::filesystem_error{err.message(), err}; + } catch (const std::filesystem::filesystem_error& e) { + errMsg = std::string{e.what()}; + std::this_thread::sleep_for(std::chrono::seconds(1)); } - g_saving_memory = false; } + const MsgDialog::MsgDialogState dialog{MsgDialog::MsgDialogState::UserState{ + .type = MsgDialog::ButtonType::OK, + .msg = "Failed to persist save memory:\n" + errMsg + "\nat " + + Common::FS::PathToUTF8String(memoryPath), + }}; + MsgDialog::ShowMsgDialog(dialog); } -void SetDirectories(OrbisUserServiceUserId user_id, std::string _game_serial) { - g_user_id = user_id; - g_game_serial = std::move(_game_serial); - g_save_path = SaveInstance::MakeDirSavePath(user_id, g_game_serial, DirnameSaveDataMemory); - g_param_sfo_path = SaveInstance::GetParamSFOPath(g_save_path); - g_param_sfo = PSF(); - g_icon_path = g_save_path / sce_sys / "icon0.png"; +std::string GetSaveDir(u32 slot_id) { + std::string dir(StandardDirnameSaveDataMemory); + if (slot_id > 0) { + dir += std::to_string(slot_id); + } + return dir; } -const std::filesystem::path& GetSavePath() { - return g_save_path; +std::filesystem::path GetSavePath(OrbisUserServiceUserId user_id, u32 slot_id, + std::string_view game_serial) { + std::string dir(StandardDirnameSaveDataMemory); + if (slot_id > 0) { + dir += std::to_string(slot_id); + } + return SaveInstance::MakeDirSavePath(user_id, Common::ElfInfo::Instance().GameSerial(), dir); } -size_t CreateSaveMemory(size_t memory_size) { - size_t existed_size = 0; +size_t SetupSaveMemory(OrbisUserServiceUserId user_id, u32 slot_id, std::string_view game_serial) { + std::lock_guard lck{g_slot_mtx}; - static std::once_flag init_save_thread_flag; - std::call_once(init_save_thread_flag, - [] { g_save_memory_thread = std::jthread{SaveThreadLoop}; }); + const auto save_dir = GetSavePath(user_id, slot_id, game_serial); - g_save_memory.resize(memory_size); - SaveInstance::SetupDefaultParamSFO(g_param_sfo, std::string{DirnameSaveDataMemory}, - g_game_serial); + auto& data = g_attached_slots[slot_id]; + data = SlotData{ + .user_id = user_id, + .game_serial = std::string{game_serial}, + .folder_path = save_dir, + .sfo = {}, + .memory_cache = {}, + }; - g_save_memory_initialized = true; + SaveInstance::SetupDefaultParamSFO(data.sfo, GetSaveDir(slot_id), std::string{game_serial}); - if (!fs::exists(g_param_sfo_path)) { - // Create save memory - fs::create_directories(g_save_path / sce_sys); - - IOFile memory_file{g_save_path / FilenameSaveDataMemory, Common::FS::FileAccessMode::Write}; - bool ok = memory_file.SetSize(memory_size); - if (!ok) { - LOG_ERROR(Lib_SaveData, "Failed to set memory size"); - throw std::filesystem::filesystem_error( - "Failed to set save memory size", g_save_path / FilenameSaveDataMemory, - std::make_error_code(std::errc::no_space_on_device)); - } - memory_file.Close(); - } else { - // Load save memory - - bool ok = g_param_sfo.Open(g_param_sfo_path); - if (!ok) { - LOG_ERROR(Lib_SaveData, "Failed to open SFO at {}", - fmt::UTF(g_param_sfo_path.u8string())); - throw std::filesystem::filesystem_error( - "failed to open SFO", g_param_sfo_path, - std::make_error_code(std::errc::illegal_byte_sequence)); - } - - IOFile memory_file{g_save_path / FilenameSaveDataMemory, Common::FS::FileAccessMode::Read}; - if (!memory_file.IsOpen()) { - LOG_ERROR(Lib_SaveData, "Failed to open save memory"); - throw std::filesystem::filesystem_error( - "failed to open save memory", g_save_path / FilenameSaveDataMemory, - std::make_error_code(std::errc::permission_denied)); - } - size_t save_size = memory_file.GetSize(); - existed_size = save_size; - memory_file.Seek(0); - memory_file.ReadRaw(g_save_memory.data(), std::min(save_size, memory_size)); - memory_file.Close(); + auto param_sfo_path = SaveInstance::GetParamSFOPath(save_dir); + if (!fs::exists(param_sfo_path)) { + return 0; } - return existed_size; + if (!data.sfo.Open(param_sfo_path) || fs::exists(save_dir / CorruptFileName)) { + if (!Backup::Restore(save_dir)) { // Could not restore the backup + return 0; + } + } + + const auto memory = save_dir / FilenameSaveDataMemory; + if (fs::exists(memory)) { + return fs::file_size(memory); + } + + return 0; } -void SetIcon(void* buf, size_t buf_size) { +void SetIcon(u32 slot_id, void* buf, size_t buf_size) { + std::lock_guard lck{g_slot_mtx}; + const auto& data = g_attached_slots[slot_id]; + const auto icon_path = data.folder_path / sce_sys / "icon0.png"; if (buf == nullptr) { const auto& src_icon = g_mnt->GetHostPath("/app0/sce_sys/save_data.png"); - if (fs::exists(src_icon)) { - if (fs::exists(g_icon_path)) { - fs::remove(g_icon_path); - } - fs::copy_file(src_icon, g_icon_path); + if (fs::exists(icon_path)) { + fs::remove(icon_path); } - if (fs::exists(g_icon_path)) { - IOFile file(g_icon_path, Common::FS::FileAccessMode::Read); - size_t size = file.GetSize(); - file.Seek(0); - g_icon_memory.resize(size); - file.ReadRaw(g_icon_memory.data(), size); - file.Close(); + if (fs::exists(src_icon)) { + fs::create_directories(icon_path.parent_path()); + fs::copy_file(src_icon, icon_path); } } else { - g_icon_memory.resize(buf_size); - std::memcpy(g_icon_memory.data(), buf, buf_size); - IOFile file(g_icon_path, Common::FS::FileAccessMode::Write); - file.Seek(0); - file.WriteRaw(g_icon_memory.data(), buf_size); + IOFile file(icon_path, Common::FS::FileAccessMode::Write); + file.WriteRaw(buf, buf_size); file.Close(); } } -void WriteIcon(void* buf, size_t buf_size) { - if (buf_size != g_icon_memory.size()) { - g_icon_memory.resize(buf_size); +bool IsSaveMemoryInitialized(u32 slot_id) { + std::lock_guard lck{g_slot_mtx}; + return g_attached_slots.contains(slot_id); +} + +PSF& GetParamSFO(u32 slot_id) { + std::lock_guard lck{g_slot_mtx}; + auto& data = g_attached_slots[slot_id]; + return data.sfo; +} + +std::vector GetIcon(u32 slot_id) { + std::lock_guard lck{g_slot_mtx}; + auto& data = g_attached_slots[slot_id]; + const auto icon_path = data.folder_path / sce_sys / "icon0.png"; + IOFile f{icon_path, Common::FS::FileAccessMode::Read}; + if (!f.IsOpen()) { + return {}; } - std::memcpy(g_icon_memory.data(), buf, buf_size); - g_icon_dirty = true; + const u64 size = f.GetSize(); + std::vector ret; + ret.resize(size); + f.ReadSpan(std::span{ret}); + return ret; } -bool IsSaveMemoryInitialized() { - return g_save_memory_initialized; -} - -PSF& GetParamSFO() { - return g_param_sfo; -} - -std::span GetIcon() { - return {g_icon_memory}; -} - -void SaveSFO(bool sync) { - if (!sync) { - g_param_dirty = true; - return; - } - const bool ok = g_param_sfo.Encode(g_param_sfo_path); +void SaveSFO(u32 slot_id) { + std::lock_guard lck{g_slot_mtx}; + const auto& data = g_attached_slots[slot_id]; + const auto sfo_path = SaveInstance::GetParamSFOPath(data.folder_path); + fs::create_directories(sfo_path.parent_path()); + const bool ok = data.sfo.Encode(sfo_path); if (!ok) { LOG_ERROR(Lib_SaveData, "Failed to encode param.sfo"); - throw std::filesystem::filesystem_error("Failed to write param.sfo", g_param_sfo_path, + throw std::filesystem::filesystem_error("Failed to write param.sfo", sfo_path, std::make_error_code(std::errc::permission_denied)); } } -bool IsSaving() { - return g_saving_memory; + +void ReadMemory(u32 slot_id, void* buf, size_t buf_size, int64_t offset) { + std::lock_guard lk{g_slot_mtx}; + auto& data = g_attached_slots[slot_id]; + auto& memory = data.memory_cache; + if (memory.empty()) { // Load file + IOFile f{data.folder_path / FilenameSaveDataMemory, Common::FS::FileAccessMode::Read}; + if (f.IsOpen()) { + memory.resize(f.GetSize()); + f.Seek(0); + f.ReadSpan(std::span{memory}); + } + } + s64 read_size = buf_size; + if (read_size + offset > memory.size()) { + read_size = memory.size() - offset; + } + std::memcpy(buf, memory.data() + offset, read_size); } -bool TriggerSaveWithoutEvent() { - if (g_saving_memory) { - return false; +void WriteMemory(u32 slot_id, void* buf, size_t buf_size, int64_t offset) { + std::lock_guard lk{g_slot_mtx}; + auto& data = g_attached_slots[slot_id]; + auto& memory = data.memory_cache; + if (offset + buf_size > memory.size()) { + memory.resize(offset + buf_size); } - g_trigger_save_memory.notify_one(); - return true; -} - -bool TriggerSave() { - if (g_saving_memory) { - return false; - } - g_save_event = true; - g_trigger_save_memory.notify_one(); - return true; -} - -void ReadMemory(void* buf, size_t buf_size, int64_t offset) { - std::scoped_lock lk{g_saving_memory_mutex}; - if (offset + buf_size > g_save_memory.size()) { - UNREACHABLE_MSG("ReadMemory out of bounds"); - } - std::memcpy(buf, g_save_memory.data() + offset, buf_size); -} - -void WriteMemory(void* buf, size_t buf_size, int64_t offset) { - std::scoped_lock lk{g_saving_memory_mutex}; - if (offset + buf_size > g_save_memory.size()) { - g_save_memory.resize(offset + buf_size); - } - std::memcpy(g_save_memory.data() + offset, buf, buf_size); - g_memory_dirty = true; + std::memcpy(memory.data() + offset, buf, buf_size); + PersistMemory(slot_id, false); + Backup::NewRequest(data.user_id, data.game_serial, GetSaveDir(slot_id), + Backup::OrbisSaveDataEventType::__DO_NOT_SAVE); } } // namespace Libraries::SaveData::SaveMemory \ No newline at end of file diff --git a/src/core/libraries/save_data/save_memory.h b/src/core/libraries/save_data/save_memory.h index 04eeaa652..681865634 100644 --- a/src/core/libraries/save_data/save_memory.h +++ b/src/core/libraries/save_data/save_memory.h @@ -3,7 +3,7 @@ #pragma once -#include +#include #include "save_backup.h" class PSF; @@ -14,36 +14,30 @@ using OrbisUserServiceUserId = s32; namespace Libraries::SaveData::SaveMemory { -void SetDirectories(OrbisUserServiceUserId user_id, std::string game_serial); +void PersistMemory(u32 slot_id, bool lock = true); -[[nodiscard]] const std::filesystem::path& GetSavePath(); +[[nodiscard]] std::string GetSaveDir(u32 slot_id); -// returns the size of the existed save memory -size_t CreateSaveMemory(size_t memory_size); +[[nodiscard]] std::filesystem::path GetSavePath(OrbisUserServiceUserId user_id, u32 slot_id, + std::string_view game_serial); -// Initialize the icon. Set buf to null to read the standard icon. -void SetIcon(void* buf, size_t buf_size); +// returns the size of the save memory if exists +size_t SetupSaveMemory(OrbisUserServiceUserId user_id, u32 slot_id, std::string_view game_serial); -// Update the icon -void WriteIcon(void* buf, size_t buf_size); +// Write the icon. Set buf to null to read the standard icon. +void SetIcon(u32 slot_id, void* buf = nullptr, size_t buf_size = 0); -[[nodiscard]] bool IsSaveMemoryInitialized(); +[[nodiscard]] bool IsSaveMemoryInitialized(u32 slot_id); -[[nodiscard]] PSF& GetParamSFO(); +[[nodiscard]] PSF& GetParamSFO(u32 slot_id); -[[nodiscard]] std::span GetIcon(); +[[nodiscard]] std::vector GetIcon(u32 slot_id); // Save now or wait for the background thread to save -void SaveSFO(bool sync = false); +void SaveSFO(u32 slot_id); -[[nodiscard]] bool IsSaving(); +void ReadMemory(u32 slot_id, void* buf, size_t buf_size, int64_t offset); -bool TriggerSaveWithoutEvent(); - -bool TriggerSave(); - -void ReadMemory(void* buf, size_t buf_size, int64_t offset); - -void WriteMemory(void* buf, size_t buf_size, int64_t offset); +void WriteMemory(u32 slot_id, void* buf, size_t buf_size, int64_t offset); } // namespace Libraries::SaveData::SaveMemory \ No newline at end of file diff --git a/src/core/libraries/save_data/savedata.cpp b/src/core/libraries/save_data/savedata.cpp index b573ded1e..e9ad77d69 100644 --- a/src/core/libraries/save_data/savedata.cpp +++ b/src/core/libraries/save_data/savedata.cpp @@ -177,7 +177,8 @@ struct OrbisSaveDataMemoryGet2 { OrbisSaveDataMemoryData* data; OrbisSaveDataParam* param; OrbisSaveDataIcon* icon; - std::array _reserved; + u32 slotId; + std::array _reserved; }; struct OrbisSaveDataMemorySet2 { @@ -186,6 +187,8 @@ struct OrbisSaveDataMemorySet2 { const OrbisSaveDataMemoryData* data; const OrbisSaveDataParam* param; const OrbisSaveDataIcon* icon; + u32 dataNum; + u32 slotId; std::array _reserved; }; @@ -198,7 +201,8 @@ struct OrbisSaveDataMemorySetup2 { const OrbisSaveDataParam* initParam; // +4.5 const OrbisSaveDataIcon* initIcon; - std::array _reserved; + u32 slotId; + std::array _reserved; }; struct OrbisSaveDataMemorySetupResult { @@ -206,9 +210,16 @@ struct OrbisSaveDataMemorySetupResult { std::array _reserved; }; +enum OrbisSaveDataMemorySyncOption : u32 { + NONE = 0, + BLOCKING = 1, +}; + struct OrbisSaveDataMemorySync { OrbisUserServiceUserId userId; - std::array _reserved; + u32 slotId; + OrbisSaveDataMemorySyncOption option; + std::array _reserved; }; struct OrbisSaveDataMount2 { @@ -327,6 +338,7 @@ static void initialize() { g_initialized = true; g_game_serial = ElfInfo::Instance().GameSerial(); g_fw_ver = ElfInfo::Instance().FirmwareVer(); + Backup::StartThread(); } // game_00other | game*other @@ -558,7 +570,6 @@ Error PS4_SYSV_ABI sceSaveDataBackup(const OrbisSaveDataBackup* backup) { } } - Backup::StartThread(); Backup::NewRequest(backup->userId, title, dir_name, OrbisSaveDataEventType::BACKUP); return Error::OK; @@ -1136,22 +1147,27 @@ Error PS4_SYSV_ABI sceSaveDataGetSaveDataMemory2(OrbisSaveDataMemoryGet2* getPar LOG_INFO(Lib_SaveData, "called with invalid parameter"); return Error::PARAMETER; } - if (!SaveMemory::IsSaveMemoryInitialized()) { + + u32 slot_id = 0; + if (g_fw_ver > ElfInfo::FW_50) { + slot_id = getParam->slotId; + } + if (!SaveMemory::IsSaveMemoryInitialized(slot_id)) { LOG_INFO(Lib_SaveData, "called without save memory initialized"); return Error::MEMORY_NOT_READY; } LOG_DEBUG(Lib_SaveData, "called"); auto data = getParam->data; if (data != nullptr) { - SaveMemory::ReadMemory(data->buf, data->bufSize, data->offset); + SaveMemory::ReadMemory(slot_id, data->buf, data->bufSize, data->offset); } auto param = getParam->param; if (param != nullptr) { - param->FromSFO(SaveMemory::GetParamSFO()); + param->FromSFO(SaveMemory::GetParamSFO(slot_id)); } auto icon = getParam->icon; if (icon != nullptr) { - auto icon_mem = SaveMemory::GetIcon(); + auto icon_mem = SaveMemory::GetIcon(slot_id); size_t total = std::min(icon->bufSize, icon_mem.size()); std::memcpy(icon->buf, icon_mem.data(), total); icon->dataSize = total; @@ -1494,36 +1510,37 @@ Error PS4_SYSV_ABI sceSaveDataSetSaveDataMemory2(const OrbisSaveDataMemorySet2* LOG_INFO(Lib_SaveData, "called with invalid parameter"); return Error::PARAMETER; } - if (!SaveMemory::IsSaveMemoryInitialized()) { + u32 slot_id = 0; + u32 data_num = 1; + if (g_fw_ver > ElfInfo::FW_50) { + slot_id = setParam->slotId; + if (setParam->dataNum > 1) { + data_num = setParam->dataNum; + } + } + if (!SaveMemory::IsSaveMemoryInitialized(slot_id)) { LOG_INFO(Lib_SaveData, "called without save memory initialized"); return Error::MEMORY_NOT_READY; } - if (SaveMemory::IsSaving()) { - int count = 0; - while (++count < 100 && SaveMemory::IsSaving()) { // try for more 10 seconds - std::this_thread::sleep_for(chrono::milliseconds(100)); - } - if (SaveMemory::IsSaving()) { - LOG_TRACE(Lib_SaveData, "called while saving"); - return Error::BUSY_FOR_SAVING; - } - } + LOG_DEBUG(Lib_SaveData, "called"); auto data = setParam->data; if (data != nullptr) { - SaveMemory::WriteMemory(data->buf, data->bufSize, data->offset); + for (int i = 0; i < data_num; i++) { + SaveMemory::WriteMemory(slot_id, data[i].buf, data[i].bufSize, data[i].offset); + } } auto param = setParam->param; if (param != nullptr) { - param->ToSFO(SaveMemory::GetParamSFO()); - SaveMemory::SaveSFO(); - } - auto icon = setParam->icon; - if (icon != nullptr) { - SaveMemory::WriteIcon(icon->buf, icon->bufSize); + param->ToSFO(SaveMemory::GetParamSFO(slot_id)); + SaveMemory::SaveSFO(slot_id); + } + + auto icon = setParam->icon; + if (icon != nullptr) { + SaveMemory::SetIcon(slot_id, icon->buf, icon->bufSize); } - SaveMemory::TriggerSaveWithoutEvent(); return Error::OK; } @@ -1563,9 +1580,12 @@ Error PS4_SYSV_ABI sceSaveDataSetupSaveDataMemory2(const OrbisSaveDataMemorySetu } LOG_DEBUG(Lib_SaveData, "called"); - SaveMemory::SetDirectories(setupParam->userId, g_game_serial); + u32 slot_id = 0; + if (g_fw_ver > ElfInfo::FW_50) { + slot_id = setupParam->slotId; + } - const auto& save_path = SaveMemory::GetSavePath(); + const auto& save_path = SaveMemory::GetSavePath(setupParam->userId, slot_id, g_game_serial); for (const auto& instance : g_mount_slots) { if (instance.has_value() && instance->GetSavePath() == save_path) { return Error::BUSY; @@ -1573,21 +1593,21 @@ Error PS4_SYSV_ABI sceSaveDataSetupSaveDataMemory2(const OrbisSaveDataMemorySetu } try { - size_t existed_size = SaveMemory::CreateSaveMemory(setupParam->memorySize); + size_t existed_size = + SaveMemory::SetupSaveMemory(setupParam->userId, slot_id, g_game_serial); if (existed_size == 0) { // Just created if (g_fw_ver >= ElfInfo::FW_45 && setupParam->initParam != nullptr) { - auto& sfo = SaveMemory::GetParamSFO(); + auto& sfo = SaveMemory::GetParamSFO(slot_id); setupParam->initParam->ToSFO(sfo); } - SaveMemory::SaveSFO(); + SaveMemory::SaveSFO(slot_id); auto init_icon = setupParam->initIcon; if (g_fw_ver >= ElfInfo::FW_45 && init_icon != nullptr) { - SaveMemory::SetIcon(init_icon->buf, init_icon->bufSize); + SaveMemory::SetIcon(slot_id, init_icon->buf, init_icon->bufSize); } else { - SaveMemory::SetIcon(nullptr, 0); + SaveMemory::SetIcon(slot_id); } - SaveMemory::TriggerSaveWithoutEvent(); } if (g_fw_ver >= ElfInfo::FW_45 && result != nullptr) { result->existedMemorySize = existed_size; @@ -1631,15 +1651,23 @@ Error PS4_SYSV_ABI sceSaveDataSyncSaveDataMemory(OrbisSaveDataMemorySync* syncPa LOG_INFO(Lib_SaveData, "called with invalid parameter"); return Error::PARAMETER; } - if (!SaveMemory::IsSaveMemoryInitialized()) { + + u32 slot_id = 0; + if (g_fw_ver > ElfInfo::FW_50) { + slot_id = syncParam->slotId; + } + + if (!SaveMemory::IsSaveMemoryInitialized(slot_id)) { LOG_INFO(Lib_SaveData, "called without save memory initialized"); return Error::MEMORY_NOT_READY; } LOG_DEBUG(Lib_SaveData, "called"); - bool ok = SaveMemory::TriggerSave(); - if (!ok) { - return Error::BUSY_FOR_SAVING; - } + + SaveMemory::PersistMemory(slot_id); + const auto& save_path = SaveMemory::GetSaveDir(slot_id); + Backup::NewRequest(syncParam->userId, g_game_serial, save_path, + OrbisSaveDataEventType::SAVE_DATA_MEMORY_SYNC); + return Error::OK; } diff --git a/src/emulator.cpp b/src/emulator.cpp index 97215c06f..d873b3462 100644 --- a/src/emulator.cpp +++ b/src/emulator.cpp @@ -33,6 +33,7 @@ #include "core/libraries/ngs2/ngs2.h" #include "core/libraries/np_trophy/np_trophy.h" #include "core/libraries/rtc/rtc.h" +#include "core/libraries/save_data/save_backup.h" #include "core/linker.h" #include "core/memory.h" #include "emulator.h" @@ -271,7 +272,7 @@ void Emulator::Run(const std::filesystem::path& file, const std::vector Date: Thu, 30 Jan 2025 00:09:11 -0800 Subject: [PATCH 92/99] sdl_window: Allow alternate face button keys on any system. (#2275) * sdl_window: Allow alternate face button keys on any system. * readme: Fix typo --- README.md | 55 ++++++++++++++++++++++++---------------------- src/sdl_window.cpp | 27 ++++++++--------------- 2 files changed, 38 insertions(+), 44 deletions(-) diff --git a/README.md b/README.md index fd40d2d63..89aed29b4 100644 --- a/README.md +++ b/README.md @@ -76,6 +76,9 @@ For more information on how to test, debug and report issues with the emulator o # Keyboard mapping +> [!NOTE] +> Some keyboards may also require you to hold the Fn key to use the F\* keys. Mac users should use the Command key instead of Control, and need to use Command+F11 for full screen to avoid conflicting with system key bindings. + | Button | Function | |-------------|-------------| F10 | FPS Counter @@ -86,32 +89,32 @@ F12 | Trigger RenderDoc Capture > [!NOTE] > Xbox and DualShock controllers work out of the box. -| Controller button | Keyboard equivelant | Mac alternative | -|-------------|-------------|--------------| -LEFT AXIS UP | W | | -LEFT AXIS DOWN | S | | -LEFT AXIS LEFT | A | | -LEFT AXIS RIGHT | D | | -RIGHT AXIS UP | I | | -RIGHT AXIS DOWN | K | | -RIGHT AXIS LEFT | J | | -RIGHT AXIS RIGHT | L | | -TRIANGLE | Numpad 8 | C | -CIRCLE | Numpad 6 | B | -CROSS | Numpad 2 | N | -SQUARE | Numpad 4 | V | -PAD UP | UP | | -PAD DOWN | DOWN | | -PAD LEFT | LEFT | | -PAD RIGHT | RIGHT | | -OPTIONS | RETURN | | -BACK BUTTON / TOUCH PAD | SPACE | | -L1 | Q | | -R1 | U | | -L2 | E | | -R2 | O | | -L3 | X | | -R3 | M | | +| Controller button | Keyboard equivalent | +|-------------|-------------| +LEFT AXIS UP | W | +LEFT AXIS DOWN | S | +LEFT AXIS LEFT | A | +LEFT AXIS RIGHT | D | +RIGHT AXIS UP | I | +RIGHT AXIS DOWN | K | +RIGHT AXIS LEFT | J | +RIGHT AXIS RIGHT | L | +TRIANGLE | Numpad 8 or C | +CIRCLE | Numpad 6 or B | +CROSS | Numpad 2 or N | +SQUARE | Numpad 4 or V | +PAD UP | UP | +PAD DOWN | DOWN | +PAD LEFT | LEFT | +PAD RIGHT | RIGHT | +OPTIONS | RETURN | +BACK BUTTON / TOUCH PAD | SPACE | +L1 | Q | +R1 | U | +L2 | E | +R2 | O | +L3 | X | +R3 | M | # Main team diff --git a/src/sdl_window.cpp b/src/sdl_window.cpp index d1fe6bbab..9b7617925 100644 --- a/src/sdl_window.cpp +++ b/src/sdl_window.cpp @@ -382,20 +382,6 @@ void WindowSDL::OnResize() { } void WindowSDL::OnKeyPress(const SDL_Event* event) { -#ifdef __APPLE__ - // Use keys that are more friendly for keyboards without a keypad. - // Once there are key binding options this won't be necessary. - constexpr SDL_Keycode CrossKey = SDLK_N; - constexpr SDL_Keycode CircleKey = SDLK_B; - constexpr SDL_Keycode SquareKey = SDLK_V; - constexpr SDL_Keycode TriangleKey = SDLK_C; -#else - constexpr SDL_Keycode CrossKey = SDLK_KP_2; - constexpr SDL_Keycode CircleKey = SDLK_KP_6; - constexpr SDL_Keycode SquareKey = SDLK_KP_4; - constexpr SDL_Keycode TriangleKey = SDLK_KP_8; -#endif - auto button = OrbisPadButtonDataOffset::None; Input::Axis axis = Input::Axis::AxisMax; int axisvalue = 0; @@ -414,16 +400,21 @@ void WindowSDL::OnKeyPress(const SDL_Event* event) { case SDLK_RIGHT: button = OrbisPadButtonDataOffset::Right; break; - case TriangleKey: + // Provide alternatives for face buttons for users without a numpad. + case SDLK_KP_8: + case SDLK_C: button = OrbisPadButtonDataOffset::Triangle; break; - case CircleKey: + case SDLK_KP_6: + case SDLK_B: button = OrbisPadButtonDataOffset::Circle; break; - case CrossKey: + case SDLK_KP_2: + case SDLK_N: button = OrbisPadButtonDataOffset::Cross; break; - case SquareKey: + case SDLK_KP_4: + case SDLK_V: button = OrbisPadButtonDataOffset::Square; break; case SDLK_RETURN: From d8b411429638b48db375c03682fd1bcc3efdfd11 Mon Sep 17 00:00:00 2001 From: Bhaal42 Date: Thu, 30 Jan 2025 09:25:29 +0100 Subject: [PATCH 93/99] Patch 1 (#2278) * Update fr.ts Corrected some typos * Update fr.ts forgot plural --- src/qt_gui/translations/fr.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/qt_gui/translations/fr.ts b/src/qt_gui/translations/fr.ts index 0f87b087b..250b8f3c3 100644 --- a/src/qt_gui/translations/fr.ts +++ b/src/qt_gui/translations/fr.ts @@ -373,7 +373,7 @@ toolBar - Bare d'outils + Barre d'outils Game List @@ -489,7 +489,7 @@ Game successfully installed at %1 - Jeu installé avec succès à %1 + Jeu installé avec succès dans %1 File doesn't appear to be a valid PKG file @@ -554,7 +554,7 @@ Show Game Size In List - Afficher la taille du jeu dans la liste + Afficher la taille des jeux dans la liste Show Splash @@ -945,7 +945,7 @@ Serial: - Série: + Numéro de série: Version: @@ -1164,7 +1164,7 @@ Serial - Série + Numéro de série Compatibility @@ -1361,4 +1361,4 @@ TB - \ No newline at end of file + From 132a9d7d357727ab7e16e974647890434dfcd0d6 Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Thu, 30 Jan 2025 01:38:34 -0800 Subject: [PATCH 94/99] externals: Update MoltenVK (#2280) Small fix for pipeline serialization from last change. --- externals/MoltenVK/MoltenVK | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/externals/MoltenVK/MoltenVK b/externals/MoltenVK/MoltenVK index aba997657..0c090001c 160000 --- a/externals/MoltenVK/MoltenVK +++ b/externals/MoltenVK/MoltenVK @@ -1 +1 @@ -Subproject commit aba997657b94d6de1794ebad36ce5634341252c7 +Subproject commit 0c090001cb42997031cfe43914340e2639944972 From 3a163002d712ba9a22e2d0fac09302de6f324c61 Mon Sep 17 00:00:00 2001 From: Missake212 Date: Thu, 30 Jan 2025 13:06:55 +0100 Subject: [PATCH 95/99] Update README.md (#2281) Lot of people seem to think that building is required to use shad, adding a little note in the README to redirect them to tabs where they can simply download it. --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index 89aed29b4..30efeb263 100644 --- a/README.md +++ b/README.md @@ -55,6 +55,9 @@ This project began as a fun project. Given our limited free time, it may take so # Building +> [!IMPORTANT] +> If you want to use shadPS4 to play your games, you don't have to follow the build instructions, you can simply download the emulator from either the [**release tab**](https://github.com/shadps4-emu/shadPS4/releases) or the [**action tab**](https://github.com/shadps4-emu/shadPS4/actions). + ## Windows Check the build instructions for [**Windows**](https://github.com/shadps4-emu/shadPS4/blob/main/documents/building-windows.md). From 19bbbf994c541e009fc88ab5366c8e21f27d8a49 Mon Sep 17 00:00:00 2001 From: Zaid Ismail <64991232+zaid-ismail031@users.noreply.github.com> Date: Thu, 30 Jan 2025 14:09:50 +0200 Subject: [PATCH 96/99] Fix game title sorting bug from Issue #2260 (#2284) * Fix alphabetical sorting bug caused by case-sensitive string comparisons in GameListFrame. * Fix bug with incorrect use of std::tolower. * Fix clang-format error. --------- Co-authored-by: Zaid Ismail --- src/qt_gui/game_list_frame.h | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/src/qt_gui/game_list_frame.h b/src/qt_gui/game_list_frame.h index 8c6fcb1e2..90d021093 100644 --- a/src/qt_gui/game_list_frame.h +++ b/src/qt_gui/game_list_frame.h @@ -3,6 +3,9 @@ #pragma once +#include // std::transform +#include // std::tolower + #include #include #include @@ -65,8 +68,12 @@ public: static bool CompareStringsAscending(GameInfo a, GameInfo b, int columnIndex) { switch (columnIndex) { - case 1: - return a.name < b.name; + case 1: { + std::string name_a = a.name, name_b = b.name; + std::transform(name_a.begin(), name_a.end(), name_a.begin(), ::tolower); + std::transform(name_b.begin(), name_b.end(), name_b.begin(), ::tolower); + return name_a < name_b; + } case 2: return a.compatibility.status < b.compatibility.status; case 3: @@ -90,8 +97,12 @@ public: static bool CompareStringsDescending(GameInfo a, GameInfo b, int columnIndex) { switch (columnIndex) { - case 1: - return a.name > b.name; + case 1: { + std::string name_a = a.name, name_b = b.name; + std::transform(name_a.begin(), name_a.end(), name_a.begin(), ::tolower); + std::transform(name_b.begin(), name_b.end(), name_b.begin(), ::tolower); + return name_a > name_b; + } case 2: return a.compatibility.status > b.compatibility.status; case 3: From c89c7e8fed8b296204a0175e0414b4c867a84a1c Mon Sep 17 00:00:00 2001 From: squidbus <175574877+squidbus@users.noreply.github.com> Date: Thu, 30 Jan 2025 09:17:03 -0800 Subject: [PATCH 97/99] cpu_patches: Always use AVX for certain patches. (#2274) --- src/core/cpu_patches.cpp | 39 ++++++++++++--------------------------- 1 file changed, 12 insertions(+), 27 deletions(-) diff --git a/src/core/cpu_patches.cpp b/src/core/cpu_patches.cpp index b812e5444..57d528a81 100644 --- a/src/core/cpu_patches.cpp +++ b/src/core/cpu_patches.cpp @@ -30,16 +30,6 @@ using namespace Xbyak::util; -#define MAYBE_AVX(OPCODE, ...) \ - [&] { \ - Cpu cpu; \ - if (cpu.has(Cpu::tAVX)) { \ - c.v##OPCODE(__VA_ARGS__); \ - } else { \ - c.OPCODE(__VA_ARGS__); \ - } \ - }() - namespace Core { static Xbyak::Reg ZydisToXbyakRegister(const ZydisRegister reg) { @@ -643,7 +633,7 @@ static void GenerateEXTRQ(const ZydisDecodedOperand* operands, Xbyak::CodeGenera ASSERT_MSG(length + index <= 64, "length + index must be less than or equal to 64."); // Get lower qword from xmm register - MAYBE_AVX(movq, scratch1, xmm_dst); + c.vmovq(scratch1, xmm_dst); if (index != 0) { c.shr(scratch1, index); @@ -656,7 +646,7 @@ static void GenerateEXTRQ(const ZydisDecodedOperand* operands, Xbyak::CodeGenera // Writeback to xmm register, extrq instruction says top 64-bits are undefined so we don't // care to preserve them - MAYBE_AVX(movq, xmm_dst, scratch1); + c.vmovq(xmm_dst, scratch1); c.pop(scratch2); c.pop(scratch1); @@ -690,7 +680,7 @@ static void GenerateEXTRQ(const ZydisDecodedOperand* operands, Xbyak::CodeGenera c.push(mask); // Construct the mask out of the length that resides in bottom 6 bits of source xmm - MAYBE_AVX(movq, scratch1, xmm_src); + c.vmovq(scratch1, xmm_src); c.mov(scratch2, scratch1); c.and_(scratch2, 0x3F); c.jz(length_zero); @@ -711,10 +701,10 @@ static void GenerateEXTRQ(const ZydisDecodedOperand* operands, Xbyak::CodeGenera c.and_(scratch1, 0x3F); c.mov(scratch2, scratch1); // cl now contains the shift amount - MAYBE_AVX(movq, scratch1, xmm_dst); + c.vmovq(scratch1, xmm_dst); c.shr(scratch1, cl); c.and_(scratch1, mask); - MAYBE_AVX(movq, xmm_dst, scratch1); + c.vmovq(xmm_dst, scratch1); c.pop(mask); c.pop(scratch2); @@ -765,8 +755,8 @@ static void GenerateINSERTQ(const ZydisDecodedOperand* operands, Xbyak::CodeGene ASSERT_MSG(length + index <= 64, "length + index must be less than or equal to 64."); - MAYBE_AVX(movq, scratch1, xmm_src); - MAYBE_AVX(movq, scratch2, xmm_dst); + c.vmovq(scratch1, xmm_src); + c.vmovq(scratch2, xmm_dst); c.mov(mask, mask_value); // src &= mask @@ -784,12 +774,7 @@ static void GenerateINSERTQ(const ZydisDecodedOperand* operands, Xbyak::CodeGene c.or_(scratch2, scratch1); // Insert scratch2 into low 64 bits of dst, upper 64 bits are unaffected - Cpu cpu; - if (cpu.has(Cpu::tAVX)) { - c.vpinsrq(xmm_dst, xmm_dst, scratch2, 0); - } else { - c.pinsrq(xmm_dst, scratch2, 0); - } + c.vpinsrq(xmm_dst, xmm_dst, scratch2, 0); c.pop(mask); c.pop(scratch2); @@ -816,7 +801,7 @@ static void GenerateINSERTQ(const ZydisDecodedOperand* operands, Xbyak::CodeGene c.push(mask); // Get upper 64 bits of src and copy it to mask and index - MAYBE_AVX(pextrq, index, xmm_src, 1); + c.vpextrq(index, xmm_src, 1); c.mov(mask, index); // When length is 0, set it to 64 @@ -839,7 +824,7 @@ static void GenerateINSERTQ(const ZydisDecodedOperand* operands, Xbyak::CodeGene c.and_(index, 0x3F); // src &= mask - MAYBE_AVX(movq, scratch1, xmm_src); + c.vmovq(scratch1, xmm_src); c.and_(scratch1, mask); // mask = ~(mask << index) @@ -851,12 +836,12 @@ static void GenerateINSERTQ(const ZydisDecodedOperand* operands, Xbyak::CodeGene c.shl(scratch1, cl); // dst = (dst & mask) | src - MAYBE_AVX(movq, scratch2, xmm_dst); + c.vmovq(scratch2, xmm_dst); c.and_(scratch2, mask); c.or_(scratch2, scratch1); // Upper 64 bits are undefined in insertq - MAYBE_AVX(movq, xmm_dst, scratch2); + c.vmovq(xmm_dst, scratch2); c.pop(mask); c.pop(index); From e805b9752097a5292a8c41ca7a5a6c27934a1b94 Mon Sep 17 00:00:00 2001 From: tomboylover93 <95257311+tomboylover93@users.noreply.github.com> Date: Thu, 30 Jan 2025 14:34:31 -0300 Subject: [PATCH 98/99] Add Vulkan debug options to the Debug tab (#2254) Co-authored-by: DanielSvoboda --- documents/building-linux.md | 2 +- src/common/config.cpp | 24 +- src/common/config.h | 9 +- src/emulator.cpp | 6 +- src/imgui/renderer/imgui_core.cpp | 4 +- src/imgui/renderer/texture_manager.cpp | 2 +- src/qt_gui/settings_dialog.cpp | 31 +- src/qt_gui/settings_dialog.ui | 286 ++++++++++++------ src/qt_gui/translations/ar.ts | 44 +++ src/qt_gui/translations/da_DK.ts | 44 +++ src/qt_gui/translations/de.ts | 44 +++ src/qt_gui/translations/el.ts | 44 +++ src/qt_gui/translations/en.ts | 47 ++- src/qt_gui/translations/es_ES.ts | 44 +++ src/qt_gui/translations/fa_IR.ts | 44 +++ src/qt_gui/translations/fi.ts | 44 +++ src/qt_gui/translations/fr.ts | 44 +++ src/qt_gui/translations/hu_HU.ts | 44 +++ src/qt_gui/translations/id.ts | 44 +++ src/qt_gui/translations/it.ts | 44 +++ src/qt_gui/translations/ja_JP.ts | 44 +++ src/qt_gui/translations/ko_KR.ts | 44 +++ src/qt_gui/translations/lt_LT.ts | 44 +++ src/qt_gui/translations/nb.ts | 44 +++ src/qt_gui/translations/nl.ts | 44 +++ src/qt_gui/translations/pl_PL.ts | 44 +++ src/qt_gui/translations/pt_BR.ts | 82 +++-- src/qt_gui/translations/ro_RO.ts | 44 +++ src/qt_gui/translations/ru_RU.ts | 44 +++ src/qt_gui/translations/sq.ts | 44 +++ src/qt_gui/translations/sv.ts | 44 +++ src/qt_gui/translations/tr_TR.ts | 44 +++ src/qt_gui/translations/uk_UA.ts | 44 +++ src/qt_gui/translations/vi_VN.ts | 44 +++ src/qt_gui/translations/zh_CN.ts | 44 +++ src/qt_gui/translations/zh_TW.ts | 44 +++ src/video_core/renderer_vulkan/vk_platform.h | 4 +- .../renderer_vulkan/vk_presenter.cpp | 14 +- .../renderer_vulkan/vk_rasterizer.cpp | 16 +- 39 files changed, 1518 insertions(+), 153 deletions(-) diff --git a/documents/building-linux.md b/documents/building-linux.md index 4aa66aac6..d9ae2e54c 100644 --- a/documents/building-linux.md +++ b/documents/building-linux.md @@ -29,7 +29,7 @@ sudo dnf install clang git cmake libatomic alsa-lib-devel pipewire-jack-audio-co sudo pacman -S base-devel clang git cmake sndio jack2 openal qt6-base qt6-declarative qt6-multimedia sdl2 vulkan-validation-layers ``` -**Note** : The `shadps4-git` AUR package is not maintained by any of the developers, and it uses the default compiler, which is often set to GCC. Use at your own discretion. +**Note**: The `shadps4-git` AUR package is not maintained by any of the developers, and it uses the default compiler, which is often set to GCC. Use at your own discretion. #### OpenSUSE diff --git a/src/common/config.cpp b/src/common/config.cpp index a57b6d35c..70b062951 100644 --- a/src/common/config.cpp +++ b/src/common/config.cpp @@ -267,18 +267,28 @@ bool vkValidationGpuEnabled() { return vkValidationGpu; } -bool vkCrashDiagnosticEnabled() { +bool getVkCrashDiagnosticEnabled() { return vkCrashDiagnostic; } -bool vkHostMarkersEnabled() { - // Forced on when crash diagnostic enabled. - return vkHostMarkers || vkCrashDiagnostic; +bool getVkHostMarkersEnabled() { + return vkHostMarkers; } -bool vkGuestMarkersEnabled() { - // Forced on when crash diagnostic enabled. - return vkGuestMarkers || vkCrashDiagnostic; +bool getVkGuestMarkersEnabled() { + return vkGuestMarkers; +} + +void setVkCrashDiagnosticEnabled(bool enable) { + vkCrashDiagnostic = enable; +} + +void setVkHostMarkersEnabled(bool enable) { + vkHostMarkers = enable; +} + +void setVkGuestMarkersEnabled(bool enable) { + vkGuestMarkers = enable; } bool getSeparateUpdateEnabled() { diff --git a/src/common/config.h b/src/common/config.h index 15937606e..356cf77fc 100644 --- a/src/common/config.h +++ b/src/common/config.h @@ -106,9 +106,12 @@ void setRdocEnabled(bool enable); bool vkValidationEnabled(); bool vkValidationSyncEnabled(); bool vkValidationGpuEnabled(); -bool vkCrashDiagnosticEnabled(); -bool vkHostMarkersEnabled(); -bool vkGuestMarkersEnabled(); +bool getVkCrashDiagnosticEnabled(); +bool getVkHostMarkersEnabled(); +bool getVkGuestMarkersEnabled(); +void setVkCrashDiagnosticEnabled(bool enable); +void setVkHostMarkersEnabled(bool enable); +void setVkGuestMarkersEnabled(bool enable); // Gui void setMainWindowGeometry(u32 x, u32 y, u32 w, u32 h); diff --git a/src/emulator.cpp b/src/emulator.cpp index d873b3462..81c4d814d 100644 --- a/src/emulator.cpp +++ b/src/emulator.cpp @@ -67,9 +67,9 @@ Emulator::Emulator() { LOG_INFO(Config, "Vulkan vkValidation: {}", Config::vkValidationEnabled()); LOG_INFO(Config, "Vulkan vkValidationSync: {}", Config::vkValidationSyncEnabled()); LOG_INFO(Config, "Vulkan vkValidationGpu: {}", Config::vkValidationGpuEnabled()); - LOG_INFO(Config, "Vulkan crashDiagnostics: {}", Config::vkCrashDiagnosticEnabled()); - LOG_INFO(Config, "Vulkan hostMarkers: {}", Config::vkHostMarkersEnabled()); - LOG_INFO(Config, "Vulkan guestMarkers: {}", Config::vkGuestMarkersEnabled()); + LOG_INFO(Config, "Vulkan crashDiagnostics: {}", Config::getVkCrashDiagnosticEnabled()); + LOG_INFO(Config, "Vulkan hostMarkers: {}", Config::getVkHostMarkersEnabled()); + LOG_INFO(Config, "Vulkan guestMarkers: {}", Config::getVkGuestMarkersEnabled()); LOG_INFO(Config, "Vulkan rdocEnable: {}", Config::isRdocEnabled()); // Create stdin/stdout/stderr diff --git a/src/imgui/renderer/imgui_core.cpp b/src/imgui/renderer/imgui_core.cpp index 26253822c..d9530dd70 100644 --- a/src/imgui/renderer/imgui_core.cpp +++ b/src/imgui/renderer/imgui_core.cpp @@ -208,7 +208,7 @@ void Render(const vk::CommandBuffer& cmdbuf, const vk::ImageView& image_view, return; } - if (Config::vkHostMarkersEnabled()) { + if (Config::getVkHostMarkersEnabled()) { cmdbuf.beginDebugUtilsLabelEXT(vk::DebugUtilsLabelEXT{ .pLabelName = "ImGui Render", }); @@ -233,7 +233,7 @@ void Render(const vk::CommandBuffer& cmdbuf, const vk::ImageView& image_view, cmdbuf.beginRendering(render_info); Vulkan::RenderDrawData(*draw_data, cmdbuf); cmdbuf.endRendering(); - if (Config::vkHostMarkersEnabled()) { + if (Config::getVkHostMarkersEnabled()) { cmdbuf.endDebugUtilsLabelEXT(); } } diff --git a/src/imgui/renderer/texture_manager.cpp b/src/imgui/renderer/texture_manager.cpp index d7516a3a5..e217cd130 100644 --- a/src/imgui/renderer/texture_manager.cpp +++ b/src/imgui/renderer/texture_manager.cpp @@ -152,7 +152,7 @@ void WorkerLoop() { g_job_list.pop_front(); g_job_list_mtx.unlock(); - if (Config::vkCrashDiagnosticEnabled()) { + if (Config::getVkCrashDiagnosticEnabled()) { // FIXME: Crash diagnostic hangs when building the command buffer here continue; } diff --git a/src/qt_gui/settings_dialog.cpp b/src/qt_gui/settings_dialog.cpp index b41fde745..802325126 100644 --- a/src/qt_gui/settings_dialog.cpp +++ b/src/qt_gui/settings_dialog.cpp @@ -285,6 +285,11 @@ SettingsDialog::SettingsDialog(std::span physical_devices, ui->vkValidationCheckBox->installEventFilter(this); ui->vkSyncValidationCheckBox->installEventFilter(this); ui->rdocCheckBox->installEventFilter(this); + ui->crashDiagnosticsCheckBox->installEventFilter(this); + ui->guestMarkersCheckBox->installEventFilter(this); + ui->hostMarkersCheckBox->installEventFilter(this); + ui->collectShaderCheckBox->installEventFilter(this); + ui->copyGPUBuffersCheckBox->installEventFilter(this); } } @@ -360,6 +365,15 @@ void SettingsDialog::LoadValuesFromConfig() { ui->vkSyncValidationCheckBox->setChecked( toml::find_or(data, "Vulkan", "validation_sync", false)); ui->rdocCheckBox->setChecked(toml::find_or(data, "Vulkan", "rdocEnable", false)); + ui->crashDiagnosticsCheckBox->setChecked( + toml::find_or(data, "Vulkan", "crashDiagnostic", false)); + ui->guestMarkersCheckBox->setChecked( + toml::find_or(data, "Vulkan", "guestMarkers", false)); + ui->hostMarkersCheckBox->setChecked(toml::find_or(data, "Vulkan", "hostMarkers", false)); + ui->copyGPUBuffersCheckBox->setChecked( + toml::find_or(data, "GPU", "copyGPUBuffers", false)); + ui->collectShaderCheckBox->setChecked( + toml::find_or(data, "Debug", "CollectShader", false)); ui->enableCompatibilityCheckBox->setChecked( toml::find_or(data, "General", "compatibilityEnabled", false)); ui->checkCompatibilityOnStartupCheckBox->setChecked( @@ -380,7 +394,7 @@ void SettingsDialog::LoadValuesFromConfig() { std::string chooseHomeTab = toml::find_or(data, "General", "chooseHomeTab", ""); ui->chooseHomeTabComboBox->setCurrentText(QString::fromStdString(chooseHomeTab)); - QStringList tabNames = {tr("General"), tr("Gui"), tr("Graphics"), tr("User"), + QStringList tabNames = {tr("General"), tr("GUI"), tr("Graphics"), tr("User"), tr("Input"), tr("Paths"), tr("Debug")}; QString chooseHomeTabQString = QString::fromStdString(chooseHomeTab); int indexTab = tabNames.indexOf(chooseHomeTabQString); @@ -551,6 +565,16 @@ void SettingsDialog::updateNoteTextEdit(const QString& elementName) { text = tr("vkSyncValidationCheckBox"); } else if (elementName == "rdocCheckBox") { text = tr("rdocCheckBox"); + } else if (elementName == "crashDiagnosticsCheckBox") { + text = tr("crashDiagnosticsCheckBox"); + } else if (elementName == "guestMarkersCheckBox") { + text = tr("guestMarkersCheckBox"); + } else if (elementName == "hostMarkersCheckBox") { + text = tr("hostMarkersCheckBox"); + } else if (elementName == "copyGPUBuffersCheckBox") { + text = tr("copyGPUBuffersCheckBox"); + } else if (elementName == "collectShaderCheckBox") { + text = tr("collectShaderCheckBox"); } ui->descriptionText->setText(text.replace("\\n", "\n")); @@ -604,6 +628,11 @@ void SettingsDialog::UpdateSettings() { Config::setVkValidation(ui->vkValidationCheckBox->isChecked()); Config::setVkSyncValidation(ui->vkSyncValidationCheckBox->isChecked()); Config::setRdocEnabled(ui->rdocCheckBox->isChecked()); + Config::setVkHostMarkersEnabled(ui->hostMarkersCheckBox->isChecked()); + Config::setVkGuestMarkersEnabled(ui->guestMarkersCheckBox->isChecked()); + Config::setVkCrashDiagnosticEnabled(ui->crashDiagnosticsCheckBox->isChecked()); + Config::setCollectShaderForDebug(ui->collectShaderCheckBox->isChecked()); + Config::setCopyGPUCmdBuffers(ui->copyGPUBuffersCheckBox->isChecked()); Config::setAutoUpdate(ui->updateCheckBox->isChecked()); Config::setUpdateChannel(ui->updateComboBox->currentText().toStdString()); Config::setChooseHomeTab(ui->chooseHomeTabComboBox->currentText().toStdString()); diff --git a/src/qt_gui/settings_dialog.ui b/src/qt_gui/settings_dialog.ui index 5da6a8198..4e7440af5 100644 --- a/src/qt_gui/settings_dialog.ui +++ b/src/qt_gui/settings_dialog.ui @@ -12,7 +12,7 @@ 0 0 970 - 600 + 750 @@ -74,7 +74,7 @@ 0 0 946 - 386 + 536 @@ -476,7 +476,7 @@ true - Gui + GUI @@ -484,7 +484,7 @@ 0 0 946 - 386 + 536 @@ -497,14 +497,14 @@ 0 - + 0 - + 0 0 @@ -530,7 +530,7 @@ Default tab when opening settings - + @@ -546,7 +546,7 @@ - Gui + GUI @@ -594,6 +594,18 @@ 0 + + + 0 + 100 + + + + + 16777215 + 16777215 + + 11 @@ -605,62 +617,16 @@ false - + Title Music false - - - - 10 - 80 - 416 - 29 - - - - - 0 - 0 - - - - Set the volume of the background music. - - - 100 - - - 10 - - - 20 - - - 50 - - - Qt::Orientation::Horizontal - - - false - - - false - - - QSlider::TickPosition::NoTicks - - - 10 - - - 10 - 22 + 9 + 30 416 26 @@ -675,45 +641,119 @@ Play title music - + - 10 - 54 - 416 - 20 + 0 + 50 + 431 + 47 - - - 0 - 0 - - - - - 16777215 - 16777215 - - - - Volume - + + + 9 + + + 9 + + + 9 + + + 9 + + + 9 + + + + + + 0 + 0 + + + + + 16777215 + 16777215 + + + + Volume + + + + + + + + 0 + 0 + + + + Set the volume of the background music. + + + 100 + + + 10 + + + 20 + + + 50 + + + Qt::Orientation::Horizontal + + + false + + + false + + + QSlider::TickPosition::NoTicks + + + 10 + + + + + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + - + 6 - 210 + 0 @@ -790,6 +830,19 @@ + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + @@ -810,7 +863,7 @@ 0 0 946 - 386 + 536 @@ -1054,10 +1107,10 @@ 0 0 946 - 386 + 536 - + @@ -1198,7 +1251,7 @@ 0 0 946 - 386 + 536 @@ -1482,7 +1535,7 @@ 0 0 946 - 386 + 536 @@ -1572,10 +1625,10 @@ 0 0 946 - 386 + 536 - + @@ -1585,7 +1638,7 @@ 0 - + @@ -1728,20 +1781,57 @@ - - - Qt::Orientation::Vertical + + + + 0 + 0 + - - QSizePolicy::Policy::MinimumExpanding + + Advanced - - - 0 - 0 - + + Qt::AlignmentFlag::AlignLeading|Qt::AlignmentFlag::AlignLeft|Qt::AlignmentFlag::AlignTop - + + + + + Enable Crash Diagnostics + + + + + + + Collect Shaders + + + + + + + Copy GPU Buffers + + + + + + + Host Debug Markers + + + + + + + Guest Debug Markers + + + + + diff --git a/src/qt_gui/translations/ar.ts b/src/qt_gui/translations/ar.ts index f7b93028a..617753ab8 100644 --- a/src/qt_gui/translations/ar.ts +++ b/src/qt_gui/translations/ar.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging RenderDoc تمكين تصحيح أخطاء + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update تحديث @@ -720,6 +740,10 @@ GUI Settings إعدادات الواجهة + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox تمكين تصحيح RenderDoc:\nإذا تم التمكين، سيوفر المحاكي توافقًا مع Renderdoc لالتقاط وتحليل الإطار الذي يتم عرضه حاليًا. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/da_DK.ts b/src/qt_gui/translations/da_DK.ts index 61d2f68bf..abde6ff72 100644 --- a/src/qt_gui/translations/da_DK.ts +++ b/src/qt_gui/translations/da_DK.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Enable RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Opdatering @@ -720,6 +740,10 @@ GUI Settings GUI-Indstillinger + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox Aktiver RenderDoc-fejlfinding:\nHvis aktiveret, giver det emulatoren mulighed for kompatibilitet med Renderdoc til at fange og analysere det aktuelle gengivne billede. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/de.ts b/src/qt_gui/translations/de.ts index 9d99a7048..b8fa22881 100644 --- a/src/qt_gui/translations/de.ts +++ b/src/qt_gui/translations/de.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging RenderDoc-Debugging aktivieren + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Aktualisieren @@ -720,6 +740,10 @@ GUI Settings GUI-Einstellungen + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox RenderDoc-Debugging aktivieren:\nWenn aktiviert, bietet der Emulator Kompatibilität mit Renderdoc zur Erfassung und Analyse des aktuell gerenderten Frames. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/el.ts b/src/qt_gui/translations/el.ts index 66c3c07cd..828b99248 100644 --- a/src/qt_gui/translations/el.ts +++ b/src/qt_gui/translations/el.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Enable RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Ενημέρωση @@ -720,6 +740,10 @@ GUI Settings Ρυθμίσεις GUI + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox Ενεργοποίηση Καταγραφής RenderDoc:\nΌταν είναι ενεργοποιημένο, ο εξομοιωτής είναι συμβατός με το RenderDoc για τη λήψη και ανάλυση του τρέχοντος καρέ. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/en.ts b/src/qt_gui/translations/en.ts index 8b6c3c69f..7ad2f15c0 100644 --- a/src/qt_gui/translations/en.ts +++ b/src/qt_gui/translations/en.ts @@ -700,6 +700,27 @@ Enable RenderDoc Debugging Enable RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + + Update Update @@ -720,6 +741,10 @@ GUI Settings GUI Settings + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +953,26 @@ rdocCheckBox Enable RenderDoc Debugging:\nIf enabled, the emulator will provide compatibility with Renderdoc to allow capture and analysis of the currently rendered frame. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + saveDataBox Save Data Path:\nThe folder where game save data will be saved. @@ -1369,4 +1414,4 @@ TB - \ No newline at end of file + diff --git a/src/qt_gui/translations/es_ES.ts b/src/qt_gui/translations/es_ES.ts index 8f7a09b5d..8af34c042 100644 --- a/src/qt_gui/translations/es_ES.ts +++ b/src/qt_gui/translations/es_ES.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Habilitar depuración de RenderDoc + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Actualización @@ -720,6 +740,10 @@ GUI Settings Configuraciones de la Interfaz + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox Habilitar Depuración de RenderDoc:\nSi se habilita, el emulador proporcionará compatibilidad con Renderdoc para permitir la captura y análisis del fotograma actualmente renderizado. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/fa_IR.ts b/src/qt_gui/translations/fa_IR.ts index 043d782c2..16f6533b6 100644 --- a/src/qt_gui/translations/fa_IR.ts +++ b/src/qt_gui/translations/fa_IR.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update به‌روزرسانی @@ -720,6 +740,10 @@ GUI Settings تنظیمات رابط کاربری + + Title Music + Title Music + Disable Trophy Pop-ups غیرفعال کردن نمایش جوایز @@ -928,6 +952,26 @@ rdocCheckBox Enable RenderDoc Debugging:\nIf enabled, the emulator will provide compatibility with Renderdoc to allow capture and analysis of the currently rendered frame. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/fi.ts b/src/qt_gui/translations/fi.ts index 86f6a6d3c..7269b4125 100644 --- a/src/qt_gui/translations/fi.ts +++ b/src/qt_gui/translations/fi.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Ota Käyttöön RenderDoc Virheenkorjaus + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Päivitys @@ -720,6 +740,10 @@ GUI Settings GUI-asetukset + + Title Music + Title Music + Disable Trophy Pop-ups Poista Trophy Pop-upit Käytöstä @@ -928,6 +952,26 @@ rdocCheckBox Ota Käyttöön RenderDoc Virheenkorjaus:\nJos käytössä, emulaattori tarjoaa Renderdoc-yhteensopivuuden, mikä mahdollistaa renderöidyn kehyksen tallennuksen ja analysoinnin. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/fr.ts b/src/qt_gui/translations/fr.ts index 250b8f3c3..b93af15a6 100644 --- a/src/qt_gui/translations/fr.ts +++ b/src/qt_gui/translations/fr.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Activer le débogage RenderDoc + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Mise à jour @@ -720,6 +740,10 @@ GUI Settings Paramètres de l'interface + + Title Music + Title Music + Disable Trophy Pop-ups Désactiver les notifications de trophées @@ -928,6 +952,26 @@ rdocCheckBox Activer le débogage RenderDoc:\nS'il est activé, l'émulateur fournit une compatibilité avec Renderdoc, permettant d'enregistrer et d'analyser la trame rendue actuelle. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/hu_HU.ts b/src/qt_gui/translations/hu_HU.ts index fe71e8120..98491aa87 100644 --- a/src/qt_gui/translations/hu_HU.ts +++ b/src/qt_gui/translations/hu_HU.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging RenderDoc Debugolás Engedélyezése + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Frissítés @@ -720,6 +740,10 @@ GUI Settings GUI Beállítások + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox RenderDoc hibakeresés engedélyezése:\nHa engedélyezve van, az emulátor kompatibilitást biztosít a Renderdoc számára, hogy lehetővé tegye a jelenleg renderelt keret rögzítését és elemzését. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/id.ts b/src/qt_gui/translations/id.ts index acfde43a7..931244209 100644 --- a/src/qt_gui/translations/id.ts +++ b/src/qt_gui/translations/id.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Enable RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Pembaruan @@ -720,6 +740,10 @@ GUI Settings Pengaturan GUI + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox Aktifkan Debugging RenderDoc:\nJika diaktifkan, emulator akan menyediakan kompatibilitas dengan Renderdoc untuk memungkinkan pengambilan dan analisis bingkai yang sedang dirender. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/it.ts b/src/qt_gui/translations/it.ts index 93c6233a6..384272137 100644 --- a/src/qt_gui/translations/it.ts +++ b/src/qt_gui/translations/it.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Abilita RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Aggiornamento @@ -720,6 +740,10 @@ GUI Settings Impostazioni GUI + + Title Music + Title Music + Disable Trophy Pop-ups Disabilita Notifica Trofei @@ -928,6 +952,26 @@ rdocCheckBox Abilita Debugging RenderDoc:\nSe abilitato, l'emulatore fornirà compatibilità con Renderdoc per consentire la cattura e l'analisi del frame attualmente reso. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/ja_JP.ts b/src/qt_gui/translations/ja_JP.ts index 921af52bb..2aae35987 100644 --- a/src/qt_gui/translations/ja_JP.ts +++ b/src/qt_gui/translations/ja_JP.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging RenderDocデバッグを有効にする + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update 更新 @@ -720,6 +740,10 @@ GUI Settings GUI設定 + + Title Music + Title Music + Disable Trophy Pop-ups トロフィーのポップアップを無効化 @@ -928,6 +952,26 @@ rdocCheckBox RenderDocデバッグを有効にする:\n有効にすると、エミュレーターはRenderdocとの互換性を提供し、現在レンダリング中のフレームのキャプチャと分析を可能にします。 + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/ko_KR.ts b/src/qt_gui/translations/ko_KR.ts index 2491959a6..56e891214 100644 --- a/src/qt_gui/translations/ko_KR.ts +++ b/src/qt_gui/translations/ko_KR.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Enable RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Update @@ -720,6 +740,10 @@ GUI Settings GUI Settings + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox Enable RenderDoc Debugging:\nIf enabled, the emulator will provide compatibility with Renderdoc to allow capture and analysis of the currently rendered frame. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/lt_LT.ts b/src/qt_gui/translations/lt_LT.ts index 23a52e948..c73a43917 100644 --- a/src/qt_gui/translations/lt_LT.ts +++ b/src/qt_gui/translations/lt_LT.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Enable RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Atnaujinimas @@ -720,6 +740,10 @@ GUI Settings GUI Nustatymai + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox Įjungti RenderDoc derinimą:\nJei įjungta, emuliatorius suteiks suderinamumą su Renderdoc, kad būtų galima užfiksuoti ir analizuoti šiuo metu renderuojamą kadrą. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/nb.ts b/src/qt_gui/translations/nb.ts index 0b7d2699a..3e6f5fedd 100644 --- a/src/qt_gui/translations/nb.ts +++ b/src/qt_gui/translations/nb.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Aktiver RenderDoc feilretting + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Oppdatering @@ -720,6 +740,10 @@ GUI Settings Grensesnitt-innstillinger + + Title Music + Title Music + Disable Trophy Pop-ups Deaktiver trofé hurtigmeny @@ -928,6 +952,26 @@ rdocCheckBox Aktiver RenderDoc feilsøking:\nHvis aktivert, vil etterligneren gi kompatibilitet med Renderdoc for å tillate opptak og analyse av det nåværende gjengitte bildet. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/nl.ts b/src/qt_gui/translations/nl.ts index 1dabda8b4..95ac19ef3 100644 --- a/src/qt_gui/translations/nl.ts +++ b/src/qt_gui/translations/nl.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Enable RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Bijwerken @@ -720,6 +740,10 @@ GUI Settings GUI-Instellingen + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox RenderDoc foutopsporing inschakelen:\nAls ingeschakeld, biedt de emulator compatibiliteit met Renderdoc om de momenteel gerenderde frame vast te leggen en te analyseren. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/pl_PL.ts b/src/qt_gui/translations/pl_PL.ts index 85eb63bfb..89f165de2 100644 --- a/src/qt_gui/translations/pl_PL.ts +++ b/src/qt_gui/translations/pl_PL.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Włącz debugowanie RenderDoc + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Aktualizacja @@ -720,6 +740,10 @@ GUI Settings Ustawienia Interfejsu + + Title Music + Title Music + Disable Trophy Pop-ups Wyłącz wyskakujące okienka trofeów @@ -928,6 +952,26 @@ rdocCheckBox Włącz debugowanie RenderDoc:\nJeśli włączone, emulator zapewnia kompatybilność z Renderdoc, aby umożliwić nagrywanie i analizowanie aktualnie renderowanej klatki. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/pt_BR.ts b/src/qt_gui/translations/pt_BR.ts index fde1d3b63..0bce16dcf 100644 --- a/src/qt_gui/translations/pt_BR.ts +++ b/src/qt_gui/translations/pt_BR.ts @@ -538,7 +538,7 @@ Enable Fullscreen - Ativar Tela Cheia + Habilitar Tela Cheia Fullscreen Mode @@ -566,7 +566,7 @@ Enable Discord Rich Presence - Ativar Discord Rich Presence + Habilitar Discord Rich Presence Username @@ -574,7 +574,7 @@ Trophy Key - Trophy Key + Chave de Troféu Trophy @@ -582,7 +582,7 @@ Logger - Registro + Registro-Log Log Type @@ -594,7 +594,7 @@ Open Log Location - Abrir local do log + Abrir local do registro Input @@ -658,11 +658,11 @@ Enable Shaders Dumping - Ativar Dumping de Shaders + Habilitar Dumping de Shaders Enable NULL GPU - Ativar GPU NULA + Habilitar GPU NULA Paths @@ -686,19 +686,39 @@ Enable Debug Dumping - Ativar Depuração de Dumping + Habilitar Depuração de Dumping Enable Vulkan Validation Layers - Ativar Camadas de Validação do Vulkan + Habilitar Camadas de Validação do Vulkan Enable Vulkan Synchronization Validation - Ativar Validação de Sincronização do Vulkan + Habilitar Validação de Sincronização do Vulkan Enable RenderDoc Debugging - Ativar Depuração por RenderDoc + Habilitar Depuração do RenderDoc + + + Enable Crash Diagnostics + Habilitar Diagnóstico de Falhas + + + Collect Shaders + Coletar Shaders + + + Copy GPU Buffers + Copiar Buffers de GPU + + + Host Debug Markers + Marcadores de Depuração do Host + + + Guest Debug Markers + Marcadores de Depuração do Convidado Update @@ -720,6 +740,10 @@ GUI Settings Configurações da Interface + + Title Music + Música no Menu + Disable Trophy Pop-ups Desabilitar Pop-ups dos Troféus @@ -782,7 +806,7 @@ fullscreenCheckBox - Ativar Tela Cheia:\nAltera a janela do jogo para o modo tela cheia.\nIsso pode ser alterado pressionando a tecla F11. + Habilitar Tela Cheia:\nAltera a janela do jogo para o modo tela cheia.\nIsso pode ser alterado pressionando a tecla F11. separateUpdatesCheckBox @@ -798,7 +822,7 @@ discordRPCCheckbox - Ativar Discord Rich Presence:\nExibe o ícone do emulador e informações relevantes no seu perfil do Discord. + Habilitar Discord Rich Presence:\nExibe o ícone do emulador e informações relevantes no seu perfil do Discord. userName @@ -898,11 +922,11 @@ dumpShadersCheckBox - Ativar Dumping de Shaders:\nArmazena os shaders do jogo em uma pasta durante a renderização para fins de depuração técnica. + Habilitar Dumping de Shaders:\nArmazena os shaders do jogo em uma pasta durante a renderização para fins de depuração técnica. nullGpuCheckBox - Ativar GPU NULA:\nDesativa a renderização do jogo para fins de depuração técnica, como se não houvesse nenhuma placa gráfica. + Habilitar GPU NULA:\nDesativa a renderização do jogo para fins de depuração técnica, como se não houvesse nenhuma placa gráfica. gameFoldersBox @@ -918,19 +942,39 @@ debugDump - Ativar Depuração de Dumping:\nArmazena os símbolos de importação e exportação e as informações do cabeçalho do arquivo do programa PS4 atual em um diretório. + Habilitar Depuração de Dumping:\nArmazena os símbolos de importação e exportação e as informações do cabeçalho do arquivo do programa PS4 atual em um diretório. vkValidationCheckBox - Ativar Camadas de Validação do Vulkan:\nAtiva um sistema que valida o estado do renderizador Vulkan e registra informações sobre seu estado interno.\nIsso diminui o desempenho e pode alterar o comportamento da emulação. + Habilitar Camadas de Validação do Vulkan:\nAtiva um sistema que valida o estado do renderizador Vulkan e registra informações sobre seu estado interno.\nIsso diminui o desempenho e pode alterar o comportamento da emulação. vkSyncValidationCheckBox - Ativar Validação de Sincronização do Vulkan:\nAtiva um sistema que valida o agendamento de tarefas de renderização Vulkan.\nIsso diminui o desempenho e pode alterar o comportamento da emulação. + Habilitar Validação de Sincronização do Vulkan:\nAtiva um sistema que valida o agendamento de tarefas de renderização Vulkan.\nIsso diminui o desempenho e pode alterar o comportamento da emulação. rdocCheckBox - Ativar depuração por RenderDoc:\nSe ativado, permite que o emulador tenha compatibilidade com RenderDoc para gravação e análise do quadro renderizado atual. + Habilitar Depuração por RenderDoc:\nSe ativado, permite que o emulador tenha compatibilidade com RenderDoc para gravação e análise do quadro renderizado atual. + + + collectShaderCheckBox + Coletar Shaders:\nVocê precisa habilitar isso para editar shaders com o menu de depuração (Ctrl + F10). + + + crashDiagnosticsCheckBox + Diagnósticos de Falha:\nCria um arquivo .yaml com informações sobre o estado do Vulkan no momento da falha.\nÚtil para depurar erros de 'Device lost'. Se você tiver isso habilitado, você deve habilitar os Marcadores de Depuração de Host e de Convidado.\nNão funciona em GPUs da Intel.\nVocê precisa ter as Camadas de Validação Vulkan habilitadas e o SDK do Vulkan para que isso funcione. + + + copyGPUBuffersCheckBox + Copiar Buffers de GPU:\nContorna condições de corrida envolvendo envios de GPU.\nPode ou não ajudar com travamentos do PM4 tipo 0. + + + hostMarkersCheckBox + Marcadores de Depuração de Host:\nInsere informações do lado do emulador, como marcadores para comandos AMDGPU específicos em torno de comandos Vulkan, além de fornecer nomes de depuração aos recursos.\nSe isso estiver habilitado, você deve habilitar o "Diagnóstico de Falha".\nÚtil para programas como o RenderDoc. + + + guestMarkersCheckBox + Marcadores de Depuração de Convidado:\nInsere quaisquer marcadores de depuração que o próprio jogo adicionou ao buffer de comando.\nSe isso estiver habilitado, você deve habilitar "Diagnóstico de Falha".\nÚtil para programas como o RenderDoc. diff --git a/src/qt_gui/translations/ro_RO.ts b/src/qt_gui/translations/ro_RO.ts index 9791a7682..f60de9823 100644 --- a/src/qt_gui/translations/ro_RO.ts +++ b/src/qt_gui/translations/ro_RO.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Enable RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Actualizare @@ -720,6 +740,10 @@ GUI Settings Setări GUI + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox Activează depanarea RenderDoc:\nDacă este activat, emulatorul va oferi compatibilitate cu Renderdoc pentru a permite capturarea și analiza cadrului redat în prezent. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/ru_RU.ts b/src/qt_gui/translations/ru_RU.ts index 0fddb1e7f..270396a6d 100644 --- a/src/qt_gui/translations/ru_RU.ts +++ b/src/qt_gui/translations/ru_RU.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Включить отладку RenderDoc + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Обновление @@ -720,6 +740,10 @@ GUI Settings Интерфейс + + Title Music + Title Music + Disable Trophy Pop-ups Отключить уведомления о трофеях @@ -928,6 +952,26 @@ rdocCheckBox Включить отладку RenderDoc:\nЕсли включено, эмулятор обеспечит совместимость с Renderdoc, позволяя захватывать и анализировать текущие кадры во время рендеринга. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/sq.ts b/src/qt_gui/translations/sq.ts index 15c18d2f6..1d37fa9c3 100644 --- a/src/qt_gui/translations/sq.ts +++ b/src/qt_gui/translations/sq.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Aktivizo Korrigjimin RenderDoc + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Përditëso @@ -720,6 +740,10 @@ GUI Settings Cilësimet e GUI-së + + Title Music + Title Music + Disable Trophy Pop-ups Çaktivizo njoftimet për Trofetë @@ -928,6 +952,26 @@ rdocCheckBox Aktivizo korrigjimin RenderDoc:\nNëse aktivizohet, emulatori do të ofrojë pajtueshmëri me Renderdoc për të lejuar kapjen dhe analizën e pamjes të pasqyruar në moment. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/sv.ts b/src/qt_gui/translations/sv.ts index e17944f12..c5fbce991 100644 --- a/src/qt_gui/translations/sv.ts +++ b/src/qt_gui/translations/sv.ts @@ -1188,6 +1188,26 @@ Enable RenderDoc Debugging Aktivera RenderDoc-felsökning + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Uppdatera @@ -1208,6 +1228,10 @@ GUI Settings Gränssnittsinställningar + + Title Music + Title Music + Disable Trophy Pop-ups Inaktivera popup för troféer @@ -1408,6 +1432,26 @@ rdocCheckBox Aktivera RenderDoc-felsökning:\nOm aktiverad kommer emulatorn att tillhandahålla kompatibilitet med Renderdoc för att tillåta fångst och analys för aktuell renderad bildruta + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + Release Release diff --git a/src/qt_gui/translations/tr_TR.ts b/src/qt_gui/translations/tr_TR.ts index a2368bfee..12794e088 100644 --- a/src/qt_gui/translations/tr_TR.ts +++ b/src/qt_gui/translations/tr_TR.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging RenderDoc Hata Ayıklamayı Etkinleştir + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Güncelle @@ -720,6 +740,10 @@ GUI Settings GUI Ayarları + + Title Music + Title Music + Disable Trophy Pop-ups Kupa Açılır Pencerelerini Devre Dışı Bırak @@ -928,6 +952,26 @@ rdocCheckBox RenderDoc Hata Ayıklamayı Etkinleştir:\nEğer etkinleştirilirse, emülatör mevcut render edilmiş çerçeveyi yakalamak ve analiz etmek için Renderdoc ile uyumluluk sunar. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/uk_UA.ts b/src/qt_gui/translations/uk_UA.ts index 720ad5b99..e80d363d3 100644 --- a/src/qt_gui/translations/uk_UA.ts +++ b/src/qt_gui/translations/uk_UA.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Увімкнути налагодження RenderDoc + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Оновлення @@ -720,6 +740,10 @@ GUI Settings Інтерфейс + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox Увімкнути налагодження RenderDoc:\nЯкщо увімкнено, емулятор забезпечить сумісність із Renderdoc, даючи змогу захоплювати й аналізувати поточні кадри під час рендерингу. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/vi_VN.ts b/src/qt_gui/translations/vi_VN.ts index a81630fad..32841af81 100644 --- a/src/qt_gui/translations/vi_VN.ts +++ b/src/qt_gui/translations/vi_VN.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Enable RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update Cập nhật @@ -720,6 +740,10 @@ GUI Settings Cài đặt GUI + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox Bật gỡ lỗi RenderDoc:\nNếu được kích hoạt, trình giả lập sẽ cung cấp tính tương thích với Renderdoc để cho phép bắt và phân tích khung hình hiện tại đang được kết xuất. + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/qt_gui/translations/zh_CN.ts b/src/qt_gui/translations/zh_CN.ts index 16ae03f94..00f4337c0 100644 --- a/src/qt_gui/translations/zh_CN.ts +++ b/src/qt_gui/translations/zh_CN.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging 启用 RenderDoc 调试 + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update 更新 @@ -720,6 +740,10 @@ GUI Settings 界面设置 + + Title Music + Title Music + Disable Trophy Pop-ups 禁止弹出奖杯 @@ -928,6 +952,26 @@ rdocCheckBox 启用 RenderDoc 调试:\n启用后模拟器将提供与 Renderdoc 的兼容性,允许在渲染过程中捕获和分析当前渲染的帧。 + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + saveDataBox 存档数据路径:\n保存游戏存档数据的目录。 diff --git a/src/qt_gui/translations/zh_TW.ts b/src/qt_gui/translations/zh_TW.ts index 9f6758797..c18e173e4 100644 --- a/src/qt_gui/translations/zh_TW.ts +++ b/src/qt_gui/translations/zh_TW.ts @@ -700,6 +700,26 @@ Enable RenderDoc Debugging Enable RenderDoc Debugging + + Enable Crash Diagnostics + Enable Crash Diagnostics + + + Collect Shaders + Collect Shaders + + + Copy GPU Buffers + Copy GPU Buffers + + + Host Debug Markers + Host Debug Markers + + + Guest Debug Markers + Guest Debug Markers + Update 更新 @@ -720,6 +740,10 @@ GUI Settings 介面設置 + + Title Music + Title Music + Disable Trophy Pop-ups Disable Trophy Pop-ups @@ -928,6 +952,26 @@ rdocCheckBox 啟用RenderDoc調試:\n如果啟用,模擬器將提供與Renderdoc的兼容性,以允許捕獲和分析當前渲染的幀。 + + collectShaderCheckBox + Collect Shaders:\nYou need this enabled to edit shaders with the debug menu (Ctrl + F10). + + + crashDiagnosticsCheckBox + Crash Diagnostics:\nCreates a .yaml file with info about the Vulkan state at the time of crashing.\nUseful for debugging 'Device lost' errors. If you have this enabled, you should enable Host AND Guest Debug Markers.\nDoes not work on Intel GPUs.\nYou need Vulkan Validation Layers enabled and the Vulkan SDK for this to work. + + + copyGPUBuffersCheckBox + Copy GPU Buffers:\nGets around race conditions involving GPU submits.\nMay or may not help with PM4 type 0 crashes. + + + hostMarkersCheckBox + Host Debug Markers:\nInserts emulator-side information like markers for specific AMDGPU commands around Vulkan commands, as well as giving resources debug names.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + + + guestMarkersCheckBox + Guest Debug Markers:\nInserts any debug markers the game itself has added to the command buffer.\nIf you have this enabled, you should enable Crash Diagnostics.\nUseful for programs like RenderDoc. + CheatsPatches diff --git a/src/video_core/renderer_vulkan/vk_platform.h b/src/video_core/renderer_vulkan/vk_platform.h index d05d12997..4e9587e46 100644 --- a/src/video_core/renderer_vulkan/vk_platform.h +++ b/src/video_core/renderer_vulkan/vk_platform.h @@ -33,7 +33,7 @@ concept VulkanHandleType = vk::isVulkanHandleType::value; template void SetObjectName(vk::Device device, const HandleType& handle, std::string_view debug_name) { - if (!Config::vkHostMarkersEnabled()) { + if (!Config::getVkHostMarkersEnabled()) { return; } const vk::DebugUtilsObjectNameInfoEXT name_info = { @@ -50,7 +50,7 @@ void SetObjectName(vk::Device device, const HandleType& handle, std::string_view template void SetObjectName(vk::Device device, const HandleType& handle, const char* format, const Args&... args) { - if (!Config::vkHostMarkersEnabled()) { + if (!Config::getVkHostMarkersEnabled()) { return; } const std::string debug_name = fmt::vformat(format, fmt::make_format_args(args...)); diff --git a/src/video_core/renderer_vulkan/vk_presenter.cpp b/src/video_core/renderer_vulkan/vk_presenter.cpp index 35ab4318a..c2be1c3e8 100644 --- a/src/video_core/renderer_vulkan/vk_presenter.cpp +++ b/src/video_core/renderer_vulkan/vk_presenter.cpp @@ -294,7 +294,7 @@ void Presenter::CreatePostProcessPipeline() { Presenter::Presenter(Frontend::WindowSDL& window_, AmdGpu::Liverpool* liverpool_) : window{window_}, liverpool{liverpool_}, instance{window, Config::getGpuId(), Config::vkValidationEnabled(), - Config::vkCrashDiagnosticEnabled()}, + Config::getVkCrashDiagnosticEnabled()}, draw_scheduler{instance}, present_scheduler{instance}, flip_scheduler{instance}, swapchain{instance, window}, rasterizer{std::make_unique(instance, draw_scheduler, liverpool)}, @@ -467,7 +467,7 @@ bool Presenter::ShowSplash(Frame* frame /*= nullptr*/) { draw_scheduler.EndRendering(); const auto cmdbuf = draw_scheduler.CommandBuffer(); - if (Config::vkHostMarkersEnabled()) { + if (Config::getVkHostMarkersEnabled()) { cmdbuf.beginDebugUtilsLabelEXT(vk::DebugUtilsLabelEXT{ .pLabelName = "ShowSplash", }); @@ -541,7 +541,7 @@ bool Presenter::ShowSplash(Frame* frame /*= nullptr*/) { .pImageMemoryBarriers = &post_barrier, }); - if (Config::vkHostMarkersEnabled()) { + if (Config::getVkHostMarkersEnabled()) { cmdbuf.endDebugUtilsLabelEXT(); } @@ -573,7 +573,7 @@ Frame* Presenter::PrepareFrameInternal(VideoCore::ImageId image_id, bool is_eop) auto& scheduler = is_eop ? draw_scheduler : flip_scheduler; scheduler.EndRendering(); const auto cmdbuf = scheduler.CommandBuffer(); - if (Config::vkHostMarkersEnabled()) { + if (Config::getVkHostMarkersEnabled()) { const auto label = fmt::format("PrepareFrameInternal:{}", image_id.index); cmdbuf.beginDebugUtilsLabelEXT(vk::DebugUtilsLabelEXT{ .pLabelName = label.c_str(), @@ -704,7 +704,7 @@ Frame* Presenter::PrepareFrameInternal(VideoCore::ImageId image_id, bool is_eop) .pImageMemoryBarriers = &post_barrier, }); - if (Config::vkHostMarkersEnabled()) { + if (Config::getVkHostMarkersEnabled()) { cmdbuf.endDebugUtilsLabelEXT(); } @@ -755,7 +755,7 @@ void Presenter::Present(Frame* frame, bool is_reusing_frame) { auto& scheduler = present_scheduler; const auto cmdbuf = scheduler.CommandBuffer(); - if (Config::vkHostMarkersEnabled()) { + if (Config::getVkHostMarkersEnabled()) { cmdbuf.beginDebugUtilsLabelEXT(vk::DebugUtilsLabelEXT{ .pLabelName = "Present", }); @@ -857,7 +857,7 @@ void Presenter::Present(Frame* frame, bool is_reusing_frame) { } } - if (Config::vkHostMarkersEnabled()) { + if (Config::getVkHostMarkersEnabled()) { cmdbuf.endDebugUtilsLabelEXT(); } diff --git a/src/video_core/renderer_vulkan/vk_rasterizer.cpp b/src/video_core/renderer_vulkan/vk_rasterizer.cpp index 7c77f2519..fde87fcfb 100644 --- a/src/video_core/renderer_vulkan/vk_rasterizer.cpp +++ b/src/video_core/renderer_vulkan/vk_rasterizer.cpp @@ -1239,8 +1239,8 @@ void Rasterizer::UpdateViewportScissorState(const GraphicsPipeline& pipeline) { } void Rasterizer::ScopeMarkerBegin(const std::string_view& str, bool from_guest) { - if ((from_guest && !Config::vkGuestMarkersEnabled()) || - (!from_guest && !Config::vkHostMarkersEnabled())) { + if ((from_guest && !Config::getVkGuestMarkersEnabled()) || + (!from_guest && !Config::getVkHostMarkersEnabled())) { return; } const auto cmdbuf = scheduler.CommandBuffer(); @@ -1250,8 +1250,8 @@ void Rasterizer::ScopeMarkerBegin(const std::string_view& str, bool from_guest) } void Rasterizer::ScopeMarkerEnd(bool from_guest) { - if ((from_guest && !Config::vkGuestMarkersEnabled()) || - (!from_guest && !Config::vkHostMarkersEnabled())) { + if ((from_guest && !Config::getVkGuestMarkersEnabled()) || + (!from_guest && !Config::getVkHostMarkersEnabled())) { return; } const auto cmdbuf = scheduler.CommandBuffer(); @@ -1259,8 +1259,8 @@ void Rasterizer::ScopeMarkerEnd(bool from_guest) { } void Rasterizer::ScopedMarkerInsert(const std::string_view& str, bool from_guest) { - if ((from_guest && !Config::vkGuestMarkersEnabled()) || - (!from_guest && !Config::vkHostMarkersEnabled())) { + if ((from_guest && !Config::getVkGuestMarkersEnabled()) || + (!from_guest && !Config::getVkHostMarkersEnabled())) { return; } const auto cmdbuf = scheduler.CommandBuffer(); @@ -1271,8 +1271,8 @@ void Rasterizer::ScopedMarkerInsert(const std::string_view& str, bool from_guest void Rasterizer::ScopedMarkerInsertColor(const std::string_view& str, const u32 color, bool from_guest) { - if ((from_guest && !Config::vkGuestMarkersEnabled()) || - (!from_guest && !Config::vkHostMarkersEnabled())) { + if ((from_guest && !Config::getVkGuestMarkersEnabled()) || + (!from_guest && !Config::getVkHostMarkersEnabled())) { return; } const auto cmdbuf = scheduler.CommandBuffer(); From ad5bd91a13ec891395efdacfbc00cd78c2a58ea6 Mon Sep 17 00:00:00 2001 From: DanielSvoboda Date: Thu, 30 Jan 2025 15:34:42 -0300 Subject: [PATCH 99/99] Fix game title sorting (#2286) * Fix game title sorting * fix * fix * fix --- src/qt_gui/game_list_frame.cpp | 9 +++++++-- src/qt_gui/game_list_frame.h | 2 +- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/qt_gui/game_list_frame.cpp b/src/qt_gui/game_list_frame.cpp index 9753f511b..8255c0daf 100644 --- a/src/qt_gui/game_list_frame.cpp +++ b/src/qt_gui/game_list_frame.cpp @@ -69,7 +69,7 @@ GameListFrame::GameListFrame(std::shared_ptr game_info_get, ListSortedAsc = true; } this->clearContents(); - PopulateGameList(); + PopulateGameList(false); }); connect(this, &QTableWidget::customContextMenuRequested, this, [=, this](const QPoint& pos) { @@ -103,7 +103,7 @@ void GameListFrame::PlayBackgroundMusic(QTableWidgetItem* item) { BackgroundMusicPlayer::getInstance().playMusic(snd0path); } -void GameListFrame::PopulateGameList() { +void GameListFrame::PopulateGameList(bool isInitialPopulation) { // Do not show status column if it is not enabled this->setColumnHidden(2, !Config::getCompatibilityEnabled()); this->setColumnHidden(6, !Config::GetLoadGameSizeEnabled()); @@ -111,6 +111,11 @@ void GameListFrame::PopulateGameList() { this->setRowCount(m_game_info->m_games.size()); ResizeIcons(icon_size); + if (isInitialPopulation) { + SortNameAscending(1); // Column 1 = Name + ResizeIcons(icon_size); + } + for (int i = 0; i < m_game_info->m_games.size(); i++) { SetTableItem(i, 1, QString::fromStdString(m_game_info->m_games[i].name)); SetTableItem(i, 3, QString::fromStdString(m_game_info->m_games[i].serial)); diff --git a/src/qt_gui/game_list_frame.h b/src/qt_gui/game_list_frame.h index 90d021093..7e37c4ea7 100644 --- a/src/qt_gui/game_list_frame.h +++ b/src/qt_gui/game_list_frame.h @@ -46,7 +46,7 @@ private: bool ListSortedAsc = true; public: - void PopulateGameList(); + void PopulateGameList(bool isInitialPopulation = true); void ResizeIcons(int iconSize); QImage backgroundImage;