diff --git a/src/gl/compatibility/gl_20.cpp b/src/gl/compatibility/gl_20.cpp index c1ba2d2db..f05256452 100644 --- a/src/gl/compatibility/gl_20.cpp +++ b/src/gl/compatibility/gl_20.cpp @@ -773,7 +773,7 @@ void GLWall::RenderLightsCompat(int pass) if (PrepareLight(light, pass)) { vertcount = 0; - RenderWall(RWF_TEXTURED, NULL); + RenderWall(RWF_TEXTURED); } node = node->nextLight; } diff --git a/src/gl/scene/gl_portal.cpp b/src/gl/scene/gl_portal.cpp index 559c14976..bb7166805 100644 --- a/src/gl/scene/gl_portal.cpp +++ b/src/gl/scene/gl_portal.cpp @@ -152,7 +152,9 @@ void GLPortal::DrawPortalStencil() for (unsigned int i = 0; imVBO->RenderArray(GL_TRIANGLE_FAN, offset, count); - vertexcount += count; - } - if (store != NULL) - { - store[0] = offset; - store[1] = count; - } + GLRenderer->mVBO->RenderArray(GL_TRIANGLE_FAN, vertindex, vertcount); + vertexcount += vertcount; } //==========================================================================