mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-02-21 19:31:26 +00:00
Optimization: Don't reset shader program at end of DrawPolygon, instead reset it in UnSetShader
This commit is contained in:
parent
200fbc04ef
commit
0758a8caec
1 changed files with 1 additions and 4 deletions
|
@ -1073,6 +1073,7 @@ EXPORT void HWRAPI(UnSetShader) (void)
|
||||||
#ifdef GL_SHADERS
|
#ifdef GL_SHADERS
|
||||||
gl_shadersenabled = false;
|
gl_shadersenabled = false;
|
||||||
gl_currentshaderprogram = 0;
|
gl_currentshaderprogram = 0;
|
||||||
|
pglUseProgram(0);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2054,10 +2055,6 @@ EXPORT void HWRAPI(DrawPolygon) (FSurfaceInfo *pSurf, FOutVector *pOutVerts, FUI
|
||||||
|
|
||||||
if (PolyFlags & PF_ForceWrapY)
|
if (PolyFlags & PF_ForceWrapY)
|
||||||
Clamp2D(GL_TEXTURE_WRAP_T);
|
Clamp2D(GL_TEXTURE_WRAP_T);
|
||||||
|
|
||||||
#ifdef GL_SHADERS
|
|
||||||
pglUseProgram(0);
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
typedef struct vbo_vertex_s
|
typedef struct vbo_vertex_s
|
||||||
|
|
Loading…
Reference in a new issue