Update vertex count stats when drawing smooth lines (OGL) (#1932)

The statistics are updated in the generic codepath, which is not used by
RageDisplay_Legacy::DrawLineStripInternal() when rendering smooth lines.

Note, that the output vertex count can differ a lot between smooth lines
(2) and non-smooth lines (~38 output vertices per input vertex), so
updating the statistics can not be done in RageDisplay::DrawLineStrip()
like it is donw for the other draw functions.
This commit is contained in:
Martin Natano
2019-11-14 12:40:35 -08:00
committed by Colby Klein
parent 6a4551f958
commit c5096d24de
+2
View File
@@ -1617,6 +1617,7 @@ void RageDisplay_Legacy::DrawLineStripInternal( const RageSpriteVertex v[], int
/* Draw the line loop: */
SetupVertices( v, iNumVerts );
glDrawArrays( GL_LINE_STRIP, 0, iNumVerts );
StatsAddVerts(iNumVerts);
glDisable( GL_LINE_SMOOTH );
@@ -1642,6 +1643,7 @@ void RageDisplay_Legacy::DrawLineStripInternal( const RageSpriteVertex v[], int
SetupVertices( v, iNumVerts );
glDrawArrays( GL_POINTS, 0, iNumVerts );
StatsAddVerts(iNumVerts);
glDisable( GL_POINT_SMOOTH );
}