From f49abee7e24605944240a6e4b6a9ed1130df2218 Mon Sep 17 00:00:00 2001 From: pineappleEA Date: Thu, 28 Sep 2023 17:32:20 +0200 Subject: [PATCH] early-access version 3901 --- README.md | 2 +- src/android/app/src/main/jni/native.cpp | 4 ---- src/core/hle/service/am/applets/applet_mii_edit.cpp | 2 ++ src/core/hle/service/mii/mii_database_manager.cpp | 2 +- src/core/hle/service/mii/types/char_info.cpp | 2 +- src/core/hle/service/mii/types/core_data.cpp | 2 +- src/core/hle/service/nfc/common/device.cpp | 2 +- src/video_core/renderer_vulkan/vk_query_cache.cpp | 6 ++++-- src/yuzu/main.cpp | 11 ++++------- src/yuzu/main.h | 2 +- 10 files changed, 16 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index d401f890d..bd8a75a6b 100755 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ yuzu emulator early access ============= -This is the source code for early-access 3900. +This is the source code for early-access 3901. ## Legal Notice diff --git a/src/android/app/src/main/jni/native.cpp b/src/android/app/src/main/jni/native.cpp index 9fa082dd5..9cf71680c 100755 --- a/src/android/app/src/main/jni/native.cpp +++ b/src/android/app/src/main/jni/native.cpp @@ -141,10 +141,6 @@ public: if (nsp->IsExtractedType()) { return InstallError; } - } else if (file_extension == "xci") { - jconst xci = - std::make_shared(m_vfs->OpenFile(filename, FileSys::Mode::Read)); - nsp = xci->GetSecurePartitionNSP(); } else { return ErrorFilenameExtension; } diff --git a/src/core/hle/service/am/applets/applet_mii_edit.cpp b/src/core/hle/service/am/applets/applet_mii_edit.cpp index 6e4e8d61d..a3fef2d92 100755 --- a/src/core/hle/service/am/applets/applet_mii_edit.cpp +++ b/src/core/hle/service/am/applets/applet_mii_edit.cpp @@ -145,6 +145,8 @@ void MiiEdit::MiiEditOutput(MiiEditResult result, s32 index) { .index{index}, }; + LOG_INFO(Input, "called, result={}, index={}", result, index); + std::vector out_data(sizeof(MiiEditAppletOutput)); std::memcpy(out_data.data(), &applet_output, sizeof(MiiEditAppletOutput)); diff --git a/src/core/hle/service/mii/mii_database_manager.cpp b/src/core/hle/service/mii/mii_database_manager.cpp index c39898594..0080b6705 100755 --- a/src/core/hle/service/mii/mii_database_manager.cpp +++ b/src/core/hle/service/mii/mii_database_manager.cpp @@ -168,7 +168,7 @@ Result DatabaseManager::FindIndex(s32& out_index, const Common::UUID& create_id, return ResultSuccess; } - for (std::size_t i = 0; i <= index; ++i) { + for (std::size_t i = 0; i < index; ++i) { if (database.Get(i).IsSpecial()) { continue; } diff --git a/src/core/hle/service/mii/types/char_info.cpp b/src/core/hle/service/mii/types/char_info.cpp index c82186c73..e90124af4 100755 --- a/src/core/hle/service/mii/types/char_info.cpp +++ b/src/core/hle/service/mii/types/char_info.cpp @@ -37,7 +37,7 @@ void CharInfo::SetFromStoreData(const StoreData& store_data) { eyebrow_aspect = store_data.GetEyebrowAspect(); eyebrow_rotate = store_data.GetEyebrowRotate(); eyebrow_x = store_data.GetEyebrowX(); - eyebrow_y = store_data.GetEyebrowY(); + eyebrow_y = store_data.GetEyebrowY() + 3; nose_type = store_data.GetNoseType(); nose_scale = store_data.GetNoseScale(); nose_y = store_data.GetNoseY(); diff --git a/src/core/hle/service/mii/types/core_data.cpp b/src/core/hle/service/mii/types/core_data.cpp index 1068031e3..970c748ca 100755 --- a/src/core/hle/service/mii/types/core_data.cpp +++ b/src/core/hle/service/mii/types/core_data.cpp @@ -113,7 +113,7 @@ void CoreData::BuildRandom(Age age, Gender gender, Race race) { .values[MiiUtil::GetRandomValue(eyebrow_type_info.values_count)]); const auto eyebrow_rotate_1{race == Race::Asian ? 6 : 0}; - const auto eyebrow_y{race == Race::Asian ? 9 : 10}; + const auto eyebrow_y{race == Race::Asian ? 6 : 7}; const auto eyebrow_rotate_offset{32 - RawData::EyebrowRotateLookup[eyebrow_rotate_1] + 6}; const auto eyebrow_rotate{ 32 - RawData::EyebrowRotateLookup[static_cast(data.eyebrow_type.Value())]}; diff --git a/src/core/hle/service/nfc/common/device.cpp b/src/core/hle/service/nfc/common/device.cpp index 05951d8cb..68c407f81 100755 --- a/src/core/hle/service/nfc/common/device.cpp +++ b/src/core/hle/service/nfc/common/device.cpp @@ -1374,7 +1374,7 @@ NFP::AmiiboName NfcDevice::GetAmiiboName(const NFP::AmiiboSettings& settings) co // Convert from utf16 to utf8 const auto amiibo_name_utf8 = Common::UTF16ToUTF8(settings_amiibo_name.data()); - memcpy(amiibo_name.data(), amiibo_name_utf8.data(), amiibo_name_utf8.size() - 1); + memcpy(amiibo_name.data(), amiibo_name_utf8.data(), amiibo_name_utf8.size()); return amiibo_name; } diff --git a/src/video_core/renderer_vulkan/vk_query_cache.cpp b/src/video_core/renderer_vulkan/vk_query_cache.cpp index 06f5d3af0..13cb4b28e 100755 --- a/src/video_core/renderer_vulkan/vk_query_cache.cpp +++ b/src/video_core/renderer_vulkan/vk_query_cache.cpp @@ -1160,7 +1160,7 @@ struct QueryCacheRuntimeImpl { cpu_memory_), primitives_needed_minus_suceeded_streamer( static_cast(QueryType::StreamingPrimitivesNeededMinusSucceeded), runtime, 0u), - hcr_setup{}, hcr_is_set{}, is_hcr_running{} { + hcr_setup{}, hcr_is_set{}, is_hcr_running{}, maxwell3d{} { hcr_setup.sType = VK_STRUCTURE_TYPE_CONDITIONAL_RENDERING_BEGIN_INFO_EXT; hcr_setup.pNext = nullptr; @@ -1235,7 +1235,9 @@ void QueryCacheRuntime::Bind3DEngine(Maxwell3D* maxwell3d) { template void QueryCacheRuntime::View3DRegs(Func&& func) { - func(*impl->maxwell3d); + if (impl->maxwell3d) { + func(*impl->maxwell3d); + } } void QueryCacheRuntime::EndHostConditionalRendering() { diff --git a/src/yuzu/main.cpp b/src/yuzu/main.cpp index 0d9159585..5444a3925 100755 --- a/src/yuzu/main.cpp +++ b/src/yuzu/main.cpp @@ -3129,10 +3129,9 @@ void GMainWindow::OnMenuInstallToNAND() { QFuture future; InstallResult result; - if (file.endsWith(QStringLiteral("xci"), Qt::CaseInsensitive) || - file.endsWith(QStringLiteral("nsp"), Qt::CaseInsensitive)) { + if (file.endsWith(QStringLiteral("nsp"), Qt::CaseInsensitive)) { - future = QtConcurrent::run([this, &file] { return InstallNSPXCI(file); }); + future = QtConcurrent::run([this, &file] { return InstallNSP(file); }); while (!future.isFinished()) { QCoreApplication::processEvents(); @@ -3191,7 +3190,7 @@ void GMainWindow::OnMenuInstallToNAND() { ui->action_Install_File_NAND->setEnabled(true); } -InstallResult GMainWindow::InstallNSPXCI(const QString& filename) { +InstallResult GMainWindow::InstallNSP(const QString& filename) { const auto qt_raw_copy = [this](const FileSys::VirtualFile& src, const FileSys::VirtualFile& dest, std::size_t block_size) { if (src == nullptr || dest == nullptr) { @@ -3225,9 +3224,7 @@ InstallResult GMainWindow::InstallNSPXCI(const QString& filename) { return InstallResult::Failure; } } else { - const auto xci = std::make_shared( - vfs->OpenFile(filename.toStdString(), FileSys::Mode::Read)); - nsp = xci->GetSecurePartitionNSP(); + return InstallResult::Failure; } if (nsp->GetStatus() != Loader::ResultStatus::Success) { diff --git a/src/yuzu/main.h b/src/yuzu/main.h index 7bb34084b..f2bfdfd44 100755 --- a/src/yuzu/main.h +++ b/src/yuzu/main.h @@ -393,7 +393,7 @@ private: void RemoveCacheStorage(u64 program_id); bool SelectRomFSDumpTarget(const FileSys::ContentProvider&, u64 program_id, u64* selected_title_id, u8* selected_content_record_type); - InstallResult InstallNSPXCI(const QString& filename); + InstallResult InstallNSP(const QString& filename); InstallResult InstallNCA(const QString& filename); void MigrateConfigFiles(); void UpdateWindowTitle(std::string_view title_name = {}, std::string_view title_version = {},