System: Add an option to preload CD image to RAM
This commit is contained in:
parent
3187d07d03
commit
9496c992f7
8 changed files with 23 additions and 0 deletions
|
|
@ -14,6 +14,7 @@
|
|||
#include "gpu.h"
|
||||
#include "host_display.h"
|
||||
#include "host_interface.h"
|
||||
#include "host_interface_progress_callback.h"
|
||||
#include "interrupt_controller.h"
|
||||
#include "mdec.h"
|
||||
#include "memory_card.h"
|
||||
|
|
@ -163,6 +164,14 @@ bool System::Boot(const SystemBootParameters& params)
|
|||
return false;
|
||||
}
|
||||
|
||||
if (params.override_load_image_to_ram.value_or(GetSettings().cdrom_load_image_to_ram))
|
||||
{
|
||||
HostInterfaceProgressCallback callback(m_host_interface);
|
||||
std::unique_ptr<CDImage> memory_image = CDImage::CreateMemoryImage(media.get(), &callback);
|
||||
if (memory_image)
|
||||
media = std::move(memory_image);
|
||||
}
|
||||
|
||||
if (m_region == ConsoleRegion::Auto)
|
||||
{
|
||||
const DiscRegion disc_region = GameList::GetRegionForImage(media.get());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue