Hi, I have a number of actors that I want to add text labels to. The text labels should be screen aligned with a fixed size. I want the text to stay 50 pixels above the center of the actor, so that the actor is not obscured by text when I am far away. Is this possible? There is a method osgText::TextBase::setPosition that I can use to add a height in scene coordinates, but I would like to add an offset to the text bounding box.
Ideally i would do this: osgText::Text* text = new osgText::Text(); text->setText("My Actor"); text->setAlignment(osgText::TextBase::LEFT_TOP); text->setAxisAlignment(osgText::TextBase::SCREEN); text->setCharacterSizeMode(osgText::TextBase::SCREEN_COORDS); // center is one meter above actor coordinate center text->setPosition(osg::Vec3(0, 0, 1)); // push text 20 pixels to left and 30 upwards text->setOffset(osg::Vec3(-20, 0, 30)); Any idea on how to accomplish this? Thank you! Cheers, Martin ------------------ Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=31026#31026 _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org