do safety checks before clearing

This commit is contained in:
Samuliak 2024-12-14 11:00:42 +01:00
parent 74a1162a17
commit 137becb894
No known key found for this signature in database
4 changed files with 20 additions and 5 deletions

View file

@ -551,7 +551,6 @@ namespace LatteDecompiler
{
bool isRectVertexShader = (static_cast<LattePrimitiveMode>(decompilerContext->contextRegisters[mmVGT_PRIMITIVE_TYPE]) == LattePrimitiveMode::RECTS);
// TODO: also check for rect primitive
if (decompilerContext->shaderType == LatteConst::ShaderType::Vertex && (decompilerContext->options->usesGeometryShader || isRectVertexShader))
decompilerContext->hasUniformVarBlock = true; // uf_verticesPerInstance
}