2008/1/16 GuiYe <[EMAIL PROTECTED]>:
>
>
>
>   Hello,robert!
>   I want to use the code:
>
>
> >    osgProducer::Viewer::SceneHandlerList::iterator sh_it =
> > viewer.getSceneHandlerList().begin();
> >    osgProducer::OsgSceneHandler* sh =sh_it->get();
>
>
> to  load the nodes from the commandline arguments.
>
>   What should I do ?

To assign a loaded file :

  viewer.setSceneData(osgDB::readNodeFile("cow.osg"));

To assign files loaded from command line

  osg::ArgumentParser arguments(&argc,argv)
  viewer.setSceneData(osgDB::readNodeFile(arguments));

All of this is exactly the same as in 1.2 osgProducer::Viewer, and
exactly how almost all the OSG examples do things.  None have anything
whatsoever to do with OsgSceneHandler which makes me perplexed about
exactly what you were trying to do.

Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to