Command to acquire swap chain texture

This commit is contained in:
2025-02-16 11:54:04 -05:00
parent 3e7caa2c7c
commit 7e8aaaa891
12 changed files with 145 additions and 4 deletions

View File

@@ -82,6 +82,20 @@ void Win32EditorApplication::Update()
// Draw here for now
// 1) Acquire a Command Buffer
CommandList* cmdList = AcquireCommandList(GraphicsDevice, QueueType::Graphics);
if (cmdList == nullptr)
{
Log(LogLevel::Error, LogCategory::Editor, "Failed to acquire command list.");
Running = false;
return;
}
Texture* swapChainTexture = nullptr;
if (!AcquireSwapChainTexture(cmdList, MainWindow, &swapChainTexture))
{
Log(LogLevel::Error, LogCategory::Editor, "Failed to acquire swapchain texture.");
Running = false;
return;
}
// Submit Commands
SubmitCommandLists(GraphicsDevice);