Number of vertices

Hi, is there any way to count the number of displayed vertices ???
I mean of course automatic way - cause it’s possible to count it manually for every object. Any ideas ?

You could render all vertices as GL_POINTS without depth-test and do an occlusion query. Since every point should be rendered as exactly one pixel, the result of the query should give you the number of rendered points.

However on ATI cards i encountered that occlusion queries are not reliable in the exact number of fragments counted, so this will not work on all hardware equally precise.

Other than that, i don’t think there is an “automatic” way.

Jan.