[rsx/wip] Dump raw shader, fix typo
This commit is contained in:
@@ -670,8 +670,9 @@ std::string VertexProgramDecompiler::Decompile()
|
|||||||
case RSX_SCA_OPCODE_COS: SetDSTSca("cos($s)"); break;
|
case RSX_SCA_OPCODE_COS: SetDSTSca("cos($s)"); break;
|
||||||
case RSX_SCA_OPCODE_BRB:
|
case RSX_SCA_OPCODE_BRB:
|
||||||
// works differently (BRB o[1].x !b0, L0;)
|
// works differently (BRB o[1].x !b0, L0;)
|
||||||
|
{
|
||||||
LOG_ERROR(RSX, "Unimplemented sca_opcode BRB d0=0x%X, d1=0x%X, d2=0x%X, d3=0x%X", d0.HEX, d1.HEX, d2.HEX, d3.HEX);
|
LOG_ERROR(RSX, "Unimplemented sca_opcode BRB d0=0x%X, d1=0x%X, d2=0x%X, d3=0x%X", d0.HEX, d1.HEX, d2.HEX, d3.HEX);
|
||||||
|
|
||||||
u32 jump_position = find_jump_lvl(GetAddr());
|
u32 jump_position = find_jump_lvl(GetAddr());
|
||||||
|
|
||||||
AddCode("$if (!$bconst) //BRB"); //If only the cond flags are set, we can just use $ifcond
|
AddCode("$if (!$bconst) //BRB"); //If only the cond flags are set, we can just use $ifcond
|
||||||
@@ -683,6 +684,7 @@ std::string VertexProgramDecompiler::Decompile()
|
|||||||
AddCode("}");
|
AddCode("}");
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
}
|
||||||
case RSX_SCA_OPCODE_CLB: break;
|
case RSX_SCA_OPCODE_CLB: break;
|
||||||
// works same as BRB
|
// works same as BRB
|
||||||
LOG_ERROR(RSX, "Unimplemented sca_opcode CLB");
|
LOG_ERROR(RSX, "Unimplemented sca_opcode CLB");
|
||||||
|
|||||||
@@ -382,6 +382,9 @@ GLVertexProgram::~GLVertexProgram()
|
|||||||
|
|
||||||
void GLVertexProgram::Decompile(const RSXVertexProgram& prog)
|
void GLVertexProgram::Decompile(const RSXVertexProgram& prog)
|
||||||
{
|
{
|
||||||
|
fs::create_path(fs::get_config_dir() + "/shaderlog");
|
||||||
|
fs::file(fs::get_config_dir() + "shaderlog/VertexProgram.raw", fs::rewrite).write(prog.data.data(), prog.data.size() * sizeof(u32));
|
||||||
|
|
||||||
GLVertexDecompilerThread decompiler(prog, shader, parr);
|
GLVertexDecompilerThread decompiler(prog, shader, parr);
|
||||||
decompiler.Task();
|
decompiler.Task();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user