Add Renderer::DrawActors for quick actors rendering in custom render passes

This commit is contained in:
Wojtek Figat
2023-01-30 00:52:32 +01:00
parent 238095b862
commit 9b3d15aa46
4 changed files with 52 additions and 22 deletions

View File

@@ -2,6 +2,9 @@
#include "RenderList.h"
#include "Engine/Core/Collections/Sorting.h"
#if !BUILD_RELEASE
#include "Engine/Core/Utilities.h"
#endif
#include "Engine/Graphics/Materials/IMaterial.h"
#include "Engine/Graphics/RenderTask.h"
#include "Engine/Graphics/GPUContext.h"
@@ -646,6 +649,9 @@ void RenderList::ExecuteDrawCalls(const RenderContext& renderContext, DrawCallsL
{
if (list.IsEmpty())
return;
#if !BUILD_RELEASE
CHECK(Utilities::CountBits((uint32)renderContext.View.Pass) == 1); // Ensure proper pass is set (single bit flag)
#endif
PROFILE_GPU_CPU("Drawing");
const auto* drawCallsData = drawCalls.Get();
const auto* listData = list.Indices.Get();