[osg-users] OSG 2.1.10 crash in osgText / osgdb_freetyped

Gert van Maren gert at k2vi.com
Fri Sep 14 13:30:00 PDT 2007


Hi Robert,

> Is this in your own application or one of the OSG examples?

It is our own app.

> Are you creating text and then updating per frame?

We're creating text and using UpdateCallback to add.

> Are you running osgViewer multi-threaded?  If so which threading model?

Well when I run dual core the OSG automatically picks the  
DrawThreadPerContext model -> crash. If I turn dual core off ->  
SingleThread no crash.

> One possibility is that the new DrawThreadPerContext threaded model is
> overlapping the drawing of the text with any updating of the text.
> The way to prevent problems like this is to explictly set the data
> variance on the text to DYNAMIC so that the draw traversal knows to
> hold back the next frame till all the dynamic objects have been
> dispatched.  You can ensure this via:
>     myText->setDataVariance(osg::Object::DYNAMIC);

Great, that did the trick

Thanks Robert.




-- 
Gert van Maren

Head of Research & Development
K2Vi Virtual Reality Software
Data Interface Technologies Ltd

Phone: +64 21 2855581
Email: gert at k2vi.com
Web: http://www.k2vi.com




More information about the osg-users mailing list