On Tue, 2008-11-04 at 10:53 -0500, Jean-Sébastien Guay wrote:
> Hello Wang Rui,
> 
> > They are tessellated at a given detail level, that is, they are all 
> > derived from osg::Geometry and can be regard as geometries. I know it is 
> > more efficient to use geometry shaders, but maybe it is more easier to 
> > save and modify data from vertices arrays, and make the library suitable 
> > for some low level grpahics systems.
> 
> No, that's fine. It would be interesting to provide different rendering 
> implementation back-ends which could be switched at runtime. But doing 
> it as osg::Geometry is fine as a first step.
> 
> > I'm just considering to write a plugin to read curve/surface data file. 
> > Do you know any format that supports parametric curves/surfaces? Does 
> > .osg format support them?
> 
> You can add whatever you want to the .osg format. Have a look at the 
> osgWidget .osg plugin for example, it's a good example of extending the 
> .osg format to support new types of objects.

Everything that's in the osgWidget plugin loader is just a skeleton for
future use, so it would be a great place to start to look and see how
it's done. Just remember, you'll want to dyn_cast<>() your osg::Object
reference to something you can set values on as you read, and as you
write.

> J-S

_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to