mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2025-06-18 21:37:59 -05:00
Rasterizer: Implemented instanced rendering.
We keep track of the current instance and update an uniform in the shaders to let them know which instance they are. Instanced vertex arrays are not yet implemented.
This commit is contained in:
@ -638,6 +638,8 @@ public:
|
||||
union {
|
||||
u32 vertex_begin_gl;
|
||||
BitField<0, 16, PrimitiveTopology> topology;
|
||||
BitField<26, 1, u32> instance_next;
|
||||
BitField<27, 1, u32> instance_cont;
|
||||
};
|
||||
} draw;
|
||||
|
||||
@ -830,6 +832,7 @@ public:
|
||||
};
|
||||
|
||||
std::array<ShaderStageInfo, Regs::MaxShaderStage> shader_stages;
|
||||
u32 current_instance = 0; ///< Current instance to be used to simulate instanced rendering.
|
||||
};
|
||||
|
||||
State state{};
|
||||
|
Reference in New Issue
Block a user