Damn, hit the send key... continuing on ...
osg::Viewer viewer;
...
while (!viewer.done())
{
... setMyFrameStamp appropriately ...
viewer.frame(myFrameStamp);
}
Obviously the Viewer shouldn't be using this frame stamp to do things
like calculate statistics etc. In fact I don't think that there is any
good reason to expose the FrameStamps that are being used internally
for doing things like calculating statistics.
So, maybe viewer.frame() should use an internal notion of time, "real"
time, and a method viewer.frame(frameStamp) would pass a frameStamp
into the update traversals. In general I think it makes sense to
completely separate the notions of time, one for internal
housekeeping, and another that is passed into update traversals. It
will certainly make it easier to do things like pause animations,
flythroughs etc without having every time driven
updatevisitor/callback pair having it's own separate time management
systems. Thoughts ?
-Drew
On 1/24/07, Drew Whitehouse <[EMAIL PROTECTED]> wrote:
I'm currently moving over from osgProducer to osgViewer and I'm
wondering how to achieve the ability to control the time being passed
into the scene's update traversal. My application is frame driven and
I want to be able to control the time that the scene is evaluated at
in such a way that I can slow down, speed up, and even reverse the
direction of the time. At the moment it seems that the Viewers notion
of time is passed down into the SceneView's. I need the two to be
quite separate, so that I can do something like
osg::Viewer viewer;
...
while (!viewer.done())
{
}
-Drew
--
Drew Whitehouse
ANU Supercomputer Facility Vizlab
--
Drew Whitehouse
ANU Supercomputer Facility Vizlab
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/