mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-11 09:18:40 +12:00
RSX/Qt: Reuse gs_frame if possible
This commit is contained in:
parent
99f1f4c22a
commit
1ab3a0bd73
18 changed files with 101 additions and 16 deletions
|
@ -60,6 +60,8 @@
|
|||
#include "Emu/RSX/VK/VulkanAPI.h"
|
||||
#endif
|
||||
|
||||
#include "Emu/RSX/GSRender.h"
|
||||
|
||||
LOG_CHANNEL(sys_log, "SYS");
|
||||
|
||||
// Preallocate 32 MiB
|
||||
|
@ -1005,6 +1007,16 @@ void Emulator::SetForceBoot(bool force_boot)
|
|||
m_force_boot = force_boot;
|
||||
}
|
||||
|
||||
void Emulator::SetContinuousMode(bool continuous_mode)
|
||||
{
|
||||
m_continuous_mode = continuous_mode;
|
||||
|
||||
if (GSRender* render = static_cast<GSRender*>(g_fxo->try_get<rsx::thread>()))
|
||||
{
|
||||
render->set_continuous_mode(continuous_mode);
|
||||
}
|
||||
}
|
||||
|
||||
game_boot_result Emulator::Load(const std::string& title_id, bool is_disc_patch, usz recursion_count)
|
||||
{
|
||||
if (recursion_count == 0 && m_restrict_emu_state_change)
|
||||
|
@ -2897,6 +2909,9 @@ void qt_events_aware_op(int repeat_duration_ms, std::function<bool()> wrapped_op
|
|||
|
||||
void Emulator::GracefulShutdown(bool allow_autoexit, bool async_op, bool savestate)
|
||||
{
|
||||
// Make sure we close the game window
|
||||
Emu.SetContinuousMode(false);
|
||||
|
||||
// Ensure no game has booted inbetween
|
||||
const auto guard = Emu.MakeEmulationStateGuard();
|
||||
|
||||
|
@ -3278,7 +3293,6 @@ void Emulator::Kill(bool allow_autoexit, bool savestate, savestate_stage* save_s
|
|||
thread_ctrl::wait_for(5'000);
|
||||
}
|
||||
|
||||
|
||||
*closed_sucessfully = true;
|
||||
}));
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue