OpcodeDecoder: provide default GetVertexSize() implementation

This commit is contained in:
Tillmann Karras 2025-08-17 10:30:32 +01:00
commit 37758fa290
4 changed files with 5 additions and 21 deletions

View file

@ -111,7 +111,11 @@ public:
// Get the current CP state. Needed for vertex decoding; will also be mutated for CP commands.
virtual CPState& GetCPState() = 0;
virtual u32 GetVertexSize(u8 vat) = 0;
virtual u32 GetVertexSize(u8 vat)
{
const CPState& cpmem = GetCPState();
return VertexLoaderBase::GetVertexSize(cpmem.vtx_desc, cpmem.vtx_attr[vat]);
}
#endif
};