- backend update from GZDoom.

This commit is contained in:
Christoph Oelckers 2021-02-12 14:44:54 +01:00
parent 5b6aa372ea
commit c96e04e6c9
28 changed files with 352 additions and 119 deletions

View file

@ -2,7 +2,6 @@
#define __GL_CLOCK_H
#include "stats.h"
#include "x86.h"
#include "m_fixed.h"
extern glcycle_t RenderWall,SetupWall,ClipWall;

View file

@ -183,12 +183,14 @@ void Draw2D(F2DDrawer *drawer, FRenderState &state)
state.SetVertexBuffer(&cmd.shape2D->buffers[cmd.shape2DBufIndex]);
state.DrawIndexed(DT_Triangles, 0, cmd.shape2DIndexCount);
state.SetVertexBuffer(&vb);
if (cmd.shape2D->bufIndex > 0 && cmd.shape2DBufIndex == cmd.shape2D->bufIndex)
if (cmd.shape2D->bufIndex > 0 && cmd.shapeLastCmd)
{
cmd.shape2D->needsVertexUpload = true;
cmd.shape2D->buffers.Clear();
cmd.shape2D->lastCommand = nullptr;
cmd.shape2D->bufIndex = -1;
}
cmd.shape2D->uploadedOnce = false;
}
else
{