OGRE  1.9.0
Ogre::Page Class Reference

Page class. More...

#include <OgrePage.h>

Inheritance diagram for Ogre::Page:

Classes

struct  PageData
 
struct  PageRequest
 Structure for holding background page requests. More...
 
struct  PageResponse
 

Public Types

typedef vector< PageContentCollection * >::type ContentCollectionList
 

Public Member Functions

 Page (PageID pageID, PagedWorldSection *parent)
 
virtual ~Page ()
 
void _notifyModified ()
 Tell the page that it is modified.
 
bool canHandleRequest (const WorkQueue::Request *req, const WorkQueue *srcQ)
 WorkQueue::RequestHandler override.
 
bool canHandleResponse (const WorkQueue::Response *res, const WorkQueue *srcQ)
 WorkQueue::ResponseHandler override.
 
virtual PageContentCollectioncreateContentCollection (const String &typeName)
 Create a new PageContentCollection within this page.
 
virtual void destroyAllContentCollections ()
 Destroy all PageContentCollections within this page.
 
virtual void destroyContentCollection (PageContentCollection *coll)
 Destroy a PageContentCollection within this page.
 
virtual void frameEnd (Real timeElapsed)
 Called when the frame ends.
 
virtual void frameStart (Real timeSinceLastFrame)
 Called when the frame starts.
 
virtual PageContentCollectiongetContentCollection (size_t index)
 Get a content collection.
 
virtual size_t getContentCollectionCount () const
 Get the number of content collections.
 
const ContentCollectionListgetContentCollectionList () const
 Get the list of content collections.
 
virtual unsigned long getFrameLastHeld ()
 Get the frame number in which this Page was last loaded or held.
 
virtual PageID getID () const
 Get the ID of this page, unique within the parent.
 
PageManagergetManager () const
 
virtual PagedWorldSectiongetParentSection () const
 Get the PagedWorldSection this page belongs to.
 
SceneManagergetSceneManager () const
 
WorkQueue::ResponsehandleRequest (const WorkQueue::Request *req, const WorkQueue *srcQ)
 WorkQueue::RequestHandler override.
 
void handleResponse (const WorkQueue::Response *res, const WorkQueue *srcQ)
 WorkQueue::ResponseHandler override.
 
bool isDeferredProcessInProgress () const
 If true, it's not safe to access this Page at this time, contents may be changing.
 
virtual bool isHeld () const
 Returns whether this page was 'held' in the last frame, that is was it either directly needed, or requested to stay in memory (held - as in a buffer region for example).
 
bool isModified () const
 
virtual void load (bool synchronous)
 Load this page.
 
virtual void notifyCamera (Camera *cam)
 Notify a section of the current camera.
 
void operator delete (void *ptr)
 
void operator delete (void *ptr)
 
void operator delete (void *ptr, const char *, int, const char *)
 
void operator delete (void *ptr, const char *, int, const char *)
 
void operator delete (void *ptr, void *)
 
void operator delete (void *ptr, void *)
 
void operator delete[] (void *ptr)
 
void operator delete[] (void *ptr)
 
void operator delete[] (void *ptr, const char *, int, const char *)
 
void operator delete[] (void *ptr, const char *, int, const char *)
 
void * operator new (size_t sz)
 
void * operator new (size_t sz)
 
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, const char *file, int line, const char *func)
 operator new, with debug line info
 
void * operator new (size_t sz, void *ptr)
 placement operator new
 
void * operator new (size_t sz, void *ptr)
 placement operator new
 
void * operator new[] (size_t sz)
 
void * operator new[] (size_t sz)
 
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, const char *file, int line, const char *func)
 array operator new, with debug line info
 
virtual void save ()
 Save page data to an automatically generated file name.
 
virtual void save (const String &filename)
 Save page data to a file.
 
virtual void save (StreamSerialiser &stream)
 Save page data to a serialiser.
 
virtual void touch ()
 'Touch' the page to let it know it's being used
 
virtual void unload ()
 Unload this page.
 

Static Public Attributes

static const uint32 CHUNK_CONTENTCOLLECTION_DECLARATION_ID
 
static const uint32 CHUNK_ID
 
static const uint16 CHUNK_VERSION
 
static const uint16 WORKQUEUE_CHANGECOLLECTION_REQUEST
 
static const uint16 WORKQUEUE_PREPARE_REQUEST
 

Protected Member Functions

String generateFilename () const
 
virtual void loadImpl ()
 
virtual bool prepareImpl (PageData *dataToPopulate)
 
