Added support for setThreadSafeRefUnref into TexGenNode

This commit is contained in:
Robert Osfield 2007-01-11 10:35:03 +00:00
parent dd958be8a4
commit 5ee30edbea
2 changed files with 10 additions and 0 deletions

View File

@ -60,6 +60,8 @@ class OSG_EXPORT TexGenNode : public Group
/** Get the const TexGen. */
inline const TexGen* getTexGen() const { return _texgen.get(); }
/** Set whether to use a mutex to ensure ref() and unref() are thread safe.*/
virtual void setThreadSafeRefUnref(bool threadSafe);
protected:

View File

@ -56,3 +56,11 @@ void TexGenNode::setTexGen(TexGen* texgen)
{
_texgen = texgen;
}
void TexGenNode::setThreadSafeRefUnref(bool threadSafe)
{
Group::setThreadSafeRefUnref(threadSafe);
if (_texgen.valid()) _texgen->setThreadSafeRefUnref(threadSafe);
}