Fix a bug with buffer reuse. Simplify stencil clearing. (#1763)

Co-authored-by: Bart Louwers <bart@emeel.net>
This commit is contained in:
Tim Sylvester
2023-10-17 07:18:23 -07:00
committed by GitHub
parent 902b8cace5
commit 565136f509
4 changed files with 49 additions and 34 deletions

View File

@@ -60,7 +60,7 @@ public:
MTLSamplerStatePtr createMetalSamplerState(MTLSamplerDescriptorPtr samplerDescriptor) const;
// Actually remove the objects we marked as abandoned with the above methods.
void performCleanup() override {}
void performCleanup() override;
void reduceMemoryUsage() override {}
@@ -134,6 +134,7 @@ private:
MTLDepthStencilStatePtr clipMaskDepthStencilState;
MTLRenderPipelineStatePtr clipMaskPipelineState;
BufferResource clipMaskUniformsBuffer;
bool clipMaskUniformsBufferUsed = false;
const gfx::Renderable* stencilStateRenderable = nullptr;
gfx::RenderingStats stats;