]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - gl_rsurf.c
free the data allocated by font rendering, even if the image is not to be used
[xonotic/darkplaces.git] / gl_rsurf.c
index 2ece8bd0d06e63781bcdf52a8e0eddf4262e73da..9d5bca92fa303c5bfa4e1bc34e12ab55304c66eb 100644 (file)
@@ -957,7 +957,6 @@ static void R_Q1BSP_RecursiveGetLightInfo_BIH(r_q1bsp_getlightinfo_t *info, cons
        int surfaceindex;
        int t;
        int nodeleafindex;
-       const int *nodeleaflist;
        int currentmaterialflags;
        qboolean castshadow;
        msurface_t *surface;
@@ -979,7 +978,6 @@ static void R_Q1BSP_RecursiveGetLightInfo_BIH(r_q1bsp_getlightinfo_t *info, cons
                node = bih->nodes + nodenum;
                if (node->type == BIH_UNORDERED)
                {
-                       nodeleaflist = node->children;
                        for (nodeleafindex = 0;nodeleafindex < BIH_MAXUNORDEREDCHILDREN && node->children[nodeleafindex] >= 0;nodeleafindex++)
                        {
                                leaf = bih->leafs + node->children[nodeleafindex];
@@ -1489,7 +1487,8 @@ void R_Q1BSP_DrawLight(entity_render_t *ent, int numsurfaces, const int *surface
                        for (kend = k;kend < batchnumsurfaces && tex == batchsurfacelist[kend]->texture;kend++)
                                ;
                        // now figure out what to do with this particular range of surfaces
-                       if (!(rsurface.texture->currentmaterialflags & MATERIALFLAG_WALL))
+                       // VorteX: added MATERIALFLAG_NORTLIGHT
+                       if ((rsurface.texture->currentmaterialflags & (MATERIALFLAG_WALL + MATERIALFLAG_NORTLIGHT)) != MATERIALFLAG_WALL)
                                continue;
                        if (r_waterstate.renderingscene && (rsurface.texture->currentmaterialflags & (MATERIALFLAG_WATERSHADER | MATERIALFLAG_REFRACTION | MATERIALFLAG_REFLECTION | MATERIALFLAG_CAMERA)))
                                continue;