OpenBarnyard
 
Loading...
Searching...
No Matches
TVertexPoolResourceInterface Class Referenceabstract

#include <TVertexPoolResourceInterface.h>

Inheritance diagram for TVertexPoolResourceInterface:
TResource TObject TNodeTree< T >::TNode TVertexPoolResource

Classes

struct  LockBuffer
 

Public Member Functions

 TDECLARE_CLASS (TVertexPoolResourceInterface, TResource)
 
 TVertexPoolResourceInterface ()
 
virtual void OnDestroy () override
 
virtual TBOOL Lock (LockBuffer *a_pLockBuffer)=0
 
virtual void Unlock (TUINT16 a_uiNewNumVertices)=0
 
virtual TBOOL Create (TVertexFactoryResourceInterface *a_pFactory, TUINT16 a_uiMaxVertices, TUINT16 a_uiFlags)
 
TVertexFactoryResourceInterfaceGetFactory () const
 
TUINT16 GetFlags () const
 
TUINT16 GetMaxVertices () const
 
TUINT16 GetNumVertices () const
 
TBOOL IsLocked () const
 
- Public Member Functions inherited from TResource
 TDECLARE_CLASS (TResource, TObject)
 
 TResource ()
 
 ~TResource ()
 
virtual TBOOL Create ()
 
virtual TBOOL Validate ()
 
virtual void Invalidate ()
 
virtual void DestroyResource ()
 
virtual TBOOL TryInvalidate ()
 
virtual TBOOL TryValidate ()
 
TBOOL IsDead () const
 
TBOOL IsDying () const
 
TBOOL IsValid () const
 
TBOOL IsExternal () const
 
TBOOL IsCreated () const
 
TBOOL IsSceneObject () const
 
TBOOL IsInvalid () const
 
void SetState (TResourceState newState)
 
void AddState (TResourceState state)
 
void SetParent (TResource *a_pParent)
 
const TCHARGetName () const
 
void SetName (const TCHAR *name)
 
TBOOL RecurseSimple (t_RecurseCb a_pCallback, TResource *a_pResource, void *a_pUserData)
 
TRenderInterfaceGetRenderer () const
 
void SetRenderer (TRenderInterface *pRenderer)
 
TUINT32 GetUId () const
 
void SetUId (TUINT32 uid)
 
- Public Member Functions inherited from TObject
virtual Toshi::TClass * GetClass ()
 
virtual void Delete ()
 
virtual ~TObject ()
 
TBOOL IsExactly (TClass *a_pClass)
 
TBOOL IsA (TClass *a_pClass)
 
- Public Member Functions inherited from TNodeTree< T >::TNode
TBOOL IsChildOfDefaultRoot () const
 
TBOOL IsLinked () const
 
T * Parent () const
 
T * Next () const
 
T * Prev () const
 
TNodeTree< T > * Tree () const
 
T * Child () const
 

Protected Attributes

TVertexFactoryResourceInterfacem_pFactory
 
TUINT16 m_uiFlags
 
TUINT16 m_uiMaxVertices
 
TUINT16 m_uiNumVertices
 
TUINT16 m_uiLockCount
 
- Protected Attributes inherited from TNodeTree< T >::TNode
TNodeTree< T > * m_Tree
 
T * m_Next
 
T * m_Prev
 
T * m_Parent
 
T * m_Child
 

Additional Inherited Members

- Public Types inherited from TResource
using t_RecurseCb = TBOOL ( * )( TResource* a_pResource, void* a_pUserData )
 
- Public Types inherited from TObject
enum  { IsTObject = TTRUE }
 
- Static Public Member Functions inherited from TResource
static TBOOL Recurse (t_RecurseCb a_pCallback, TResource *a_pResource, TBOOL a_bFlag, void *a_pUserData)
 
- Static Public Member Functions inherited from TObject
static Toshi::TObject * CreateTObject ()
 
static Toshi::TObject * CreateTObjectInPlace (void *a_pPtr)
 
static void InitialiseClass ()
 
static void DeinitialiseClass ()
 
static TFORCEINLINE TClassGetClassStatic ()
 
- Public Attributes inherited from TResource
friend TRenderInterface
 
- Public Attributes inherited from TNodeTree< T >::TNode
friend TNodeTree
 
- Static Public Attributes inherited from TResource
static constexpr size_t MAXNAMELEN = 14
 
