#include <OgreResourceBackgroundQueue.h>
Inheritance diagram for Ogre::ResourceBackgroundQueue:
Public Member Functions | |
ResourceBackgroundQueue () | |
virtual | ~ResourceBackgroundQueue () |
void | setStartBackgroundThread (bool startThread) |
Sets whether or not a thread should be created and started to handle the background loading, or whether a user thread will call the appropriate hooks. | |
bool | getStartBackgroundThread (void) |
Gets whether or not a thread should be created and started to handle the background loading, or whether a user thread will call the appropriate hooks. | |
virtual void | initialise (void) |
Initialise the background queue system. | |
virtual void | shutdown (void) |
Shut down the background queue system. | |
virtual BackgroundProcessTicket | initialiseResourceGroup (const String &name, Listener *listener=0) |
Initialise a resource group in the background. | |
virtual BackgroundProcessTicket | initialiseAllResourceGroups (Listener *listener=0) |
Initialise all resource groups which are yet to be initialised in the background. | |
virtual BackgroundProcessTicket | prepareResourceGroup (const String &name, Listener *listener=0) |
Prepares a resource group in the background. | |
virtual BackgroundProcessTicket | loadResourceGroup (const String &name, Listener *listener=0) |
Loads a resource group in the background. | |
virtual BackgroundProcessTicket | unload (const String &resType, const String &name, Listener *listener=0) |
Unload a single resource in the background. | |
virtual BackgroundProcessTicket | unload (const String &resType, ResourceHandle handle, Listener *listener=0) |
Unload a single resource in the background. | |
virtual BackgroundProcessTicket | unloadResourceGroup (const String &name, Listener *listener=0) |
Unloads a resource group in the background. | |
virtual BackgroundProcessTicket | prepare (const String &resType, const String &name, const String &group, bool isManual=false, ManualResourceLoader *loader=0, const NameValuePairList *loadParams=0, Listener *listener=0) |
Prepare a single resource in the background. | |
virtual BackgroundProcessTicket | load (const String &resType, const String &name, const String &group, bool isManual=false, ManualResourceLoader *loader=0, const NameValuePairList *loadParams=0, Listener *listener=0) |
Load a single resource in the background. | |
virtual bool | isProcessComplete (BackgroundProcessTicket ticket) |
Returns whether a previously queued process has completed or not. | |
bool | _doNextQueuedBackgroundProcess () |
Process a single queued background operation. | |
void | _initThread () |
Initialise processing for a background thread. | |
virtual void | _queueFireBackgroundPreparingComplete (Resource *res) |
Queue the firing of the 'background preparing complete' event to a Resource::Listener event. | |
virtual void | _queueFireBackgroundLoadingComplete (Resource *res) |
Queue the firing of the 'background loading complete' event to a Resource::Listener event. | |
virtual void | _fireOnFrameCallbacks (void) |
Fires all the queued events for background loaded resources. | |
Singleton (void) | |
void * | operator new (size_t sz, const char *file, int line, const char *func) |
operator new, with debug line info | |
void * | operator new (size_t sz) |
void * | operator new (size_t sz, void *ptr) |
placement operator new | |
void * | operator new[] (size_t sz, const char *file, int line, const char *func) |
array operator new, with debug line info | |
void * | operator new[] (size_t sz) |
void | operator delete (void *ptr) |
void | operator delete (void *ptr, void *) |
void | operator delete (void *ptr, const char *, int, const char *) |
void | operator delete[] (void *ptr) |
void | operator delete[] (void *ptr, const char *, int, const char *) |
Static Public Member Functions | |
static ResourceBackgroundQueue & | getSingleton (void) |
Override standard Singleton retrieval. | |
static ResourceBackgroundQueue * | getSingletonPtr (void) |
Override standard Singleton retrieval. | |
Protected Types | |
typedef std::list< Request > | RequestQueue |
typedef std::map< BackgroundProcessTicket, Request * > | RequestTicketMap |
typedef std::list< QueuedNotification > | NotificationQueue |
enum | RequestType { RT_INITIALISE_GROUP, RT_INITIALISE_ALL_GROUPS, RT_PREPARE_GROUP, RT_PREPARE_RESOURCE, RT_LOAD_GROUP, RT_LOAD_RESOURCE, RT_UNLOAD_GROUP, RT_UNLOAD_RESOURCE, RT_SHUTDOWN } |
Enumerates the type of requests. More... | |
Protected Member Functions | |
virtual OGRE_AUTO_MUTEX void | queueFireBackgroundOperationComplete (Request *req) |
Queue the firing of the 'background loading complete' event to a Resource::Listener event. | |
Protected Attributes | |
RequestQueue | mRequestQueue |
Queue of requests, used to store and order requests. | |
RequestTicketMap | mRequestTicketMap |
Request lookup by ticket. | |
unsigned long | mNextTicketID |
Next ticket ID. | |
NotificationQueue | mNotificationQueue |
Queued notifications of background loading being finished. | |
bool | mStartThread |
Whether this class should start it's own thread or not. | |
void * | mThread |
Dummy. | |
Static Protected Attributes | |
static ResourceBackgroundQueue * | ms_Singleton |
Classes | |
class | Listener |
This abstract listener interface lets you get notifications of completed background processes instead of having to poll ticket statuses. More... | |
struct | QueuedNotification |
Struct that holds details of queued notifications. More... | |
struct | Request |
Encapsulates a queued request for the background queue. More... |
Definition at line 88 of file OgreResourceBackgroundQueue.h.
|
Definition at line 185 of file OgreResourceBackgroundQueue.h. |
|
Definition at line 156 of file OgreResourceBackgroundQueue.h. |
|
Definition at line 157 of file OgreResourceBackgroundQueue.h. |
|
Enumerates the type of requests.
Definition at line 129 of file OgreResourceBackgroundQueue.h. |
|
|
|
|
|
Process a single queued background operation.
|
|
Fires all the queued events for background loaded resources.
|
|
Initialise processing for a background thread.
|
|
Queue the firing of the 'background loading complete' event to a Resource::Listener event.
|
|
Queue the firing of the 'background preparing complete' event to a Resource::Listener event.
|
|
Override standard Singleton retrieval.
Reimplemented from Ogre::Singleton< ResourceBackgroundQueue >. |
|
Override standard Singleton retrieval.
Reimplemented from Ogre::Singleton< ResourceBackgroundQueue >. |
|
Gets whether or not a thread should be created and started to handle the background loading, or whether a user thread will call the appropriate hooks.
Definition at line 255 of file OgreResourceBackgroundQueue.h. |
|
Initialise the background queue system.
|
|
Initialise all resource groups which are yet to be initialised in the background.
|
|
Initialise a resource group in the background.
|
|
Returns whether a previously queued process has completed or not.
|
|
Load a single resource in the background.
|
|
Loads a resource group in the background.
|
|
Definition at line 101 of file OgreMemoryAllocatedObject.h. |
|
Definition at line 95 of file OgreMemoryAllocatedObject.h. |
|
Definition at line 89 of file OgreMemoryAllocatedObject.h. |
|
Definition at line 112 of file OgreMemoryAllocatedObject.h. |
|
Definition at line 106 of file OgreMemoryAllocatedObject.h. |
|
placement operator new
Definition at line 73 of file OgreMemoryAllocatedObject.h. |
|
Definition at line 67 of file OgreMemoryAllocatedObject.h. |
|
operator new, with debug line info
Definition at line 62 of file OgreMemoryAllocatedObject.h. |
|
Definition at line 84 of file OgreMemoryAllocatedObject.h. |
|
array operator new, with debug line info
Definition at line 79 of file OgreMemoryAllocatedObject.h. |
|
Prepare a single resource in the background.
|
|
Prepares a resource group in the background.
|
|
Queue the firing of the 'background loading complete' event to a Resource::Listener event.
|
|
Sets whether or not a thread should be created and started to handle the background loading, or whether a user thread will call the appropriate hooks.
Definition at line 249 of file OgreResourceBackgroundQueue.h. |
|
Shut down the background queue system.
|
|
Definition at line 64 of file OgreSingleton.h. |
|
Unload a single resource in the background.
|
|
Unload a single resource in the background.
|
|
Unloads a resource group in the background.
|
|
Next ticket ID.
Definition at line 166 of file OgreResourceBackgroundQueue.h. |
|
Queued notifications of background loading being finished.
Definition at line 187 of file OgreResourceBackgroundQueue.h. |
|
Queue of requests, used to store and order requests.
Definition at line 160 of file OgreResourceBackgroundQueue.h. |
|
Request lookup by ticket.
Definition at line 163 of file OgreResourceBackgroundQueue.h. |
|
Definition at line 61 of file OgreSingleton.h. |
|
Whether this class should start it's own thread or not.
Definition at line 192 of file OgreResourceBackgroundQueue.h. |
|
Dummy.
Definition at line 207 of file OgreResourceBackgroundQueue.h. |
Copyright © 2008 Torus Knot Software Ltd
This work is licensed under a Creative Commons Attribution-ShareAlike 2.5 License.
Last modified Sat Apr 11 13:52:07 2009