virtual bool prepareImpl (StreamSerialiser &str, PageData *dataToPopulate)
 
void updateDebugDisplay ()
 

Protected Attributes

ContentCollectionList mContentCollections
 
SceneNodemDebugNode
 
bool mDeferredProcessInProgress
 
unsigned long mFrameLastHeld
 
PageID mID
 
bool mModified
 
PagedWorldSectionmParent
 
uint16 mWorkQueueChannel
 

Friends

_OgrePagingExport friend std::ostream & operator<< (std::ostream &o, const Page &p)
 Function for writing to a stream.
 

Detailed Description

Page class.

Definition at line 49 of file OgrePage.h.

Member Typedef Documentation

◆ ContentCollectionList

Definition at line 53 of file OgrePage.h.

Constructor & Destructor Documentation

◆ Page()

Ogre::Page::Page ( PageID pageID,
PagedWorldSection * parent )

◆ ~Page()

virtual Ogre::Page::~Page ( )
virtual

Member Function Documentation

◆ _notifyModified()

void Ogre::Page::_notifyModified ( )

Tell the page that it is modified.

Definition at line 188 of file OgrePage.h.

References mModified.

◆ canHandleRequest()

bool Ogre::Page::canHandleRequest ( const WorkQueue::Request * req,
const WorkQueue * srcQ )
virtual

◆ canHandleResponse()

bool Ogre::Page::canHandleResponse ( const WorkQueue::Response * res,
const WorkQueue * srcQ )
virtual

◆ createContentCollection()

virtual PageContentCollection * Ogre::Page::createContentCollection ( const String & typeName)
virtual

Create a new PageContentCollection within this page.

This is equivalent to calling PageManager::createContentCollection and then attachContentCollection.

Parameters
typeNameThe name of the type of content collection (see PageManager::getContentCollectionFactories)

◆ destroyAllContentCollections()

virtual void Ogre::Page::destroyAllContentCollections ( )
virtual

Destroy all PageContentCollections within this page.

◆ destroyContentCollection()

virtual void Ogre::Page::destroyContentCollection ( PageContentCollection * coll)
virtual

Destroy a PageContentCollection within this page.

This is equivalent to calling detachContentCollection and PageManager::destroyContentCollection.

◆ frameEnd()

virtual void Ogre::Page::frameEnd ( Real timeElapsed)
virtual

Called when the frame ends.

◆ frameStart()

virtual void Ogre::Page::frameStart ( Real timeSinceLastFrame)
virtual

Called when the frame starts.

◆ generateFilename()

String Ogre::Page::generateFilename ( ) const
protected

◆ getContentCollection()

virtual PageContentCollection * Ogre::Page::getContentCollection ( size_t index)
virtual

Get a content collection.

◆ getContentCollectionCount()

virtual size_t Ogre::Page::getContentCollectionCount ( ) const
virtual

Get the number of content collections.

◆ getContentCollectionList()

const ContentCollectionList & Ogre::Page::getContentCollectionList ( ) const

Get the list of content collections.

◆ getFrameLastHeld()

virtual unsigned long Ogre::Page::getFrameLastHeld ( )
virtual

Get the frame number in which this Page was last loaded or held.

Remarks
A Page that has not been requested to be loaded or held in the recent past will be a candidate for removal.

Definition at line 121 of file OgrePage.h.

References mFrameLastHeld.

◆ getID()

virtual PageID Ogre::Page::getID ( ) const
virtual

Get the ID of this page, unique within the parent.

Definition at line 113 of file OgrePage.h.

References mID.

◆ getManager()

PageManager * Ogre::Page::getManager ( ) const

◆ getParentSection()

virtual PagedWorldSection * Ogre::Page::getParentSection ( ) const
virtual

Get the PagedWorldSection this page belongs to.

Definition at line 115 of file OgrePage.h.

References mParent.

◆ getSceneManager()

SceneManager * Ogre::Page::getSceneManager ( ) const

◆ handleRequest()

WorkQueue::Response * Ogre::Page::handleRequest ( const WorkQueue::Request * req,
const WorkQueue * srcQ )
virtual

◆ handleResponse()

void Ogre::Page::handleResponse ( const WorkQueue::Response * res,
const WorkQueue * srcQ )
virtual

◆ isDeferredProcessInProgress()

bool Ogre::Page::isDeferredProcessInProgress ( ) const

If true, it's not safe to access this Page at this time, contents may be changing.

Definition at line 110 of file OgrePage.h.

References mDeferredProcessInProgress.

◆ isHeld()

virtual bool Ogre::Page::isHeld ( ) const
virtual

