diff options
Diffstat (limited to 'src/renderergl2/tr_surface.c')
-rw-r--r-- | src/renderergl2/tr_surface.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/renderergl2/tr_surface.c b/src/renderergl2/tr_surface.c index 67b0cce7..e6146eef 100644 --- a/src/renderergl2/tr_surface.c +++ b/src/renderergl2/tr_surface.c @@ -92,6 +92,8 @@ void RB_AddQuadStampExt( vec3_t origin, vec3_t left, vec3_t up, float color[4], uint32_t pNormal; int ndx; + RB_CheckVao(tess.vao); + RB_CHECKOVERFLOW( 4, 6 ); ndx = tess.numVertexes; @@ -284,6 +286,8 @@ static void RB_SurfacePolychain( srfPoly_t *p ) { int i; int numv; + RB_CheckVao(tess.vao); + RB_CHECKOVERFLOW( p->numVerts, 3*(p->numVerts - 2) ); // fan triangles into the tess array @@ -627,6 +631,8 @@ static void DoRailCore( const vec3_t start, const vec3_t end, const vec3_t up, f int vbase; float t = len / 256.0f; + RB_CheckVao(tess.vao); + RB_CHECKOVERFLOW( 4, 6 ); vbase = tess.numVertexes; @@ -708,6 +714,8 @@ static void DoRailDiscs( int numSegs, const vec3_t start, const vec3_t dir, cons } } + RB_CheckVao(tess.vao); + for ( i = 0; i < numSegs; i++ ) { int j; @@ -1219,6 +1227,8 @@ static void RB_SurfaceMesh(mdvSurface_t *surface) { backlerp = backEnd.currentEntity->e.backlerp; } + RB_CheckVao(tess.vao); + RB_CHECKOVERFLOW( surface->numVerts, surface->numIndexes ); LerpMeshVertexes (surface, backlerp); @@ -1326,6 +1336,8 @@ static void RB_SurfaceGrid( srfBspSurface_t *srf ) { return; } + RB_CheckVao(tess.vao); + dlightBits = srf->dlightBits; tess.dlightBits |= dlightBits; |