mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2025-10-13 00:07:47 +00:00
Shader_IR: add the ability to amend code in the shader ir.
This commit introduces a mechanism by which shader IR code can be amended and extended. This useful for track algorithms where certain information can derived from before the track such as indexes to array samplers.
This commit is contained in:
parent
b6825f4b37
commit
a4d446291d
5 changed files with 72 additions and 3 deletions
|
@ -446,4 +446,10 @@ Node ShaderIR::BitfieldInsert(Node base, Node insert, u32 offset, u32 bits) {
|
|||
Immediate(bits));
|
||||
}
|
||||
|
||||
u32 ShaderIR::DeclareAmend(Node new_amend) {
|
||||
const u32 id = static_cast<u32>(amend_code.size());
|
||||
amend_code.push_back(new_amend);
|
||||
return id;
|
||||
}
|
||||
|
||||
} // namespace VideoCommon::Shader
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue