<div dir="ltr"><div>thanks Robert ! I am seeing there is an example too for the user stats. Sometimes I am faster by shooting even sample questions to the user list before doing the home work</div><div><br></div><div>Thanks again !</div><div><br></div><div>Nick</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Nov 6, 2017 at 9:37 AM, Robert Osfield <span dir="ltr"><<a href="mailto:robert.osfield@gmail.com" target="_blank">robert.osfield@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Nick,<br>
<br>
On 6 November 2017 at 00:56, Trajce Nikolov NICK<br>
<span><<a href="mailto:trajce.nikolov.nick@gmail.com">trajce.nikolov.nick@gmail.com</a><wbr>> wrote:<br>
> I am trying to measure the time needed to process a frame. My first and<br>
> somewhat naïve approach is to init the timer at the beginning of the frame<br>
> and get the result after the renderingTraversal. But, it seams (and that is<br>
> what I believe it is happening) the rendering traversal is containing the<br>
> swap buffers which is synced with the refresh rate (please correct me if I<br>
> am wrong). Is there something like preswap callback or something like this?<br>
<br>
</span>Are you aware of the osg::Stats data structure and support built into<br>
osgViewer? The StatsHandler.cpp that provides the on-screen stats<br>
enables stats collection and then gets the stats from the osg::Stats<br>
objects. Various parts of the OSG check for the osg::Stats objects<br>
and then fill in the details when required. The osg::Stats objects<br>
are designed to queried by users. Just have a look at how<br>
src/osgViewer/StatsHandler.cpp sets things up.<br>
<br>
Robert<br>
______________________________<wbr>_________________<br>
osg-users mailing list<br>
<a href="mailto:osg-users@lists.openscenegraph.org">osg-users@lists.<wbr>openscenegraph.org</a><br>
<a href="http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org" target="_blank" rel="noreferrer">http://lists.openscenegraph.<wbr>org/listinfo.cgi/osg-users-<wbr>openscenegraph.org</a><br>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">trajce nikolov nick<br></div>
</div>