Returns whether this page was 'held' in the last frame, that is was it either directly needed, or requested to stay in memory (held - as in a buffer region for example).

If not, this page is eligible for removal.

◆ isModified()

bool Ogre::Page::isModified ( ) const

Definition at line 189 of file OgrePage.h.

References mModified.

◆ load()

virtual void Ogre::Page::load ( bool synchronous)
virtual

Load this page.

Parameters
synchronousWhether to force this to happen synchronously.

◆ loadImpl()

virtual void Ogre::Page::loadImpl ( )
protectedvirtual

◆ notifyCamera()

virtual void Ogre::Page::notifyCamera ( Camera * cam)
virtual

Notify a section of the current camera.

◆ operator delete() [1/6]

void Ogre::AllocatedObject< GeneralAllocPolicy >::operator delete ( void * ptr)
inherited

Definition at line 96 of file OgreMemoryAllocatedObject.h.

◆ operator delete() [2/6]

void Ogre::AllocatedObject< GeneralAllocPolicy >::operator delete ( void * ptr)
inherited

Definition at line 96 of file OgreMemoryAllocatedObject.h.

◆ operator delete() [3/6]

void Ogre::AllocatedObject< GeneralAllocPolicy >::operator delete ( void * ptr,
const char * ,
int ,
const char *  )
inherited

Definition at line 108 of file OgreMemoryAllocatedObject.h.

◆ operator delete() [4/6]

void Ogre::AllocatedObject< GeneralAllocPolicy >::operator delete ( void * ptr,
const char * ,
int ,
const char *  )
inherited

Definition at line 108 of file OgreMemoryAllocatedObject.h.

◆ operator delete() [5/6]

void Ogre::AllocatedObject< GeneralAllocPolicy >::operator delete ( void * ptr,
void *  )
inherited

Definition at line 102 of file OgreMemoryAllocatedObject.h.

◆ operator delete() [6/6]

void Ogre::AllocatedObject< GeneralAllocPolicy >::operator delete ( void * ptr,
void *  )
inherited

Definition at line 102 of file OgreMemoryAllocatedObject.h.

◆ operator delete[]() [1/4]

void Ogre::AllocatedObject< GeneralAllocPolicy >::operator delete[] ( void * ptr)
inherited

Definition at line 113 of file OgreMemoryAllocatedObject.h.

◆ operator delete[]() [2/4]

void Ogre::AllocatedObject< GeneralAllocPolicy >::operator delete[] ( void * ptr)
inherited

Definition at line 113 of file OgreMemoryAllocatedObject.h.

◆ operator delete[]() [3/4]

void Ogre::AllocatedObject< GeneralAllocPolicy >::operator delete[] ( void * ptr,
const char * ,
int ,
const char *  )
inherited

Definition at line 119 of file OgreMemoryAllocatedObject.h.

◆ operator delete[]() [4/4]

void Ogre::AllocatedObject< GeneralAllocPolicy >::operator delete[] ( void * ptr,
const char * ,
int ,
const char *  )
inherited

Definition at line 119 of file OgreMemoryAllocatedObject.h.

◆ operator new() [1/6]

void * Ogre::AllocatedObject< GeneralAllocPolicy >::operator new ( size_t sz)
inherited

Definition at line 73 of file OgreMemoryAllocatedObject.h.

◆ operator new() [2/6]

void * Ogre::AllocatedObject< GeneralAllocPolicy >::operator new ( size_t sz)
inherited

Definition at line 73 of file OgreMemoryAllocatedObject.h.

◆ operator new() [3/6]

void * Ogre::AllocatedObject< GeneralAllocPolicy >::operator new ( size_t sz,
const char * file,
int line,
const char * func )
inherited

operator new, with debug line info

Definition at line 68 of file OgreMemoryAllocatedObject.h.

◆ operator new() [4/6]

void * Ogre::AllocatedObject< GeneralAllocPolicy >::operator new ( size_t sz,
const char * file,
int line,
const char * func )
inherited

operator new, with debug line info

Definition at line 68 of file OgreMemoryAllocatedObject.h.

◆ operator new() [5/6]

void * Ogre::AllocatedObject< GeneralAllocPolicy >::operator new ( size_t sz,
void * ptr )
inherited

placement operator new

Definition at line 79 of file OgreMemoryAllocatedObject.h.

◆ operator new() [6/6]

void * Ogre::AllocatedObject< GeneralAllocPolicy >::operator new ( size_t sz,
void * ptr )
inherited

placement operator new

