From a6c6ec012ce6d5355b776379ec8b2cbd94552cf3 Mon Sep 17 00:00:00 2001 From: Robin Kertels Date: Thu, 15 Sep 2022 23:38:57 +0200 Subject: VertexLoaderManager: Clean up and slightly speed up with templates --- Source/Core/VideoCommon/OpcodeDecoding.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Source/Core/VideoCommon/OpcodeDecoding.cpp') diff --git a/Source/Core/VideoCommon/OpcodeDecoding.cpp b/Source/Core/VideoCommon/OpcodeDecoding.cpp index 3f90a2b6e3..c8f2f2c53a 100644 --- a/Source/Core/VideoCommon/OpcodeDecoding.cpp +++ b/Source/Core/VideoCommon/OpcodeDecoding.cpp @@ -122,7 +122,7 @@ public: // HACK DataReader src{const_cast(vertex_data), const_cast(vertex_data) + size}; const u32 bytes = - VertexLoaderManager::RunVertices(vat, primitive, num_vertices, src, is_preprocess); + VertexLoaderManager::RunVertices(vat, primitive, num_vertices, src); ASSERT(bytes == size); -- cgit v1.2.3 From 2db74e7f21cdad4abc7f5148ffcdd9e801093b42 Mon Sep 17 00:00:00 2001 From: Robin Kertels Date: Sat, 17 Sep 2022 14:19:13 +0200 Subject: OpcodeDecoding: Get vertex size from the loader --- Source/Core/VideoCommon/OpcodeDecoding.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'Source/Core/VideoCommon/OpcodeDecoding.cpp') diff --git a/Source/Core/VideoCommon/OpcodeDecoding.cpp b/Source/Core/VideoCommon/OpcodeDecoding.cpp index c8f2f2c53a..bc19a1c2de 100644 --- a/Source/Core/VideoCommon/OpcodeDecoding.cpp +++ b/Source/Core/VideoCommon/OpcodeDecoding.cpp @@ -228,6 +228,12 @@ public: return g_main_cp_state; } + OPCODE_CALLBACK(u32 GetVertexSize(u8 vat)) + { + VertexLoaderBase* loader = VertexLoaderManager::RefreshLoader(vat); + return loader->m_vertex_size; + } + u32 m_cycles = 0; bool m_in_display_list = false; }; -- cgit v1.2.3