Removing hard sync, breaking stuff again
This commit is contained in:
@@ -54,6 +54,7 @@ public:
|
|||||||
virtual ORenderPass createRenderPass(RenderTargetLayout layout, Array<SubPassDependency> dependencies, PViewport renderArea) = 0;
|
virtual ORenderPass createRenderPass(RenderTargetLayout layout, Array<SubPassDependency> dependencies, PViewport renderArea) = 0;
|
||||||
virtual void beginRenderPass(PRenderPass renderPass) = 0;
|
virtual void beginRenderPass(PRenderPass renderPass) = 0;
|
||||||
virtual void endRenderPass() = 0;
|
virtual void endRenderPass() = 0;
|
||||||
|
virtual void waitDeviceIdle() = 0;
|
||||||
|
|
||||||
virtual void executeCommands(const Array<PRenderCommand>& commands) = 0;
|
virtual void executeCommands(const Array<PRenderCommand>& commands) = 0;
|
||||||
virtual void executeCommands(const Array<PComputeCommand>& commands) = 0;
|
virtual void executeCommands(const Array<PComputeCommand>& commands) = 0;
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ struct GraphicsInitializer
|
|||||||
: applicationName("SeeleEngine")
|
: applicationName("SeeleEngine")
|
||||||
, engineName("SeeleEngine")
|
, engineName("SeeleEngine")
|
||||||
, windowLayoutFile(nullptr)
|
, windowLayoutFile(nullptr)
|
||||||
, layers{"VK_LAYER_LUNARG_monitor"}
|
, layers{}
|
||||||
, instanceExtensions{}
|
, instanceExtensions{}
|
||||||
, deviceExtensions{"VK_KHR_swapchain"}
|
, deviceExtensions{"VK_KHR_swapchain"}
|
||||||
, windowHandle(nullptr)
|
, windowHandle(nullptr)
|
||||||
|
|||||||
@@ -12,8 +12,6 @@
|
|||||||
#include "Material/MaterialInstance.h"
|
#include "Material/MaterialInstance.h"
|
||||||
#include "Graphics/Descriptor.h"
|
#include "Graphics/Descriptor.h"
|
||||||
#include "Graphics/Command.h"
|
#include "Graphics/Command.h"
|
||||||
#include <vulkan/vulkan.h>
|
|
||||||
#include "Graphics/Vulkan/Graphics.h"
|
|
||||||
|
|
||||||
using namespace Seele;
|
using namespace Seele;
|
||||||
|
|
||||||
|
|||||||
@@ -9,8 +9,6 @@
|
|||||||
#include "Math/Vector.h"
|
#include "Math/Vector.h"
|
||||||
#include "RenderGraph.h"
|
#include "RenderGraph.h"
|
||||||
#include "Graphics/Command.h"
|
#include "Graphics/Command.h"
|
||||||
#include <vulkan/vulkan.h>
|
|
||||||
#include "Graphics/Vulkan/Graphics.h"
|
|
||||||
|
|
||||||
using namespace Seele;
|
using namespace Seele;
|
||||||
|
|
||||||
@@ -131,9 +129,8 @@ void DepthPrepass::render()
|
|||||||
commands.add(command);
|
commands.add(command);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
graphics->executeCommands(commands);
|
//graphics->executeCommands(commands);
|
||||||
graphics->endRenderPass();
|
graphics->endRenderPass();
|
||||||
//vkDeviceWaitIdle(((Vulkan::Graphics*)graphics.getHandle())->getDevice());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DepthPrepass::endFrame()
|
void DepthPrepass::endFrame()
|
||||||
|
|||||||
@@ -111,6 +111,11 @@ void Graphics::endRenderPass()
|
|||||||
getGraphicsCommands()->submitCommands();
|
getGraphicsCommands()->submitCommands();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Graphics::waitDeviceIdle()
|
||||||
|
{
|
||||||
|
vkDeviceWaitIdle(handle);
|
||||||
|
}
|
||||||
|
|
||||||
void Graphics::executeCommands(const Array<Gfx::PRenderCommand>& commands)
|
void Graphics::executeCommands(const Array<Gfx::PRenderCommand>& commands)
|
||||||
{
|
{
|
||||||
getGraphicsCommands()->getCommands()->executeCommands(commands);
|
getGraphicsCommands()->getCommands()->executeCommands(commands);
|
||||||
|
|||||||
@@ -37,6 +37,7 @@ public:
|
|||||||
virtual Gfx::ORenderPass createRenderPass(Gfx::RenderTargetLayout layout, Array<Gfx::SubPassDependency> dependencies, Gfx::PViewport renderArea) override;
|
virtual Gfx::ORenderPass createRenderPass(Gfx::RenderTargetLayout layout, Array<Gfx::SubPassDependency> dependencies, Gfx::PViewport renderArea) override;
|
||||||
virtual void beginRenderPass(Gfx::PRenderPass renderPass) override;
|
virtual void beginRenderPass(Gfx::PRenderPass renderPass) override;
|
||||||
virtual void endRenderPass() override;
|
virtual void endRenderPass() override;
|
||||||
|
virtual void waitDeviceIdle() override;
|
||||||
|
|
||||||
virtual void executeCommands(const Array<Gfx::PRenderCommand>& commands) override;
|
virtual void executeCommands(const Array<Gfx::PRenderCommand>& commands) override;
|
||||||
virtual void executeCommands(const Array<Gfx::PComputeCommand>& commands) override;
|
virtual void executeCommands(const Array<Gfx::PComputeCommand>& commands) override;
|
||||||
|
|||||||
Reference in New Issue
Block a user