Hi Javier,

I'm afraid this change will fix your app only to break others
(including existing OSG manipulators/callbacks) that assume that the
event time is based on the ReferenceTime.

Perhaps what is required is to add the current FrameStamp to the
EventQueue and have events record the last assigned FrameNumber,
ReferenceTime and SimulationTime, then allow callbacks/event handlers
to pick which quantity is relevant to them, without making assumptions
about what the time value is.

Robert.

On Sat, Jan 1, 2011 at 11:05 PM, Javier Taibo <[email protected]> wrote:
>   Hi everybody, and happy new year!
>   I needed to capture the frames of an OSG animation at a fixed frame-rate,
> to edit a video with them. After seeking in the list and the web, I found
> that this should be done by calling osgViewer::Viewer::frame() method with
> the correct timing for each frame, the so called "simulation time".
>   It didn't work, and after some debugging, I have found that the Viewer is
> passing the reference time instead of the simulation time. Replacing this
> single line in Viewer.cpp solved the problem for me. Instead of
>     _eventQueue->frame( getFrameStamp()->getReferenceTime() );
>   I put
>     _eventQueue->frame( getFrameStamp()->getSimulationTime() );
>   and the frames' timing is perfect.
>
>   Cheers!
> --
> Javier Taibo
>
>
>
> _______________________________________________
> osg-submissions mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org
>
>
_______________________________________________
osg-submissions mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org

Reply via email to