Skip to content
Snippets Groups Projects
Unverified Commit 37e1ed37 authored by bunnei's avatar bunnei Committed by GitHub
Browse files

Merge pull request #991 from bunnei/ignore-mac

maxwell_3d: Ignore macros that have not been uploaded yet.
parents 75e12a33 efe6b473
No related branches found
No related tags found
No related merge requests found
...@@ -23,12 +23,17 @@ Maxwell3D::Maxwell3D(VideoCore::RasterizerInterface& rasterizer, MemoryManager& ...@@ -23,12 +23,17 @@ Maxwell3D::Maxwell3D(VideoCore::RasterizerInterface& rasterizer, MemoryManager&
: memory_manager(memory_manager), rasterizer{rasterizer}, macro_interpreter(*this) {} : memory_manager(memory_manager), rasterizer{rasterizer}, macro_interpreter(*this) {}
void Maxwell3D::CallMacroMethod(u32 method, std::vector<u32> parameters) { void Maxwell3D::CallMacroMethod(u32 method, std::vector<u32> parameters) {
auto macro_code = uploaded_macros.find(method); // Reset the current macro.
executing_macro = 0;
// The requested macro must have been uploaded already. // The requested macro must have been uploaded already.
ASSERT_MSG(macro_code != uploaded_macros.end(), "Macro %08X was not uploaded", method); auto macro_code = uploaded_macros.find(method);
if (macro_code == uploaded_macros.end()) {
LOG_ERROR(HW_GPU, "Macro {:04X} was not uploaded", method);
return;
}
// Reset the current macro and execute it. // Execute the current macro.
executing_macro = 0;
macro_interpreter.Execute(macro_code->second, std::move(parameters)); macro_interpreter.Execute(macro_code->second, std::move(parameters));
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment