Hi Alfonso, I still find it curious that your timer is so erratic, the problems that you are having certainly aren't something that lots of people have problems with, yet the task of moving objects around is very common indeed.
Robert. On Mon, Jan 26, 2009 at 11:02 AM, Alfonso Callejo Goena <[email protected]> wrote: > Hi Robert: > > I have two ways of performing the displacement: > > -- time = nv->getFrameStamp()->getSimulationTime(); > mT.makeTranslate( vehSpeed*time, 0., 0. ); > > -- mT.makeTranslate( dist, 0., 0. ); > dist=dist+avgTime*vehSpeed; // avgTime is the average time per callback > > In the first case jumps appear regardless the vsync is on or off. > In the second case jumps don't appear but, whenever the framerate changes > (for instance by turning vsync off framerate turns from 60 to 160 fps), the > avgTime needs to be recomputed in order to keep the desired velocity. > I think I'm going to adopt the second strategy, but I am still wondering why > the first one doesn't work. > > Thank you, > Alfonso > _______________________________________________ > osg-users mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > > _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

