fix only msaa depth texutre in frame buffer error on iOS platform (#2725)

This commit is contained in:
Kitchen
2022-02-09 22:29:14 +08:00
committed by GitHub
parent 86b027763a
commit e42fe374c3

View File

@@ -2145,6 +2145,10 @@ namespace bgfx { namespace mtl
{
const TextureMtl& texture = m_textures[frameBuffer.m_depthHandle.idx];
pd.depthAttachmentPixelFormat = texture.m_ptr.m_obj.pixelFormat;
pd.sampleCount = NULL != texture.m_ptrMsaa
? texture.m_ptrMsaa.sampleCount()
: 1
;
if (NULL != texture.m_ptrStencil)
{
pd.stencilAttachmentPixelFormat = texture.m_ptrStencil.m_obj.pixelFormat;