fix: some Metal validation errors

This commit is contained in:
Samuliak 2024-08-17 17:51:37 +02:00
parent 502d5b8b2f
commit 83a08b2247
9 changed files with 216 additions and 99 deletions

View file

@ -243,6 +243,13 @@ uint64 MetalPipelineCache::CalculatePipelineHash(const LatteFetchShader* fetchSh
stateHash = std::rotl<uint64>(stateHash, 7);
}
if (activeFBO->depthBuffer.texture)
{
auto textureView = static_cast<LatteTextureViewMtl*>(activeFBO->depthBuffer.texture);
stateHash += textureView->GetRGBAView()->pixelFormat();
stateHash = std::rotl<uint64>(stateHash, 7);
}
for (auto& group : fetchShader->bufferGroups)
{
uint32 bufferStride = group.getCurrentBufferStride(lcr.GetRawView());