[osg-users] Bug in Viewer::setReferenceTime

Robert Osfield robert.osfield at gmail.com
Sun Jun 7 04:14:15 PDT 2015

Hi Benjamin,

Well spotted, can't believe how long that bug will have been lurking
without being picked up.  I've applied your suggested fix to
CompositeViewer and Viewer in OSG-svn/trunk and the OSG-3.2 branch.


On 6 June 2015 at 21:44, Benjamin Richter <br at waldteufel.eu> wrote:
> Hi everybody.
> I was having some trouble with Viewer::setReferenceTime today and while
> debugging found the issue in the following line [1]
> double delta_ticks =
> (time-currentTime)*(osg::Timer::instance()->getSecondsPerTick());
> As currentTime and time are given in seconds (see link below for context)
> but the result should be in ticks, dividing by getSecondsPerTick would be
> correct.
> (Apart from that: Thank you for this great library :D)
> Regards
> Benjamin
> [1]
> https://github.com/openscenegraph/osg/blob/3c55e5bc765aff03ed0850ef9b9b62dc6aabe6a8/src/osgViewer/Viewer.cpp#L446
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

More information about the osg-users mailing list