Definition at line 79 of file OgreMemoryAllocatedObject.h.

◆ operator new[]() [1/4]

void * Ogre::AllocatedObject< GeneralAllocPolicy >::operator new[] ( size_t sz)
inherited

Definition at line 91 of file OgreMemoryAllocatedObject.h.

◆ operator new[]() [2/4]

void * Ogre::AllocatedObject< GeneralAllocPolicy >::operator new[] ( size_t sz)
inherited

Definition at line 91 of file OgreMemoryAllocatedObject.h.

◆ operator new[]() [3/4]

void * Ogre::AllocatedObject< GeneralAllocPolicy >::operator new[] ( size_t sz,
const char * file,
int line,
const char * func )
inherited

array operator new, with debug line info

Definition at line 86 of file OgreMemoryAllocatedObject.h.

◆ operator new[]() [4/4]

void * Ogre::AllocatedObject< GeneralAllocPolicy >::operator new[] ( size_t sz,
const char * file,
int line,
const char * func )
inherited

array operator new, with debug line info

Definition at line 86 of file OgreMemoryAllocatedObject.h.

◆ prepareImpl() [1/2]

virtual bool Ogre::Page::prepareImpl ( PageData * dataToPopulate)
protectedvirtual

◆ prepareImpl() [2/2]

virtual bool Ogre::Page::prepareImpl ( StreamSerialiser & str,
PageData * dataToPopulate )
protectedvirtual

◆ save() [1/3]

virtual void Ogre::Page::save ( )
virtual

Save page data to an automatically generated file name.

◆ save() [2/3]

virtual void Ogre::Page::save ( const String & filename)
virtual

Save page data to a file.

◆ save() [3/3]

virtual void Ogre::Page::save ( StreamSerialiser & stream)
virtual

Save page data to a serialiser.

◆ touch()

virtual void Ogre::Page::touch ( )
virtual

'Touch' the page to let it know it's being used

◆ unload()

virtual void Ogre::Page::unload ( )
virtual

Unload this page.

◆ updateDebugDisplay()

void Ogre::Page::updateDebugDisplay ( )
protected

Friends And Related Symbol Documentation

◆ operator<<

_OgrePagingExport friend std::ostream & operator<< ( std::ostream & o,
const Page & p )
friend

Function for writing to a stream.

References Page(), and _OgrePagingExport.

Member Data Documentation

◆ CHUNK_CONTENTCOLLECTION_DECLARATION_ID

const uint32 Ogre::Page::CHUNK_CONTENTCOLLECTION_DECLARATION_ID
static

Definition at line 101 of file OgrePage.h.

◆ CHUNK_ID

const uint32 Ogre::Page::CHUNK_ID
static

Definition at line 98 of file OgrePage.h.

◆ CHUNK_VERSION

const uint16 Ogre::Page::CHUNK_VERSION
static

Definition at line 99 of file OgrePage.h.

◆ mContentCollections

ContentCollectionList Ogre::Page::mContentCollections
protected

Definition at line 58 of file OgrePage.h.

◆ mDebugNode

SceneNode* Ogre::Page::mDebugNode
protected

Definition at line 63 of file OgrePage.h.

◆ mDeferredProcessInProgress

bool Ogre::Page::mDeferredProcessInProgress
protected

Definition at line 60 of file OgrePage.h.

Referenced by isDeferredProcessInProgress().

◆ mFrameLastHeld

unsigned long Ogre::Page::mFrameLastHeld
protected

Definition at line 57 of file OgrePage.h.

Referenced by getFrameLastHeld().

◆ mID

PageID Ogre::Page::mID
protected

Definition at line 55 of file OgrePage.h.

Referenced by getID().

◆ mModified

bool Ogre::Page::mModified
protected

Definition at line 61 of file OgrePage.h.

Referenced by _notifyModified(), and isModified().

◆ mParent

PagedWorldSection* Ogre::Page::mParent
protected

Definition at line 56 of file OgrePage.h.

Referenced by getParentSection().

◆ mWorkQueueChannel

uint16 Ogre::Page::mWorkQueueChannel
protected

Definition at line 59 of file OgrePage.h.

◆ WORKQUEUE_CHANGECOLLECTION_REQUEST

const uint16 Ogre::Page::WORKQUEUE_CHANGECOLLECTION_REQUEST
static

Definition at line 192 of file OgrePage.h.

◆ WORKQUEUE_PREPARE_REQUEST

const uint16 Ogre::Page::WORKQUEUE_PREPARE_REQUEST
static

Definition at line 191 of file OgrePage.h.


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