diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/audio_core/audio_renderer.h | 2 | ||||
| -rw-r--r-- | src/core/hle/service/am/am.cpp | 42 | ||||
| -rw-r--r-- | src/core/hle/service/am/am.h | 3 | ||||
| -rw-r--r-- | src/core/hle/service/hid/hid.cpp | 9 | ||||
| -rw-r--r-- | src/core/hle/service/hid/hid.h | 1 | ||||
| -rw-r--r-- | src/core/hle/service/time/interface.cpp | 2 | ||||
| -rw-r--r-- | src/core/hle/service/time/time.cpp | 29 | ||||
| -rw-r--r-- | src/core/hle/service/time/time.h | 1 | ||||
| -rw-r--r-- | src/video_core/engines/const_buffer_engine_interface.h | 14 | ||||
| -rw-r--r-- | src/video_core/renderer_opengl/gl_rasterizer.cpp | 7 | ||||
| -rw-r--r-- | src/video_core/renderer_vulkan/maxwell_to_vk.cpp | 20 | ||||
| -rw-r--r-- | src/yuzu/main.cpp | 15 |
12 files changed, 124 insertions, 21 deletions
diff --git a/src/audio_core/audio_renderer.h b/src/audio_core/audio_renderer.h index be1b019f1..c0fae669e 100644 --- a/src/audio_core/audio_renderer.h +++ b/src/audio_core/audio_renderer.h | |||
| @@ -189,7 +189,7 @@ struct UpdateDataHeader { | |||
| 189 | UpdateDataHeader() {} | 189 | UpdateDataHeader() {} |
| 190 | 190 | ||
| 191 | explicit UpdateDataHeader(const AudioRendererParameter& config) { | 191 | explicit UpdateDataHeader(const AudioRendererParameter& config) { |
| 192 | revision = Common::MakeMagic('R', 'E', 'V', '4'); // 5.1.0 Revision | 192 | revision = Common::MakeMagic('R', 'E', 'V', '8'); // 9.2.0 Revision |
| 193 | behavior_size = 0xb0; | 193 | behavior_size = 0xb0; |
| 194 | memory_pools_size = (config.effect_count + (config.voice_count * 4)) * 0x10; | 194 | memory_pools_size = (config.effect_count + (config.voice_count * 4)) * 0x10; |
| 195 | voices_size = config.voice_count * 0x10; | 195 | voices_size = config.voice_count * 0x10; |
diff --git a/src/core/hle/service/am/am.cpp b/src/core/hle/service/am/am.cpp index d1bf13c89..557608e76 100644 --- a/src/core/hle/service/am/am.cpp +++ b/src/core/hle/service/am/am.cpp | |||
| @@ -52,6 +52,11 @@ enum class LaunchParameterKind : u32 { | |||
| 52 | AccountPreselectedUser = 2, | 52 | AccountPreselectedUser = 2, |
| 53 | }; | 53 | }; |
| 54 | 54 | ||
| 55 | enum class VrMode : u8 { | ||
| 56 | Disabled = 0, | ||
| 57 | Enabled = 1, | ||
| 58 | }; | ||
| 59 | |||
| 55 | constexpr u32 LAUNCH_PARAMETER_ACCOUNT_PRESELECTED_USER_MAGIC = 0xC79497CA; | 60 | constexpr u32 LAUNCH_PARAMETER_ACCOUNT_PRESELECTED_USER_MAGIC = 0xC79497CA; |
| 56 | 61 | ||
| 57 | struct LaunchParameterAccountPreselectedUser { | 62 | struct LaunchParameterAccountPreselectedUser { |
| @@ -605,11 +610,11 @@ ICommonStateGetter::ICommonStateGetter(Core::System& system, | |||
| 605 | {30, nullptr, "GetHomeButtonReaderLockAccessor"}, | 610 | {30, nullptr, "GetHomeButtonReaderLockAccessor"}, |
| 606 | {31, nullptr, "GetReaderLockAccessorEx"}, | 611 | {31, nullptr, "GetReaderLockAccessorEx"}, |
| 607 | {40, nullptr, "GetCradleFwVersion"}, | 612 | {40, nullptr, "GetCradleFwVersion"}, |
| 608 | {50, nullptr, "IsVrModeEnabled"}, | 613 | {50, &ICommonStateGetter::IsVrModeEnabled, "IsVrModeEnabled"}, |
| 609 | {51, nullptr, "SetVrModeEnabled"}, | 614 | {51, &ICommonStateGetter::SetVrModeEnabled, "SetVrModeEnabled"}, |
| 610 | {52, &ICommonStateGetter::SetLcdBacklighOffEnabled, "SetLcdBacklighOffEnabled"}, | 615 | {52, &ICommonStateGetter::SetLcdBacklighOffEnabled, "SetLcdBacklighOffEnabled"}, |
| 611 | {53, nullptr, "BeginVrModeEx"}, | 616 | {53, nullptr, "BeginVrModeEx"}, |
| 612 | {54, nullptr, "EndVrModeEx"}, | 617 | {54, &ICommonStateGetter::EndVrModeEx, "EndVrModeEx"}, |
| 613 | {55, nullptr, "IsInControllerFirmwareUpdateSection"}, | 618 | {55, nullptr, "IsInControllerFirmwareUpdateSection"}, |
| 614 | {60, &ICommonStateGetter::GetDefaultDisplayResolution, "GetDefaultDisplayResolution"}, | 619 | {60, &ICommonStateGetter::GetDefaultDisplayResolution, "GetDefaultDisplayResolution"}, |
| 615 | {61, &ICommonStateGetter::GetDefaultDisplayResolutionChangeEvent, "GetDefaultDisplayResolutionChangeEvent"}, | 620 | {61, &ICommonStateGetter::GetDefaultDisplayResolutionChangeEvent, "GetDefaultDisplayResolutionChangeEvent"}, |
| @@ -672,6 +677,30 @@ void ICommonStateGetter::GetCurrentFocusState(Kernel::HLERequestContext& ctx) { | |||
| 672 | rb.Push(static_cast<u8>(FocusState::InFocus)); | 677 | rb.Push(static_cast<u8>(FocusState::InFocus)); |
| 673 | } | 678 | } |
| 674 | 679 | ||
| 680 | void ICommonStateGetter::IsVrModeEnabled(Kernel::HLERequestContext& ctx) { | ||
| 681 | LOG_WARNING(Service_AM, "(STUBBED) called"); | ||
| 682 | |||
| 683 | IPC::ResponseBuilder rb{ctx, 3}; | ||
| 684 | rb.Push(RESULT_SUCCESS); | ||
| 685 | rb.PushEnum(VrMode::Disabled); | ||
| 686 | } | ||
| 687 | |||
| 688 | void ICommonStateGetter::SetVrModeEnabled(Kernel::HLERequestContext& ctx) { | ||
| 689 | IPC::RequestParser rp{ctx}; | ||
| 690 | const auto is_vr_mode_enabled = rp.Pop<bool>(); | ||
| 691 | |||
| 692 | LOG_WARNING(Service_AM, "(STUBBED) called. is_vr_mode_enabled={}", is_vr_mode_enabled); | ||
| 693 | |||
| 694 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 695 | if (!is_vr_mode_enabled) { | ||
| 696 | rb.Push(RESULT_SUCCESS); | ||
| 697 | } else { | ||
| 698 | // TODO: Find better error code for this | ||
| 699 | UNIMPLEMENTED_MSG("is_vr_mode_enabled={}", is_vr_mode_enabled); | ||
| 700 | rb.Push(RESULT_UNKNOWN); | ||
| 701 | } | ||
| 702 | } | ||
| 703 | |||
| 675 | void ICommonStateGetter::SetLcdBacklighOffEnabled(Kernel::HLERequestContext& ctx) { | 704 | void ICommonStateGetter::SetLcdBacklighOffEnabled(Kernel::HLERequestContext& ctx) { |
| 676 | IPC::RequestParser rp{ctx}; | 705 | IPC::RequestParser rp{ctx}; |
| 677 | const auto is_lcd_backlight_off_enabled = rp.Pop<bool>(); | 706 | const auto is_lcd_backlight_off_enabled = rp.Pop<bool>(); |
| @@ -683,6 +712,13 @@ void ICommonStateGetter::SetLcdBacklighOffEnabled(Kernel::HLERequestContext& ctx | |||
| 683 | rb.Push(RESULT_SUCCESS); | 712 | rb.Push(RESULT_SUCCESS); |
| 684 | } | 713 | } |
| 685 | 714 | ||
| 715 | void ICommonStateGetter::EndVrModeEx(Kernel::HLERequestContext& ctx) { | ||
| 716 | LOG_WARNING(Service_AM, "(STUBBED) called"); | ||
| 717 | |||
| 718 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 719 | rb.Push(RESULT_SUCCESS); | ||
| 720 | } | ||
| 721 | |||
| 686 | void ICommonStateGetter::GetDefaultDisplayResolutionChangeEvent(Kernel::HLERequestContext& ctx) { | 722 | void ICommonStateGetter::GetDefaultDisplayResolutionChangeEvent(Kernel::HLERequestContext& ctx) { |
| 687 | LOG_DEBUG(Service_AM, "called"); | 723 | LOG_DEBUG(Service_AM, "called"); |
| 688 | 724 | ||
diff --git a/src/core/hle/service/am/am.h b/src/core/hle/service/am/am.h index 0843de781..53cfce10f 100644 --- a/src/core/hle/service/am/am.h +++ b/src/core/hle/service/am/am.h | |||
| @@ -182,7 +182,10 @@ private: | |||
| 182 | void GetOperationMode(Kernel::HLERequestContext& ctx); | 182 | void GetOperationMode(Kernel::HLERequestContext& ctx); |
| 183 | void GetPerformanceMode(Kernel::HLERequestContext& ctx); | 183 | void GetPerformanceMode(Kernel::HLERequestContext& ctx); |
| 184 | void GetBootMode(Kernel::HLERequestContext& ctx); | 184 | void GetBootMode(Kernel::HLERequestContext& ctx); |
| 185 | void IsVrModeEnabled(Kernel::HLERequestContext& ctx); | ||
| 186 | void SetVrModeEnabled(Kernel::HLERequestContext& ctx); | ||
| 185 | void SetLcdBacklighOffEnabled(Kernel::HLERequestContext& ctx); | 187 | void SetLcdBacklighOffEnabled(Kernel::HLERequestContext& ctx); |
| 188 | void EndVrModeEx(Kernel::HLERequestContext& ctx); | ||
| 186 | void GetDefaultDisplayResolution(Kernel::HLERequestContext& ctx); | 189 | void GetDefaultDisplayResolution(Kernel::HLERequestContext& ctx); |
| 187 | void SetCpuBoostMode(Kernel::HLERequestContext& ctx); | 190 | void SetCpuBoostMode(Kernel::HLERequestContext& ctx); |
| 188 | 191 | ||
diff --git a/src/core/hle/service/hid/hid.cpp b/src/core/hle/service/hid/hid.cpp index e6b56a9f9..d6ed5f304 100644 --- a/src/core/hle/service/hid/hid.cpp +++ b/src/core/hle/service/hid/hid.cpp | |||
| @@ -235,7 +235,7 @@ Hid::Hid(Core::System& system) : ServiceFramework("hid"), system(system) { | |||
| 235 | {303, nullptr, "ActivateSevenSixAxisSensor"}, | 235 | {303, nullptr, "ActivateSevenSixAxisSensor"}, |
| 236 | {304, nullptr, "StartSevenSixAxisSensor"}, | 236 | {304, nullptr, "StartSevenSixAxisSensor"}, |
| 237 | {305, nullptr, "StopSevenSixAxisSensor"}, | 237 | {305, nullptr, "StopSevenSixAxisSensor"}, |
| 238 | {306, nullptr, "InitializeSevenSixAxisSensor"}, | 238 | {306, &Hid::InitializeSevenSixAxisSensor, "InitializeSevenSixAxisSensor"}, |
| 239 | {307, nullptr, "FinalizeSevenSixAxisSensor"}, | 239 | {307, nullptr, "FinalizeSevenSixAxisSensor"}, |
| 240 | {308, nullptr, "SetSevenSixAxisSensorFusionStrength"}, | 240 | {308, nullptr, "SetSevenSixAxisSensorFusionStrength"}, |
| 241 | {309, nullptr, "GetSevenSixAxisSensorFusionStrength"}, | 241 | {309, nullptr, "GetSevenSixAxisSensorFusionStrength"}, |
| @@ -853,6 +853,13 @@ void Hid::SetPalmaBoostMode(Kernel::HLERequestContext& ctx) { | |||
| 853 | rb.Push(RESULT_SUCCESS); | 853 | rb.Push(RESULT_SUCCESS); |
| 854 | } | 854 | } |
| 855 | 855 | ||
| 856 | void Hid::InitializeSevenSixAxisSensor(Kernel::HLERequestContext& ctx) { | ||
| 857 | LOG_WARNING(Service_HID, "(STUBBED) called"); | ||
| 858 | |||
| 859 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 860 | rb.Push(RESULT_SUCCESS); | ||
| 861 | } | ||
| 862 | |||
| 856 | class HidDbg final : public ServiceFramework<HidDbg> { | 863 | class HidDbg final : public ServiceFramework<HidDbg> { |
| 857 | public: | 864 | public: |
| 858 | explicit HidDbg() : ServiceFramework{"hid:dbg"} { | 865 | explicit HidDbg() : ServiceFramework{"hid:dbg"} { |
diff --git a/src/core/hle/service/hid/hid.h b/src/core/hle/service/hid/hid.h index ad20f147c..039c38b58 100644 --- a/src/core/hle/service/hid/hid.h +++ b/src/core/hle/service/hid/hid.h | |||
| @@ -128,6 +128,7 @@ private: | |||
| 128 | void StopSixAxisSensor(Kernel::HLERequestContext& ctx); | 128 | void StopSixAxisSensor(Kernel::HLERequestContext& ctx); |
| 129 | void SetIsPalmaAllConnectable(Kernel::HLERequestContext& ctx); | 129 | void SetIsPalmaAllConnectable(Kernel::HLERequestContext& ctx); |
| 130 | void SetPalmaBoostMode(Kernel::HLERequestContext& ctx); | 130 | void SetPalmaBoostMode(Kernel::HLERequestContext& ctx); |
| 131 | void InitializeSevenSixAxisSensor(Kernel::HLERequestContext& ctx); | ||
| 131 | 132 | ||
| 132 | std::shared_ptr<IAppletResource> applet_resource; | 133 | std::shared_ptr<IAppletResource> applet_resource; |
| 133 | Core::System& system; | 134 | Core::System& system; |
diff --git a/src/core/hle/service/time/interface.cpp b/src/core/hle/service/time/interface.cpp index 1660bbdb8..f509653a3 100644 --- a/src/core/hle/service/time/interface.cpp +++ b/src/core/hle/service/time/interface.cpp | |||
| @@ -30,7 +30,7 @@ Time::Time(std::shared_ptr<Module> module, Core::System& system, const char* nam | |||
| 30 | {400, &Time::GetClockSnapshot, "GetClockSnapshot"}, | 30 | {400, &Time::GetClockSnapshot, "GetClockSnapshot"}, |
| 31 | {401, &Time::GetClockSnapshotFromSystemClockContext, "GetClockSnapshotFromSystemClockContext"}, | 31 | {401, &Time::GetClockSnapshotFromSystemClockContext, "GetClockSnapshotFromSystemClockContext"}, |
| 32 | {500, nullptr, "CalculateStandardUserSystemClockDifferenceByUser"}, | 32 | {500, nullptr, "CalculateStandardUserSystemClockDifferenceByUser"}, |
| 33 | {501, nullptr, "CalculateSpanBetween"}, | 33 | {501, &Time::CalculateSpanBetween, "CalculateSpanBetween"}, |
| 34 | }; | 34 | }; |
| 35 | // clang-format on | 35 | // clang-format on |
| 36 | 36 | ||
diff --git a/src/core/hle/service/time/time.cpp b/src/core/hle/service/time/time.cpp index 749b7be70..ce859f18d 100644 --- a/src/core/hle/service/time/time.cpp +++ b/src/core/hle/service/time/time.cpp | |||
| @@ -308,6 +308,35 @@ void Module::Interface::GetClockSnapshotFromSystemClockContext(Kernel::HLEReques | |||
| 308 | ctx.WriteBuffer(&clock_snapshot, sizeof(Clock::ClockSnapshot)); | 308 | ctx.WriteBuffer(&clock_snapshot, sizeof(Clock::ClockSnapshot)); |
| 309 | } | 309 | } |
| 310 | 310 | ||
| 311 | void Module::Interface::CalculateSpanBetween(Kernel::HLERequestContext& ctx) { | ||
| 312 | LOG_DEBUG(Service_Time, "called"); | ||
| 313 | |||
| 314 | IPC::RequestParser rp{ctx}; | ||
| 315 | const auto snapshot_a = rp.PopRaw<Clock::ClockSnapshot>(); | ||
| 316 | const auto snapshot_b = rp.PopRaw<Clock::ClockSnapshot>(); | ||
| 317 | |||
| 318 | Clock::TimeSpanType time_span_type{}; | ||
| 319 | s64 span{}; | ||
| 320 | if (const ResultCode result{snapshot_a.steady_clock_time_point.GetSpanBetween( | ||
| 321 | snapshot_b.steady_clock_time_point, span)}; | ||
| 322 | result != RESULT_SUCCESS) { | ||
| 323 | if (snapshot_a.network_time && snapshot_b.network_time) { | ||
| 324 | time_span_type = | ||
| 325 | Clock::TimeSpanType::FromSeconds(snapshot_b.network_time - snapshot_a.network_time); | ||
| 326 | } else { | ||
| 327 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 328 | rb.Push(ERROR_TIME_NOT_FOUND); | ||
| 329 | return; | ||
| 330 | } | ||
| 331 | } else { | ||
| 332 | time_span_type = Clock::TimeSpanType::FromSeconds(span); | ||
| 333 | } | ||
| 334 | |||
| 335 | IPC::ResponseBuilder rb{ctx, (sizeof(s64) / 4) + 2}; | ||
| 336 | rb.Push(RESULT_SUCCESS); | ||
| 337 | rb.PushRaw(time_span_type.nanoseconds); | ||
| 338 | } | ||
| 339 | |||
| 311 | void Module::Interface::GetSharedMemoryNativeHandle(Kernel::HLERequestContext& ctx) { | 340 | void Module::Interface::GetSharedMemoryNativeHandle(Kernel::HLERequestContext& ctx) { |
| 312 | LOG_DEBUG(Service_Time, "called"); | 341 | LOG_DEBUG(Service_Time, "called"); |
| 313 | IPC::ResponseBuilder rb{ctx, 2, 1}; | 342 | IPC::ResponseBuilder rb{ctx, 2, 1}; |
diff --git a/src/core/hle/service/time/time.h b/src/core/hle/service/time/time.h index aadc2df60..351988468 100644 --- a/src/core/hle/service/time/time.h +++ b/src/core/hle/service/time/time.h | |||
| @@ -32,6 +32,7 @@ public: | |||
| 32 | void CalculateMonotonicSystemClockBaseTimePoint(Kernel::HLERequestContext& ctx); | 32 | void CalculateMonotonicSystemClockBaseTimePoint(Kernel::HLERequestContext& ctx); |
| 33 | void GetClockSnapshot(Kernel::HLERequestContext& ctx); | 33 | void GetClockSnapshot(Kernel::HLERequestContext& ctx); |
| 34 | void GetClockSnapshotFromSystemClockContext(Kernel::HLERequestContext& ctx); | 34 | void GetClockSnapshotFromSystemClockContext(Kernel::HLERequestContext& ctx); |
| 35 | void CalculateSpanBetween(Kernel::HLERequestContext& ctx); | ||
| 35 | void GetSharedMemoryNativeHandle(Kernel::HLERequestContext& ctx); | 36 | void GetSharedMemoryNativeHandle(Kernel::HLERequestContext& ctx); |
| 36 | 37 | ||
| 37 | private: | 38 | private: |
diff --git a/src/video_core/engines/const_buffer_engine_interface.h b/src/video_core/engines/const_buffer_engine_interface.h index 724ee0fd6..ebe139504 100644 --- a/src/video_core/engines/const_buffer_engine_interface.h +++ b/src/video_core/engines/const_buffer_engine_interface.h | |||
| @@ -18,10 +18,14 @@ struct SamplerDescriptor { | |||
| 18 | union { | 18 | union { |
| 19 | u32 raw = 0; | 19 | u32 raw = 0; |
| 20 | BitField<0, 2, Tegra::Shader::TextureType> texture_type; | 20 | BitField<0, 2, Tegra::Shader::TextureType> texture_type; |
| 21 | BitField<2, 3, Tegra::Texture::ComponentType> component_type; | 21 | BitField<2, 3, Tegra::Texture::ComponentType> r_type; |
| 22 | BitField<5, 1, u32> is_array; | 22 | BitField<5, 1, u32> is_array; |
| 23 | BitField<6, 1, u32> is_buffer; | 23 | BitField<6, 1, u32> is_buffer; |
| 24 | BitField<7, 1, u32> is_shadow; | 24 | BitField<7, 1, u32> is_shadow; |
| 25 | BitField<8, 3, Tegra::Texture::ComponentType> g_type; | ||
| 26 | BitField<11, 3, Tegra::Texture::ComponentType> b_type; | ||
| 27 | BitField<14, 3, Tegra::Texture::ComponentType> a_type; | ||
| 28 | BitField<17, 7, Tegra::Texture::TextureFormat> format; | ||
| 25 | }; | 29 | }; |
| 26 | 30 | ||
| 27 | bool operator==(const SamplerDescriptor& rhs) const noexcept { | 31 | bool operator==(const SamplerDescriptor& rhs) const noexcept { |
| @@ -36,9 +40,11 @@ struct SamplerDescriptor { | |||
| 36 | using Tegra::Shader::TextureType; | 40 | using Tegra::Shader::TextureType; |
| 37 | SamplerDescriptor result; | 41 | SamplerDescriptor result; |
| 38 | 42 | ||
| 39 | // This is going to be used to determine the shading language type. | 43 | result.format.Assign(tic.format.Value()); |
| 40 | // Because of that we don't care about all component types on color textures. | 44 | result.r_type.Assign(tic.r_type.Value()); |
| 41 | result.component_type.Assign(tic.r_type.Value()); | 45 | result.g_type.Assign(tic.g_type.Value()); |
| 46 | result.b_type.Assign(tic.b_type.Value()); | ||
| 47 | result.a_type.Assign(tic.a_type.Value()); | ||
| 42 | 48 | ||
| 43 | switch (tic.texture_type.Value()) { | 49 | switch (tic.texture_type.Value()) { |
| 44 | case Tegra::Texture::TextureType::Texture1D: | 50 | case Tegra::Texture::TextureType::Texture1D: |
diff --git a/src/video_core/renderer_opengl/gl_rasterizer.cpp b/src/video_core/renderer_opengl/gl_rasterizer.cpp index 826eee7df..31add708f 100644 --- a/src/video_core/renderer_opengl/gl_rasterizer.cpp +++ b/src/video_core/renderer_opengl/gl_rasterizer.cpp | |||
| @@ -444,6 +444,7 @@ void RasterizerOpenGL::Clear() { | |||
| 444 | } | 444 | } |
| 445 | 445 | ||
| 446 | SyncRasterizeEnable(); | 446 | SyncRasterizeEnable(); |
| 447 | SyncStencilTestState(); | ||
| 447 | 448 | ||
| 448 | if (regs.clear_flags.scissor) { | 449 | if (regs.clear_flags.scissor) { |
| 449 | SyncScissorTest(); | 450 | SyncScissorTest(); |
| @@ -1052,12 +1053,8 @@ void RasterizerOpenGL::SyncStencilTestState() { | |||
| 1052 | flags[Dirty::StencilTest] = false; | 1053 | flags[Dirty::StencilTest] = false; |
| 1053 | 1054 | ||
| 1054 | const auto& regs = gpu.regs; | 1055 | const auto& regs = gpu.regs; |
| 1055 | if (!regs.stencil_enable) { | 1056 | oglEnable(GL_STENCIL_TEST, regs.stencil_enable); |
| 1056 | glDisable(GL_STENCIL_TEST); | ||
| 1057 | return; | ||
| 1058 | } | ||
| 1059 | 1057 | ||
| 1060 | glEnable(GL_STENCIL_TEST); | ||
| 1061 | glStencilFuncSeparate(GL_FRONT, MaxwellToGL::ComparisonOp(regs.stencil_front_func_func), | 1058 | glStencilFuncSeparate(GL_FRONT, MaxwellToGL::ComparisonOp(regs.stencil_front_func_func), |
| 1062 | regs.stencil_front_func_ref, regs.stencil_front_func_mask); | 1059 | regs.stencil_front_func_ref, regs.stencil_front_func_mask); |
| 1063 | glStencilOpSeparate(GL_FRONT, MaxwellToGL::StencilOp(regs.stencil_front_op_fail), | 1060 | glStencilOpSeparate(GL_FRONT, MaxwellToGL::StencilOp(regs.stencil_front_op_fail), |
diff --git a/src/video_core/renderer_vulkan/maxwell_to_vk.cpp b/src/video_core/renderer_vulkan/maxwell_to_vk.cpp index f93447610..7480cb7c3 100644 --- a/src/video_core/renderer_vulkan/maxwell_to_vk.cpp +++ b/src/video_core/renderer_vulkan/maxwell_to_vk.cpp | |||
| @@ -401,6 +401,26 @@ vk::Format VertexFormat(Maxwell::VertexAttribute::Type type, Maxwell::VertexAttr | |||
| 401 | } | 401 | } |
| 402 | break; | 402 | break; |
| 403 | case Maxwell::VertexAttribute::Type::SignedScaled: | 403 | case Maxwell::VertexAttribute::Type::SignedScaled: |
| 404 | switch (size) { | ||
| 405 | case Maxwell::VertexAttribute::Size::Size_8: | ||
| 406 | return vk::Format::eR8Sscaled; | ||
| 407 | case Maxwell::VertexAttribute::Size::Size_8_8: | ||
| 408 | return vk::Format::eR8G8Sscaled; | ||
| 409 | case Maxwell::VertexAttribute::Size::Size_8_8_8: | ||
| 410 | return vk::Format::eR8G8B8Sscaled; | ||
| 411 | case Maxwell::VertexAttribute::Size::Size_8_8_8_8: | ||
| 412 | return vk::Format::eR8G8B8A8Sscaled; | ||
| 413 | case Maxwell::VertexAttribute::Size::Size_16: | ||
| 414 | return vk::Format::eR16Sscaled; | ||
| 415 | case Maxwell::VertexAttribute::Size::Size_16_16: | ||
| 416 | return vk::Format::eR16G16Sscaled; | ||
| 417 | case Maxwell::VertexAttribute::Size::Size_16_16_16: | ||
| 418 | return vk::Format::eR16G16B16Sscaled; | ||
| 419 | case Maxwell::VertexAttribute::Size::Size_16_16_16_16: | ||
| 420 | return vk::Format::eR16G16B16A16Sscaled; | ||
| 421 | default: | ||
| 422 | break; | ||
| 423 | } | ||
| 404 | break; | 424 | break; |
| 405 | case Maxwell::VertexAttribute::Type::Float: | 425 | case Maxwell::VertexAttribute::Type::Float: |
| 406 | switch (size) { | 426 | switch (size) { |
diff --git a/src/yuzu/main.cpp b/src/yuzu/main.cpp index 47615adfe..d7e59d0cd 100644 --- a/src/yuzu/main.cpp +++ b/src/yuzu/main.cpp | |||
| @@ -1034,6 +1034,14 @@ void GMainWindow::BootGame(const QString& filename) { | |||
| 1034 | } | 1034 | } |
| 1035 | 1035 | ||
| 1036 | void GMainWindow::ShutdownGame() { | 1036 | void GMainWindow::ShutdownGame() { |
| 1037 | if (!emulation_running) { | ||
| 1038 | return; | ||
| 1039 | } | ||
| 1040 | |||
| 1041 | if (ui.action_Fullscreen->isChecked()) { | ||
| 1042 | HideFullscreen(); | ||
| 1043 | } | ||
| 1044 | |||
| 1037 | AllowOSSleep(); | 1045 | AllowOSSleep(); |
| 1038 | 1046 | ||
| 1039 | discord_rpc->Pause(); | 1047 | discord_rpc->Pause(); |
| @@ -1716,11 +1724,6 @@ void GMainWindow::OnStartGame() { | |||
| 1716 | } | 1724 | } |
| 1717 | 1725 | ||
| 1718 | void GMainWindow::OnPauseGame() { | 1726 | void GMainWindow::OnPauseGame() { |
| 1719 | Core::System& system{Core::System::GetInstance()}; | ||
| 1720 | if (system.GetExitLock() && !ConfirmForceLockedExit()) { | ||
| 1721 | return; | ||
| 1722 | } | ||
| 1723 | |||
| 1724 | emu_thread->SetRunning(false); | 1727 | emu_thread->SetRunning(false); |
| 1725 | 1728 | ||
| 1726 | ui.action_Start->setEnabled(true); | 1729 | ui.action_Start->setEnabled(true); |
| @@ -1803,7 +1806,7 @@ void GMainWindow::ToggleWindowMode() { | |||
| 1803 | // Render in the main window... | 1806 | // Render in the main window... |
| 1804 | render_window->BackupGeometry(); | 1807 | render_window->BackupGeometry(); |
| 1805 | ui.horizontalLayout->addWidget(render_window); | 1808 | ui.horizontalLayout->addWidget(render_window); |
| 1806 | render_window->setFocusPolicy(Qt::ClickFocus); | 1809 | render_window->setFocusPolicy(Qt::StrongFocus); |
| 1807 | if (emulation_running) { | 1810 | if (emulation_running) { |
| 1808 | render_window->setVisible(true); | 1811 | render_window->setVisible(true); |
| 1809 | render_window->setFocus(); | 1812 | render_window->setFocus(); |