Merge remote-tracking branch 'origin/SP3-1-Rendering' into SP3-1-Rendering

This commit is contained in:
Sri Sham Haran 2022-10-02 01:01:50 +08:00
commit 8a6ef1fc2d
3 changed files with 10 additions and 1 deletions

View File

@ -136,6 +136,9 @@ namespace Sandbox
SHADE::SHSystemManager::RunRoutines(false, 0.016f);
}
// Finish all graphics jobs first
graphicsSystem->AwaitGraphicsExecution();
}

View File

@ -552,12 +552,17 @@ namespace SHADE
worldCamera->SetPerspective(90.0f, static_cast<float>(windowDims.first), static_cast<float>(windowDims.second), 0.0f, 100.0f);
}
void SHGraphicsSystem::AwaitGraphicsExecution()
{
device->WaitIdle();
}
void SHGraphicsSystem::SetWindow(SHWindow* wind) noexcept
{
window = wind;
}
/*-----------------------------------------------------------------------------------*/
/* System Routine Functions - BeginRoutine */
/*-----------------------------------------------------------------------------------*/

View File

@ -251,6 +251,7 @@ namespace SHADE
void BuildTextures();
void HandleResize(void) noexcept;
void AwaitGraphicsExecution();
/*-----------------------------------------------------------------------------*/
/* Setters */