Protect the _programSet in Shader with a mutex.
This prevents thread safety issues when Shader objects are used in multiple programs.
This commit is contained in:
committed by
Robert Osfield
parent
a06fcbe5d9
commit
6ae1139630
@@ -306,6 +306,7 @@ class OSG_EXPORT Shader : public osg::Object
|
||||
/** osg::Programs that this osg::Shader is attached to */
|
||||
typedef std::set< osg::Program* > ProgramSet;
|
||||
ProgramSet _programSet;
|
||||
OpenThreads::Mutex _programSetMutex;
|
||||
mutable osg::buffered_value< osg::ref_ptr<ShaderObjects> > _pcsList;
|
||||
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user