Benjamin GODIN wrote:
Hello,
I was wondering if there was a way to set an ID to a node.
Then, I could use that ID in my NodeVisitor to refer to an external table which
contains the values to use.
Is it possible ?
In fact, the only thing I have seen in the doc is the possibility to give the
node a name (a String).
What functionality do you need beyond a string? You can attach anything that
derives from Referenced as UserData on anything that derives from Object,
including Node. The osgWorks project defines a RefID class, which is essentially
a reference counted string, for just such a purpose. (See osgworks.googlecode.com.)
--
-Paul Martz Skew Matrix Software
http://www.skew-matrix.com/
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org