Hi Matt,
I have RSI right now, so can't go in to long replies.
A couple of pointers. The OSG can be used in many different ways, its
very much a general purpose graphics toolkit, and isn't specialized
for any particular domain, its also an advanced toolkit - one used in
professional simulators the world over. This means many classes are
deliberately loosely coupled, and less focused on high level helpers
than more domain specific or more entry level toolkits. This will
mean the learning curve may well be pretty steep, but the payback is
that it'll be a toolkit that you won't out grow any time soon.
As for event loops, well in vis-sim you have a frame-loop rather than
an event loop, with the events being captured in a separate thread or
polled on each new frame, this is difference is down the importance of
hitting a solid 60Hz. Event driven apps are very poor a hitting
constant frame rates.
The OSG can be used either with frame driven or event driven
applications its up to you. The main viewer examples are frame driven
though, but this doesn't preclude the event driven usage.
In dev version of the OSG there is a new osgViewer that replaces
osgProducer are does frame up the frame loop in a convinience method,
but you also can still call the indivdual traversals if you wish.
So... if you like high level stuff then perhaps its more to your
liking:
int main(int, char **)
{
// construct the viewer.
osgViewer::Viewer viewer;
// add model to viewer.
viewer.setSceneData( osg::readNodeFile("cow.osg" ));
return viewer.run();
}
The run method is a frame driven loop rather than an even driven loop,
but in principle its kinda similar idea.
Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/