mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-06-03 12:27:21 +12:00
Immediate mode vertex submission attempt 1
This commit is contained in:
parent
6ecdf71dbc
commit
922424b8d0
4 changed files with 61 additions and 10 deletions
|
@ -22,6 +22,11 @@ class GPU {
|
|||
std::array<u32, regNum> regs; // GPU internal registers
|
||||
std::array<vec4f, 16> currentAttributes; // Vertex attributes before being passed to the shader
|
||||
|
||||
std::array<vec4f, 16> immediateModeAttributes; // Vertex attributes uploaded via immediate mode submission
|
||||
std::array<Vertex, 3> immediateModeVertices;
|
||||
uint immediateModeVertIndex;
|
||||
uint immediateModeAttrIndex; // Index of the immediate mode attribute we're uploading
|
||||
|
||||
template <bool indexed>
|
||||
void drawArrays();
|
||||
|
||||
|
@ -53,7 +58,7 @@ class GPU {
|
|||
std::array<u32, 3> fixedAttrBuff; // Buffer to hold fixed attributes in until they get submitted
|
||||
|
||||
Renderer renderer;
|
||||
|
||||
Vertex getImmediateModeVertex();
|
||||
public:
|
||||
GPU(Memory& mem);
|
||||
void initGraphicsContext() { renderer.initGraphicsContext(); }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue