Hi Bob, The performance of creating the labels is an oddity, 5000 labels is quite a few but surprised it's taking that long. I don't have any suggestions as to what is causing things to be so long.
For the type of task you have a general purpose text class like osgText::Text will not be the most efficient way to implement what you need. It will be possible to implement it with custom shaders and osg::Geometry and use the osgText::Font to provide the Texture. You can do a lot of text setup in vertex shader, and even look up glyph coords in the vertex shader and map an index value to all the glyphs required. The custom approach will be really light weight but it requires more knowledge of shaders and how to set everything up in the scene graph, so it'll be a lot more work. The most effective use of your time would probably be to profile your application when it's setting up the text, there could be something happening that is cause a big bottleneck. If it turns out the bottleneck is within the OSG then creating an example that illustrates the bottleneck would be useful as it'll enable others to try it out and provide insight to what could be done differently. Cheers, Robert. -- You received this message because you are subscribed to the Google Groups "OpenSceneGraph Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/osg-users/CAFN7Y%2BXvXZERT2wbNUCGOHhxkUtv_r__DwQkxBK2zSOmKc%3DRRg%40mail.gmail.com.
