diff options
author | StapleButter <thetotalworm@gmail.com> | 2017-02-10 16:50:26 +0100 |
---|---|---|
committer | StapleButter <thetotalworm@gmail.com> | 2017-02-10 16:50:26 +0100 |
commit | 78f49d061a1c5d1c3056244db42f2f00bed29c6b (patch) | |
tree | 300c615b1b7252bce1a021ec168f2eb9d75b0c69 /GPU3D.cpp | |
parent | c95f7578bbf3c9cec96b341474b3ca73159c791d (diff) |
base for software renderer
Diffstat (limited to 'GPU3D.cpp')
-rw-r--r-- | GPU3D.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -177,11 +177,15 @@ bool Init() CmdFIFO = new FIFO<CmdFIFOEntry>(256); CmdPIPE = new FIFO<CmdFIFOEntry>(4); + if (!SoftRenderer::Init()) return false; + return true; } void DeInit() { + SoftRenderer::DeInit(); + delete CmdFIFO; delete CmdPIPE; } @@ -228,6 +232,8 @@ void Reset() CurPolygonRAM = &PolygonRAM[0]; NumVertices = 0; NumPolygons = 0; + + SoftRenderer::Reset(); } @@ -1152,7 +1158,8 @@ void CheckFIFODMA() void VBlank() { - // TODO: render + // TODO: only do this if a SwapBuffers command was issued + SoftRenderer::RenderFrame(CurVertexRAM, CurPolygonRAM, NumPolygons); CurRAMBank = CurRAMBank?0:1; CurVertexRAM = &VertexRAM[CurRAMBank ? 6144 : 0]; |