- improve sector portals rendering in softpoly

- fix a softpoly memory leak and change vertex list to be allocated using the frame allocator
This commit is contained in:
Magnus Norddahl 2017-03-24 07:28:28 +01:00
commit f178646e1a
13 changed files with 98 additions and 131 deletions

View file

@ -102,9 +102,7 @@ void RenderPolyDecal::Render(const TriMatrix &worldToClip, const Vec4f &clipPlan
DVector2 points[2] = { decal_left, decal_right };
TriVertex *vertices = PolyVertexBuffer::GetVertices(4);
if (!vertices)
return;
TriVertex *vertices = PolyRenderer::Instance()->FrameMemory.AllocMemory<TriVertex>(4);
bool foggy = false;
int actualextralight = foggy ? 0 : PolyRenderer::Instance()->Viewpoint.extralight << 4;