Hi Robert,This was a step in the correct direction I think. Adding osg::Referenced::setThreadSafeReferenceCounting(true); solved the problem. I removed all setThreadSafeRefUnref()'s and it was still ok. Maybe setThreadSafeReferenceCounting should be automatically enabled depending on the threading mode.
However, now I observe a crash when I cycle through the modes with 'm' and come back to DrawThreadPerContext mode. Application starts with default threading mode then I set to SingleThreaded in code and then in runtime I go to DrawThreadPerContext again. You can find the stack trace and the code I used as attachment.
HI Tugkan, On 2/23/07, Tugkan Calapoglu <[EMAIL PROTECTED]> wrote:Hi Robert, The message comes from osg::AlphaFunc. I've attached the stack trace. I've added af->setThreadSafeRefUnref( true ) but this didn't change anything. The message still comes and crash occurs with the same stack trace. I've done the same for the state set also and nothing changed.It wonder where this AlphaFunc was attached, it could be its StateSet is the one with the problems with thread safe ref/unref. One thing you could try is sticking a: osg::Referenced::setThreadSafeReferenceCounting(true); At the top of the main. Robert. Robert. _______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/
--
Tugkan Calapoglu
-------------------------------------
VIRES Simulationstechnologie GmbH
Oberaustrasse 34
83026 Rosenheim
Germany
phone +49.8031.463640
fax +49.8031.463645
email [EMAIL PROTECTED]
internet www.vires.com
-------------------------------------
Sitz der Gesellschaft: Rosenheim
Handelsregister Traunstein HRB 10410
Geschaeftsfuehrer: Marius Dupuis
Wunibald Karl
-------------------------------------
stackTrace3.tar.gz
Description: GNU Zip compressed data
osgviewer.cpp.tar.gz
Description: GNU Zip compressed data
_______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/
