PS2GL
OpenGL*-like API for the PS2
Loading...
Searching...
No Matches
CRendererManager Class Reference
+ Collaboration diagram for CRendererManager:

Public Member Functions

 CRendererManager (CGLContext &context)
 
void RegisterUserRenderer (CRenderer *renderer)
 
bool UpdateNewRenderer ()
 
void MakeNewRendererCurrent ()
 
void LoadRenderer (CVifSCDmaPacket &packet)
 
CRendererGetCurRenderer ()
 
CRendererProps GetRendererReqs () const
 
bool IsCurRendererCustom () const
 
void EnableCustom (tU64 flag)
 
void DisableCustom (tU64 flag)
 
void NumLightsChanged (tLightType type, int num)
 
void PrimChanged (unsigned int prim)
 
void TexEnabledChanged (bool enabled)
 
void LightingEnabledChanged (bool enabled)
 
void SpecularEnabledChanged (bool enabled)
 
void PerVtxMaterialChanged (RendererProps::tPerVtxMaterial matType)
 
void ClippingEnabledChanged (bool enabled)
 
void CullFaceEnabledChanged (bool enabled)
 
void ArrayAccessChanged (RendererProps::tArrayAccess accessType)
 

Private Member Functions

void RegisterDefaultRenderer (CRenderer *renderer)
 

Private Attributes

CGLContextGLContext
 
CRendererProps RendererRequirements
 
bool RendererReqsHaveChanged
 
tU64 CurUserPrimReqs
 
tU64 CurUserPrimReqMask
 
tRenderer DefaultRenderers [kMaxDefaultRenderers]
 
tRenderer UserRenderers [kMaxUserRenderers]
 
int NumDefaultRenderers
 
int NumUserRenderers
 
const tRendererCurrentRenderer
 
const tRendererNewRenderer
 

Static Private Attributes

static const int kMaxDefaultRenderers = 64
 
static const int kMaxUserRenderers = PGL_MAX_CUSTOM_RENDERERS
 

Detailed Description

Definition at line 41 of file renderermanager.h.

Constructor & Destructor Documentation

◆ CRendererManager()

CRendererManager::CRendererManager ( CGLContext context)

Definition at line 25 of file renderermanager.cpp.

Member Function Documentation

◆ RegisterDefaultRenderer()

void CRendererManager::RegisterDefaultRenderer ( CRenderer renderer)
private

Definition at line 318 of file renderermanager.cpp.

◆ RegisterUserRenderer()

void CRendererManager::RegisterUserRenderer ( CRenderer renderer)

Definition at line 327 of file renderermanager.cpp.

◆ UpdateNewRenderer()

bool CRendererManager::UpdateNewRenderer ( )

Finds a new renderer if the renderer requirements have changed, but does not replace the current renderer. To begin using the new renderer call MakeNewRendererCurrent().

Returns
true if the renderer changed, false otherwise

Definition at line 547 of file renderermanager.cpp.

◆ MakeNewRendererCurrent()

void CRendererManager::MakeNewRendererCurrent ( )

Definition at line 614 of file renderermanager.cpp.

◆ LoadRenderer()

void CRendererManager::LoadRenderer ( CVifSCDmaPacket &  packet)

Definition at line 621 of file renderermanager.cpp.

◆ GetCurRenderer()

CRenderer & CRendererManager::GetCurRenderer ( )
inline

Definition at line 66 of file renderermanager.h.

◆ GetRendererReqs()

CRendererProps CRendererManager::GetRendererReqs ( ) const
inline

Definition at line 67 of file renderermanager.h.

◆ IsCurRendererCustom()

bool CRendererManager::IsCurRendererCustom ( ) const
inline

Definition at line 69 of file renderermanager.h.

◆ EnableCustom()

void CRendererManager::EnableCustom ( tU64  flag)

Definition at line 341 of file renderermanager.cpp.

◆ DisableCustom()

void CRendererManager::DisableCustom ( tU64  flag)

Definition at line 352 of file renderermanager.cpp.

◆ NumLightsChanged()

void CRendererManager::NumLightsChanged ( tLightType  type,
int  num 
)

Definition at line 363 of file renderermanager.cpp.

◆ PrimChanged()

void CRendererManager::PrimChanged ( unsigned int  prim)

Definition at line 403 of file renderermanager.cpp.

◆ TexEnabledChanged()

void CRendererManager::TexEnabledChanged ( bool  enabled)

Definition at line 463 of file renderermanager.cpp.

◆ LightingEnabledChanged()

void CRendererManager::LightingEnabledChanged ( bool  enabled)

Definition at line 478 of file renderermanager.cpp.

◆ SpecularEnabledChanged()

void CRendererManager::SpecularEnabledChanged ( bool  enabled)

Definition at line 493 of file renderermanager.cpp.

◆ PerVtxMaterialChanged()

void CRendererManager::PerVtxMaterialChanged ( RendererProps::tPerVtxMaterial  matType)

Definition at line 508 of file renderermanager.cpp.

◆ ClippingEnabledChanged()

void CRendererManager::ClippingEnabledChanged ( bool  enabled)

Definition at line 516 of file renderermanager.cpp.

◆ CullFaceEnabledChanged()

void CRendererManager::CullFaceEnabledChanged ( bool  enabled)

Definition at line 525 of file renderermanager.cpp.

◆ ArrayAccessChanged()

void CRendererManager::ArrayAccessChanged ( RendererProps::tArrayAccess  accessType)

Definition at line 533 of file renderermanager.cpp.

Field Documentation

◆ GLContext

CGLContext& CRendererManager::GLContext
private

Definition at line 42 of file renderermanager.h.

◆ RendererRequirements

CRendererProps CRendererManager::RendererRequirements
private

Definition at line 44 of file renderermanager.h.

◆ RendererReqsHaveChanged

bool CRendererManager::RendererReqsHaveChanged
private

Definition at line 45 of file renderermanager.h.

◆ CurUserPrimReqs

tU64 CRendererManager::CurUserPrimReqs
private

Definition at line 46 of file renderermanager.h.

◆ CurUserPrimReqMask

tU64 CRendererManager::CurUserPrimReqMask
private

Definition at line 46 of file renderermanager.h.

◆ kMaxDefaultRenderers

const int CRendererManager::kMaxDefaultRenderers = 64
staticprivate

Definition at line 48 of file renderermanager.h.

◆ kMaxUserRenderers

const int CRendererManager::kMaxUserRenderers = PGL_MAX_CUSTOM_RENDERERS
staticprivate

Definition at line 49 of file renderermanager.h.

◆ DefaultRenderers

tRenderer CRendererManager::DefaultRenderers[kMaxDefaultRenderers]
private

Definition at line 50 of file renderermanager.h.

◆ UserRenderers

tRenderer CRendererManager::UserRenderers[kMaxUserRenderers]
private

Definition at line 51 of file renderermanager.h.

◆ NumDefaultRenderers

int CRendererManager::NumDefaultRenderers
private

Definition at line 52 of file renderermanager.h.

◆ NumUserRenderers

int CRendererManager::NumUserRenderers
private

Definition at line 52 of file renderermanager.h.

◆ CurrentRenderer

const tRenderer* CRendererManager::CurrentRenderer
private

Definition at line 53 of file renderermanager.h.

◆ NewRenderer

const tRenderer * CRendererManager::NewRenderer
private

Definition at line 53 of file renderermanager.h.


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