- Static Public Attributes inherited from TObject
static constexpr Toshi::TClass * PARENTCLASS = TNULL
 
static constinit Toshi::TClass ms_oClass = Toshi::TClass( "TObject", TObject::CreateTObject, TObject::CreateTObjectInPlace, TObject::InitialiseClass, TObject::DeinitialiseClass, 0, 2, sizeof( TObject ), alignof( TObject ) )
 
- Protected Member Functions inherited from TNodeTree< T >::TNode
 TNode ()
 

Detailed Description

Definition at line 7 of file TVertexPoolResourceInterface.h.

Constructor & Destructor Documentation

◆ TVertexPoolResourceInterface()

TVertexPoolResourceInterface::TVertexPoolResourceInterface ( )

Member Function Documentation

◆ Create()

TBOOL TVertexPoolResourceInterface::Create ( TVertexFactoryResourceInterface * a_pFactory,
TUINT16 a_uiMaxVertices,
TUINT16 a_uiFlags )
virtual

Reimplemented in TVertexPoolResource.

Definition at line 29 of file TVertexPoolResourceInterface.cpp.

30{
31 m_pFactory = a_pFactory;
32 m_uiMaxVertices = a_uiMaxVertices;
33 m_uiFlags = a_uiFlags;
34 return TResource::Create();
35}
virtual TBOOL Create()
Definition TResource.cpp:28

◆ GetFactory()

TVertexFactoryResourceInterface * TVertexPoolResourceInterface::GetFactory ( ) const
inline

Definition at line 30 of file TVertexPoolResourceInterface.h.

30{ return m_pFactory; }

◆ GetFlags()

TUINT16 TVertexPoolResourceInterface::GetFlags ( ) const
inline

Definition at line 31 of file TVertexPoolResourceInterface.h.

31{ return m_uiFlags; }

◆ GetMaxVertices()

TUINT16 TVertexPoolResourceInterface::GetMaxVertices ( ) const
inline

Definition at line 32 of file TVertexPoolResourceInterface.h.

32{ return m_uiMaxVertices; }

◆ GetNumVertices()

TUINT16 TVertexPoolResourceInterface::GetNumVertices ( ) const
inline

Definition at line 33 of file TVertexPoolResourceInterface.h.

33{ return m_uiNumVertices; }

◆ IsLocked()

TBOOL TVertexPoolResourceInterface::IsLocked ( ) const
inline

Definition at line 34 of file TVertexPoolResourceInterface.h.

34{ return m_uiLockCount != 0; }

◆ Lock()

virtual TBOOL TVertexPoolResourceInterface::Lock ( LockBuffer * a_pLockBuffer)
pure virtual

Implemented in TVertexPoolResource.

◆ OnDestroy()

void TVertexPoolResourceInterface::OnDestroy ( )
overridevirtual

Reimplemented from TResource.

Reimplemented in TVertexPoolResource.

Definition at line 23 of file TVertexPoolResourceInterface.cpp.

24{
25 TASSERT( 0 == m_uiLockCount );
26 m_pFactory->m_uiNumPools -= 1;
27}
#define TASSERT(X,...)
Definition Defines.h:138

◆ TDECLARE_CLASS()

TVertexPoolResourceInterface::TDECLARE_CLASS ( TVertexPoolResourceInterface ,
TResource  )

◆ Unlock()

virtual void TVertexPoolResourceInterface::Unlock ( TUINT16 a_uiNewNumVertices)
pure virtual

Implemented in TVertexPoolResource.

Member Data Documentation

◆ m_pFactory

TVertexFactoryResourceInterface* TVertexPoolResourceInterface::m_pFactory
protected

Definition at line 37 of file TVertexPoolResourceInterface.h.

◆ m_uiFlags

TUINT16 TVertexPoolResourceInterface::m_uiFlags
protected

Definition at line 38 of file TVertexPoolResourceInterface.h.

◆ m_uiLockCount

TUINT16 TVertexPoolResourceInterface::m_uiLockCount
protected

Definition at line 41 of file TVertexPoolResourceInterface.h.

◆ m_uiMaxVertices

TUINT16 TVertexPoolResourceInterface::m_uiMaxVertices
protected

Definition at line 39 of file TVertexPoolResourceInterface.h.

◆ m_uiNumVertices

TUINT16 TVertexPoolResourceInterface::m_uiNumVertices
protected

Definition at line 40 of file TVertexPoolResourceInterface.h.


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