Works, but with memory leaks

This commit is contained in:
Dynamitos
2022-03-26 12:55:04 +01:00
parent cd28e433cc
commit 9130a7961f
23 changed files with 720 additions and 308 deletions
@@ -171,12 +171,6 @@ void CmdBuffer::waitForCommand(uint32 timeout)
refreshFence();
}
Event CmdBuffer::asyncWait() const
{
return fence->asyncWait();
}
PFence CmdBuffer::getFence()
{
return fence;
@@ -32,7 +32,10 @@ public:
void addWaitSemaphore(VkPipelineStageFlags stages, PSemaphore waitSemaphore);
void refreshFence();
void waitForCommand(uint32 timeToWait = 1000000u);
Event asyncWait() const;
Fence* operator co_await()
{
return fence.getHandle();
}
PFence getFence();
PCommandBufferManager getManager();
enum State
@@ -80,11 +80,6 @@ void Fence::wait(uint32 timeout)
break;
}
}
Event Fence::asyncWait() const
{
return signaled;
}
VertexDeclaration::VertexDeclaration(const Array<Gfx::VertexElement>& elementList)
: elementList(elementList)
@@ -43,7 +43,10 @@ public:
return fence;
}
void wait(uint32 timeout);
Event asyncWait() const;
Event& operator co_await()
{
return signaled;
}
bool operator<(const Fence &other) const
{
return fence < other.fence;