AtlasInstanceTOC< _StubType, _ResourceTOCType > Class Template Reference [Atlas Runtime]

#include <atlasInstanceTOC.h>

Inheritance diagram for AtlasInstanceTOC< _StubType, _ResourceTOCType >:

Inheritance graph
[legend]
List of all members.

Detailed Description


template<class _StubType, class _ResourceTOCType> class AtlasInstanceTOC< _StubType, _ResourceTOCType >

Atlas instance TOC base class.

Provides most functionality for tracking an instance of an Atlas TOC.

Allows you to bind to an existing AtlasResourceTOC, make load requests, and perform other operations on the instance dataset.


Public Types

typedef _StubType StubType
typedef _ResourceTOCType ResourceTOCType

Public Member Functions

 ~AtlasInstanceTOC ()
virtual void updateBounds (StubType *stub, U32 i, S32 x, S32 y)
 Callback to allow subclasses to update stub data when we initialize.
ResourceTOCTypegetResourceTOC ()
virtual void initializeTOC (ResourceTOCType *resourceToc)
 Initialize our TOC.
ResourceTOCType::StubType * getResourceStub (StubType *stub)
 Given a pointer to a stub from this TOC, convert to a stub in the corresponding resource TOC.
StubTypegetInstanceStub (typename ResourceTOCType::StubType *stub)
 Given a pointer to a stub from the resource TOC, convert back to a stub in this TOC.
virtual void requestLoad (StubType *stub, U32 reason, F32 priority)
virtual void cancelLoadRequest (StubType *stub, U32 reason)
virtual void cancelAllLoadRequests (U32 reason)
 Purge all data.
bool areChildrenLoaded (StubType *stub)
 Helper function; returns true iff all the children of this stub are populated with chunks.

Protected Attributes

_ResourceTOCType * mResourceTOC


Member Typedef Documentation

template<class _StubType, class _ResourceTOCType>
typedef _StubType AtlasInstanceTOC< _StubType, _ResourceTOCType >::StubType

template<class _StubType, class _ResourceTOCType>
typedef _ResourceTOCType AtlasInstanceTOC< _StubType, _ResourceTOCType >::ResourceTOCType


Constructor & Destructor Documentation

template<class _StubType, class _ResourceTOCType>
AtlasInstanceTOC< _StubType, _ResourceTOCType >::~AtlasInstanceTOC (  )  [inline]


Member Function Documentation

template<class _StubType, class _ResourceTOCType>
virtual void AtlasInstanceTOC< _StubType, _ResourceTOCType >::updateBounds ( StubType stub,
U32  i,
S32  x,
S32  y 
) [inline, virtual]

Callback to allow subclasses to update stub data when we initialize.

Reimplemented in AtlasInstanceGeomTOC.

template<class _StubType, class _ResourceTOCType>
ResourceTOCType* AtlasInstanceTOC< _StubType, _ResourceTOCType >::getResourceTOC (  )  [inline]

template<class _StubType, class _ResourceTOCType>
virtual void AtlasInstanceTOC< _StubType, _ResourceTOCType >::initializeTOC ( ResourceTOCType resourceToc  )  [inline, virtual]

Initialize our TOC.

template<class _StubType, class _ResourceTOCType>
ResourceTOCType::StubType* AtlasInstanceTOC< _StubType, _ResourceTOCType >::getResourceStub ( StubType stub  )  [inline]

Given a pointer to a stub from this TOC, convert to a stub in the corresponding resource TOC.

template<class _StubType, class _ResourceTOCType>
StubType* AtlasInstanceTOC< _StubType, _ResourceTOCType >::getInstanceStub ( typename ResourceTOCType::StubType *  stub  )  [inline]

Given a pointer to a stub from the resource TOC, convert back to a stub in this TOC.

template<class _StubType, class _ResourceTOCType>
virtual void AtlasInstanceTOC< _StubType, _ResourceTOCType >::requestLoad ( StubType stub,
U32  reason,
F32  priority 
) [inline, virtual]

Reimplemented in AtlasInstanceGeomTOC.

template<class _StubType, class _ResourceTOCType>
virtual void AtlasInstanceTOC< _StubType, _ResourceTOCType >::cancelLoadRequest ( StubType stub,
U32  reason 
) [inline, virtual]

Reimplemented in AtlasInstanceGeomTOC.

template<class _StubType, class _ResourceTOCType>
virtual void AtlasInstanceTOC< _StubType, _ResourceTOCType >::cancelAllLoadRequests ( U32  reason  )  [inline, virtual]

Purge all data.

template<class _StubType, class _ResourceTOCType>
bool AtlasInstanceTOC< _StubType, _ResourceTOCType >::areChildrenLoaded ( StubType stub  )  [inline]

Helper function; returns true iff all the children of this stub are populated with chunks.

If this is a leaf, we return false.


Member Data Documentation

template<class _StubType, class _ResourceTOCType>
_ResourceTOCType* AtlasInstanceTOC< _StubType, _ResourceTOCType >::mResourceTOC [protected]