OpenMW
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | Private Member Functions | Private Attributes | List of all members
Resource::ResourceSystem Class Reference

Wrapper class that constructs and provides access to the most commonly used resource subsystems. More...

#include <resourcesystem.hpp>

Collaboration diagram for Resource::ResourceSystem:

Public Member Functions

 ResourceSystem (const VFS::Manager *vfs)
 
 ~ResourceSystem ()
 
SceneManagergetSceneManager ()
 
ImageManagergetImageManager ()
 
NifFileManagergetNifFileManager ()
 
KeyframeManagergetKeyframeManager ()
 
void updateCache (double referenceTime)
 
void addResourceManager (ResourceManager *resourceMgr)
 
void removeResourceManager (ResourceManager *resourceMgr)
 
void setExpiryDelay (double expiryDelay)
 How long to keep objects in cache after no longer being referenced. More...
 
const VFS::ManagergetVFS () const
 

Private Member Functions

 ResourceSystem (const ResourceSystem &)
 
void operator= (const ResourceSystem &)
 

Private Attributes

std::auto_ptr< SceneManagermSceneManager
 
std::auto_ptr< ImageManagermImageManager
 
std::auto_ptr< NifFileManagermNifFileManager
 
std::auto_ptr< KeyframeManagermKeyframeManager
 
std::vector< ResourceManager * > mResourceManagers
 
const VFS::ManagermVFS
 

Detailed Description

Wrapper class that constructs and provides access to the most commonly used resource subsystems.

Resource subsystems can be used with multiple OpenGL contexts, just like the OSG equivalents, but
are built around the use of a single virtual file system.

Constructor & Destructor Documentation

Resource::ResourceSystem::ResourceSystem ( const VFS::Manager vfs)

Here is the call graph for this function:

Resource::ResourceSystem::~ResourceSystem ( )
Resource::ResourceSystem::ResourceSystem ( const ResourceSystem )
private

Member Function Documentation

void Resource::ResourceSystem::addResourceManager ( ResourceManager resourceMgr)

Add this ResourceManager to be handled by the ResourceSystem.

Note
Does not transfer ownership.

Here is the caller graph for this function:

ImageManager * Resource::ResourceSystem::getImageManager ( )

Here is the caller graph for this function:

KeyframeManager * Resource::ResourceSystem::getKeyframeManager ( )

Here is the caller graph for this function:

NifFileManager * Resource::ResourceSystem::getNifFileManager ( )
SceneManager * Resource::ResourceSystem::getSceneManager ( )

Here is the caller graph for this function:

const VFS::Manager * Resource::ResourceSystem::getVFS ( ) const
Note
May be called from any thread.

Here is the caller graph for this function:

void Resource::ResourceSystem::operator= ( const ResourceSystem )
private
void Resource::ResourceSystem::removeResourceManager ( ResourceManager resourceMgr)
Note
Do nothing if resourceMgr does not exist.
Does not delete resourceMgr.

Here is the caller graph for this function:

void Resource::ResourceSystem::setExpiryDelay ( double  expiryDelay)

How long to keep objects in cache after no longer being referenced.

Here is the caller graph for this function:

void Resource::ResourceSystem::updateCache ( double  referenceTime)

Indicates to each resource manager to clear the cache, i.e. to drop cached objects that are no longer referenced.

Note
May be called from any thread if you do not add or remove resource managers at that point.

Here is the caller graph for this function:

Member Data Documentation

std::auto_ptr<ImageManager> Resource::ResourceSystem::mImageManager
private
std::auto_ptr<KeyframeManager> Resource::ResourceSystem::mKeyframeManager
private
std::auto_ptr<NifFileManager> Resource::ResourceSystem::mNifFileManager
private
std::vector<ResourceManager*> Resource::ResourceSystem::mResourceManagers
private
std::auto_ptr<SceneManager> Resource::ResourceSystem::mSceneManager
private
const VFS::Manager* Resource::ResourceSystem::mVFS
private

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