Browse Source

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 10 years ago
parent
commit
1638d797eb
1 changed files with 2 additions and 0 deletions
  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)