]> git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
add missing R_Mesh_ResetTextureState call (to fix CSQC polygon rendering)
authordivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 24 Aug 2008 14:57:06 +0000 (14:57 +0000)
committerdivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 24 Aug 2008 14:57:06 +0000 (14:57 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@8474 d7cf8633-e32d-0410-b094-e92efae38249

clvm_cmds.c

index 5ed6a046fdd3ed9e621feafa9e41d16476d6b6cd..fb5a7e597146956c9415c4cedb3b324885ef944e 100644 (file)
@@ -2463,12 +2463,14 @@ static void VM_DrawPolygonCallback (const entity_render_t *ent, const rtlight_t
 {
        int surfacelistindex;
        vmpolygons_t* polys = vmpolygons + PRVM_GetProgNr();
+       R_Mesh_ResetTextureState();
        R_Mesh_Matrix(&identitymatrix);
        GL_CullFace(GL_NONE);
        R_Mesh_VertexPointer(polys->data_vertex3f, 0, 0);
        R_Mesh_ColorPointer(polys->data_color4f, 0, 0);
        R_Mesh_TexCoordPointer(0, 2, polys->data_texcoord2f, 0, 0);
        R_SetupGenericShader(true);
+
        for (surfacelistindex = 0;surfacelistindex < numsurfaces;)
        {
                int numtriangles = 0;