Ver Fonte

Added invalidation of renderpipeline state cache. In case the program object gets re-used the cache can return invalid instances of the descriptor.

Marco Weber há 10 anos atrás
pai
commit
1638d797eb
1 ficheiros alterados com 2 adições e 0 exclusões
  1. 2 0
      src/renderer_mtl.mm

+ 2 - 0
src/renderer_mtl.mm

@@ -1453,6 +1453,8 @@ namespace bgfx { namespace mtl
 
 		m_processedUniforms = false;
 		m_numPredefined = 0;
+
+		m_renderPipelineStateCache.invalidate();
 	}
 
 	UniformType::Enum convertMtlType(MTLDataType _type)