Re: [info-performer] Counting polygons

Date view Thread view Subject view Author view

From: Paolo Farinelli (paolo++at++sgi.com)
Date: 07/22/2003 13:27:12


Hi Christopher,

take a look at the man pages for pfStats. The PFSTATS_GFX_GEOM
mode counts geometry that is drawn via pfGeoSet::draw.

Hope this helps,
Regards,
Paolo

Dorosky, Christopher G wrote:

>I would like to count how many polygons are displayed, within a generic model.
>There are lots of these models, and they all have LOD's.
>
>The brute force approach is to count the number of polygons in each geoset, for each LOD, and figure out how many would be displayed for each given LOD combination.
>
>Is there a way, with a pre and post draw callback, to count the number of polygons that we actually draw, per model, per frame?
>IE.
>predraw and postdraw are node callbacks, with the node being a model.
>
>predraw()
>{
> glStartCounter();
>}
>postdraw()
>{
> printf("The number of polygons in the model just drawn is %d\n", glStopCount());
>}
>
>pf stuff would be fine as well.
>
>Thanks!
>
>Christopher Dorosky
>Staff Research Engineer - Real Time Simulation, TOPSCENE
>Lockheed Martin Missiles and Fire Control - Dallas
>christopher.g.dorosky++at++lmco.com
>972-603-2349
>
>-----------------------------------------------------------------------
> List Archives, Info, FAQ: http://www.sgi.com/software/performer/
> Open Development Project: http://oss.sgi.com/projects/performer/
> Submissions: info-performer++at++sgi.com
> Admin. requests: info-performer-request++at++sgi.com
>-----------------------------------------------------------------------
> SIGGRAPH 2003 Friends of Performer Meeting:
> Wednesday July 30 6:00pm San Diego Hilton Hotel Santa Rosa Room
>-----------------------------------------------------------------------
>
>
>
>

-- 
Paolo Farinelli                                           paolo++at++sgi.com
Member of Technical Staff, OpenGL Performer              1-650-933-1808
Silicon Graphics        1600 Amphitheatre Pkwy, Mountain View, CA 94043


Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Tue Jul 22 2003 - 13:27:21 PDT