mirror of
https://github.com/bkaradzic/bgfx.git
synced 2026-02-20 22:03:12 +01:00
Release all swapchain resources on destruction
This commit is contained in:
@@ -2817,11 +2817,18 @@ namespace bgfx { namespace mtl
|
||||
|
||||
SwapChainMtl::~SwapChainMtl()
|
||||
{
|
||||
MTL_RELEASE(m_backBufferDepth);
|
||||
if (BX_ENABLED(BX_PLATFORM_IOS) )
|
||||
{
|
||||
MTL_RELEASE(m_backBufferStencil);
|
||||
if(m_drawable != nil) {
|
||||
release(m_drawable);
|
||||
m_drawable = nil;
|
||||
}
|
||||
|
||||
MTL_RELEASE(m_backBufferDepth);
|
||||
MTL_RELEASE(m_backBufferStencil);
|
||||
if (NULL != m_backBufferColorMsaa)
|
||||
{
|
||||
MTL_RELEASE(m_backBufferColorMsaa);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void SwapChainMtl::init(void* _nwh)
|
||||
|
||||
Reference in New Issue
Block a user