- Main Page
- Modules
- Namespaces
- Classes
- Files
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# osgDB::SharedStateManager Class Reference

Inheritance diagram for osgDB::SharedStateManager:

[legend]
List of all members.

## Public Types
enum | ShareMode { SHARE_NONE = 0x00, SHARE_TEXTURES = 0x01, SHARE_STATESETS = 0x02, SHARE_ALL }
## Public Member Functions
| SharedStateManager ()
void | setShareMode (unsigned int mode)
unsigned int | getShareMode ()
void | prune ()
void | share (osg::Node *node, OpenThreads::Mutex *mt=0)
void | apply (osg::Node &node)
void | apply (osg::Geode &geode)
## Protected Types
typedef std::set< osg::ref_ptr< osg::StateAttribute > > | TextureSet
typedef std::set< osg::ref_ptr< osg::StateSet > > | StateSetSet
typedef std::pair< osg::StateAttribute *, bool > | TextureSharePair
typedef std::map< osg::StateAttribute *, TextureSharePair > | TextureTextureSharePairMap
typedef std::pair< osg::StateSet *, bool > | StateSetSharePair
typedef std::map< osg::StateSet *, StateSetSharePair > | StateSetStateSetSharePairMap
## Protected Member Functions
void | process (osg::StateSet *ss, osg::Object *parent)
osg::StateAttribute * | find (osg::StateAttribute *sa)
osg::StateSet * | find (osg::StateSet *ss)
void | setStateSet (osg::StateSet *ss, osg::Object *object)
void | shareTextures (osg::StateSet *ss)
## Protected Attributes
TextureSet | _sharedTextureList
StateSetSet | _sharedStateSetList
TextureTextureSharePairMap | tmpSharedTextureList
StateSetStateSetSharePairMap | tmpSharedStateSetList
unsigned int | shareMode
OpenThreads::Mutex * | mutex

## Member Typedef Documentation

typedef std::set< osg::ref_ptr<osg::StateSet> > osgDB::SharedStateManager::StateSetSet`[protected]`

typedef std::pair<osg::StateSet*, bool> osgDB::SharedStateManager::StateSetSharePair`[protected]`

typedef std::map<osg::StateSet*, StateSetSharePair> osgDB::SharedStateManager::StateSetStateSetSharePairMap`[protected]`

typedef std::set< osg::ref_ptr<osg::StateAttribute> > osgDB::SharedStateManager::TextureSet`[protected]`

typedef std::pair<osg::StateAttribute*, bool> osgDB::SharedStateManager::TextureSharePair`[protected]`

typedef std::map<osg::StateAttribute*, TextureSharePair> osgDB::SharedStateManager::TextureTextureSharePairMap`[protected]`

## Member Enumeration Documentation

enum osgDB::SharedStateManager::ShareMode

  | Enumerator:
  SHARE_NONE |
  SHARE_TEXTURES |
  SHARE_STATESETS |
  SHARE_ALL |

## Constructor & Destructor Documentation

SharedStateManager::SharedStateManager | ( |  | ) |

## Member Function Documentation

void SharedStateManager::apply | ( | osg::Geode & | geode | ) | `[virtual]`

| Reimplemented from osg::NodeVisitor.

void SharedStateManager::apply | ( | osg::Node & | node | ) | `[virtual]`

| Reimplemented from osg::NodeVisitor.

osg::StateSet * SharedStateManager::find | ( | osg::StateSet * | ss | ) | `[inline, protected]`

osg::StateAttribute * SharedStateManager::find | ( | osg::StateAttribute * | sa | ) | `[inline, protected]`

unsigned int osgDB::SharedStateManager::getShareMode | ( |  | ) | `[inline]`

void SharedStateManager::process | ( | osg::StateSet * | ss,
|  | osg::Object * | parent
| ) | `[protected]`

void SharedStateManager::prune | ( |  | ) |

void osgDB::SharedStateManager::setShareMode | ( | unsigned int | mode | ) | `[inline]`

void SharedStateManager::setStateSet | ( | osg::StateSet * | ss,
|  | osg::Object * | object
| ) | `[inline, protected]`

void SharedStateManager::share | ( | osg::Node * | node,
|  | OpenThreads::Mutex * | mt = `0`
| ) |

void SharedStateManager::shareTextures | ( | osg::StateSet * | ss | ) | `[inline, protected]`

## Member Data Documentation

StateSetSet osgDB::SharedStateManager::_sharedStateSetList`[protected]`

TextureSet osgDB::SharedStateManager::_sharedTextureList`[protected]`

OpenThreads::Mutex* osgDB::SharedStateManager::mutex`[protected]`

unsigned int osgDB::SharedStateManager::shareMode`[protected]`

StateSetStateSetSharePairMap osgDB::SharedStateManager::tmpSharedStateSetList`[protected]`

TextureTextureSharePairMap osgDB::SharedStateManager::tmpSharedTextureList`[protected]`

The documentation for this class was generated from the following files:

- SharedStateManager
- SharedStateManager.cpp