This commit is contained in:
SimoneN64
2024-01-18 22:09:27 +01:00
parent 607a43620a
commit 1c6f89f856
14 changed files with 44 additions and 1732 deletions

View File

@@ -11,7 +11,6 @@ using namespace Vulkan;
using namespace RDP;
static CommandProcessor* command_processor;
static WSI* wsi;
static std::unique_ptr<ParallelRdpWindowInfo> windowInfo;
VkQueue GetGraphicsQueue() {
@@ -125,13 +124,13 @@ private:
Program* fullscreen_quad_program;
WSI* LoadWSIPlatform(Vulkan::WSIPlatform* wsi_platform, std::unique_ptr<ParallelRdpWindowInfo>&& newWindowInfo) {
WSI* LoadWSIPlatform(Vulkan::InstanceFactory* instanceFactory, Vulkan::WSIPlatform* wsi_platform, std::unique_ptr<ParallelRdpWindowInfo>&& newWindowInfo) {
wsi = new WSI();
wsi->set_backbuffer_srgb(false);
wsi->set_platform(wsi_platform);
wsi->set_present_mode(PresentMode::SyncToVBlank);
Context::SystemHandles handles;
if (!wsi->init_simple(1, handles)) {
if (!wsi->init_simple(instanceFactory, 1, handles)) {
Util::panic("Failed to initialize WSI!");
}

View File

@@ -23,6 +23,8 @@ public:
}
};
static Vulkan::WSI* wsi;
VkRenderPass GetVkRenderPass();
VkQueue GetGraphicsQueue();
VkInstance GetVkInstance();
@@ -33,7 +35,7 @@ VkFormat GetVkFormat();
VkCommandBuffer GetVkCommandBuffer();
void SubmitRequestedVkCommandBuffer();
void LoadParallelRDP(const u8* rdram);
Vulkan::WSI* LoadWSIPlatform(Vulkan::WSIPlatform* wsi_platform, std::unique_ptr<ParallelRdpWindowInfo>&& newWindowInfo);
Vulkan::WSI* LoadWSIPlatform(Vulkan::InstanceFactory*, Vulkan::WSIPlatform* wsi_platform, std::unique_ptr<ParallelRdpWindowInfo>&& newWindowInfo);
void UpdateScreenParallelRdp(n64::Core& core, n64::VI& vi);
void ParallelRdpEnqueueCommand(int command_length, u32* buffer);
void ParallelRdpOnFullSync();