Add Quad Overdraw debug view mode

This commit is contained in:
Wojtek Figat
2021-10-07 14:59:06 +02:00
parent 949766e3a0
commit 1af5ec8492
22 changed files with 473 additions and 5 deletions

View File

@@ -16,6 +16,9 @@ private:
PipelineStateCache Default;
PipelineStateCache DefaultLightmap;
PipelineStateCache Depth;
#if USE_EDITOR
PipelineStateCache QuadOverdraw;
#endif
FORCE_INLINE PipelineStateCache* GetPS(const DrawPass pass, const bool useLightmap)
{
@@ -25,6 +28,10 @@ private:
return &Depth;
case DrawPass::GBuffer:
return useLightmap ? &DefaultLightmap : &Default;
#if USE_EDITOR
case DrawPass::QuadOverdraw:
return &QuadOverdraw;
#endif
default:
return nullptr;
}
@@ -35,6 +42,9 @@ private:
Default.Release();
DefaultLightmap.Release();
Depth.Release();
#if USE_EDITOR
QuadOverdraw.Release();
#endif
}
};