Twilight Princess
Decompilation of The Legend of Zelda: Twilight Princess
Loading...
Searching...
No Matches
nw4hbm::lyt::Material Class Reference

#include <material.h>

+ Collaboration diagram for nw4hbm::lyt::Material:

Public Member Functions

 Material ()
 
 Material (const res::Material *pRes, const ResBlockSet &resBlockSet)
 
virtual ~Material ()
 
virtual bool SetupGX (bool bModVtxCol, u8 alpha)
 
virtual void BindAnimation (AnimTransform *animTrans)
 
virtual void UnbindAnimation (AnimTransform *animTrans)
 
virtual void UnbindAllAnimation ()
 
virtual void Animate ()
 
virtual AnimationLinkFindAnimationLink (AnimTransform *animTrans)
 
virtual void SetAnimationEnable (AnimTransform *animTrans, bool bEnable)
 
const char * GetName () const
 
GXColorS10 GetTevColor (u32 idx) const
 
u8 GetTextureCap () const
 
u8 GetTexSRTCap () const
 
u8 GetTexCoordGenCap () const
 
u8 GetIndTexSRTCap () const
 
bool IsTevSwapCap () const
 
bool IsBlendModeCap () const
 
bool IsAlphaCompareCap () const
 
bool IsMatColorCap () const
 
bool IsChanCtrlCap () const
 
u8 GetTextureNum () const
 
bool IsUserAllocated () const
 
void SetName (const char *name)
 
const GXTexObjGetTexMapAry () const
 
const TexSRTGetTexSRTAry () const
 
const TexCoordGenGetTexCoordGenAry () const
 
const ChanCtrlGetChanCtrlAry () const
 
const ut::ColorGetMatColAry () const
 
const TevSwapModeGetTevSwapAry () const
 
const AlphaCompareGetAlphaComparePtr () const
 
const BlendModeGetBlendModePtr () const
 
const IndirectStageGetIndirectStageAry () const
 
const TexSRTGetIndTexSRTAry () const
 
const TevStageGetTevStageAry () const
 
GXTexObjGetTexMapAry ()
 
TexSRTGetTexSRTAry ()
 
TexCoordGenGetTexCoordGenAry ()
 
ChanCtrlGetChanCtrlAry ()
 
ut::ColorGetMatColAry ()
 
TevSwapModeGetTevSwapAry ()
 
AlphaCompareGetAlphaComparePtr ()
 
BlendModeGetBlendModePtr ()
 
IndirectStageGetIndirectStageAry ()
 
TexSRTGetIndTexSRTAry ()
 
TevStageGetTevStageAry ()
 
void GetTexture (GXTexObj *pTexObj, u8 texMapIdx) const
 
void SetTextureNum (u8 num)
 
void SetTexCoordGenNum (u8 num)
 
void SetIndStageNum (u8 num)
 
void SetTevStageNum (u8 num)
 
void SetTexture (u8 texMapIdx, const GXTexObj &texObj)
 
void SetTexture (u8 texMapIdx, TPLPalette *pTplRes)
 
void SetTextureNoWrap (u8 texMapIdx, TPLPalette *pTplRes)
 
void SetColorElement (u32 colorType, s16 value)
 
void SetTexCoordGen (u32 idx, TexCoordGen value)
 
void SetTexSRTElement (u32 texSRTIdx, u32 eleIdx, f32 value)
 
void SetIndTexSRTElement (u32 texSRTIdx, u32 eleIdx, f32 value)
 
void Init ()
 
void InitBitGXNums (detail::BitGXNums *ptr)
 
void ReserveGXMem (u8 texMapNum, u8 texSRTNum, u8 texCoordGenNum, u8 tevStageNum, bool allocTevSwap, u8 indStageNum, u8 indSRTNum, bool allocChanCtrl, bool allocMatCol, bool allocAlpComp, bool allocBlendMode)
 
void AddAnimationLink (AnimationLink *animationLink)
 

Private Attributes

char mName [20]
 
AnimationLinkList mAnimList
 
GXColorS10 mTevCols [TEVCOLOR_MAX]
 
ut::Color mTevKCols [GX_MAX_KCOLOR]
 
detail::BitGXNums mGXMemCap
 
detail::BitGXNums mGXMemNum
 
bool mbUserAllocated
 
void * mpGXMem
 

Static Private Attributes

static const int MAX_TEX_SRT = (GX_TEXMTX9 - GX_TEXMTX0) / 3 + 1
 
static const int MAX_IND_SRT = (GX_ITM_2 - GX_ITM_0) + 1
 

Constructor & Destructor Documentation

◆ Material() [1/2]

nw4hbm::lyt::Material::Material ( )

◆ Material() [2/2]

nw4hbm::lyt::Material::Material ( const res::Material * pRes,
const ResBlockSet & resBlockSet )

◆ ~Material()

nw4hbm::lyt::Material::~Material ( )
virtual

Member Function Documentation

◆ AddAnimationLink()

void nw4hbm::lyt::Material::AddAnimationLink ( AnimationLink * animationLink)

◆ Animate()

void nw4hbm::lyt::Material::Animate ( )
virtual

◆ BindAnimation()

void nw4hbm::lyt::Material::BindAnimation ( AnimTransform * animTrans)
virtual

◆ FindAnimationLink()

AnimationLink * nw4hbm::lyt::Material::FindAnimationLink ( AnimTransform * animTrans)
virtual

◆ GetAlphaComparePtr() [1/2]

AlphaCompare * nw4hbm::lyt::Material::GetAlphaComparePtr ( )

◆ GetAlphaComparePtr() [2/2]

const AlphaCompare * nw4hbm::lyt::Material::GetAlphaComparePtr ( ) const

◆ GetBlendModePtr() [1/2]

BlendMode * nw4hbm::lyt::Material::GetBlendModePtr ( )

◆ GetBlendModePtr() [2/2]

const BlendMode * nw4hbm::lyt::Material::GetBlendModePtr ( ) const

◆ GetChanCtrlAry() [1/2]

ChanCtrl * nw4hbm::lyt::Material::GetChanCtrlAry ( )

◆ GetChanCtrlAry() [2/2]

const ChanCtrl * nw4hbm::lyt::Material::GetChanCtrlAry ( ) const

◆ GetIndirectStageAry() [1/2]

IndirectStage * nw4hbm::lyt::Material::GetIndirectStageAry ( )

◆ GetIndirectStageAry() [2/2]

const IndirectStage * nw4hbm::lyt::Material::GetIndirectStageAry ( ) const

◆ GetIndTexSRTAry() [1/2]

TexSRT * nw4hbm::lyt::Material::GetIndTexSRTAry ( )

◆ GetIndTexSRTAry() [2/2]

const TexSRT * nw4hbm::lyt::Material::GetIndTexSRTAry ( ) const

◆ GetIndTexSRTCap()

u8 nw4hbm::lyt::Material::GetIndTexSRTCap ( ) const
inline

◆ GetMatColAry() [1/2]

ut::Color * nw4hbm::lyt::Material::GetMatColAry ( )

◆ GetMatColAry() [2/2]

const ut::Color * nw4hbm::lyt::Material::GetMatColAry ( ) const

◆ GetName()

const char * nw4hbm::lyt::Material::GetName ( ) const
inline

◆ GetTevColor()

GXColorS10 nw4hbm::lyt::Material::GetTevColor ( u32 idx) const
inline

◆ GetTevStageAry() [1/2]

TevStage * nw4hbm::lyt::Material::GetTevStageAry ( )

◆ GetTevStageAry() [2/2]

const TevStage * nw4hbm::lyt::Material::GetTevStageAry ( ) const

◆ GetTevSwapAry() [1/2]

TevSwapMode * nw4hbm::lyt::Material::GetTevSwapAry ( )

◆ GetTevSwapAry() [2/2]

const TevSwapMode * nw4hbm::lyt::Material::GetTevSwapAry ( ) const

◆ GetTexCoordGenAry() [1/2]

TexCoordGen * nw4hbm::lyt::Material::GetTexCoordGenAry ( )

◆ GetTexCoordGenAry() [2/2]

const TexCoordGen * nw4hbm::lyt::Material::GetTexCoordGenAry ( ) const

◆ GetTexCoordGenCap()

u8 nw4hbm::lyt::Material::GetTexCoordGenCap ( ) const
inline

◆ GetTexMapAry() [1/2]

GXTexObj * nw4hbm::lyt::Material::GetTexMapAry ( )

◆ GetTexMapAry() [2/2]

const GXTexObj * nw4hbm::lyt::Material::GetTexMapAry ( ) const

◆ GetTexSRTAry() [1/2]

TexSRT * nw4hbm::lyt::Material::GetTexSRTAry ( )

◆ GetTexSRTAry() [2/2]

const TexSRT * nw4hbm::lyt::Material::GetTexSRTAry ( ) const

◆ GetTexSRTCap()

u8 nw4hbm::lyt::Material::GetTexSRTCap ( ) const
inline

◆ GetTexture()

void nw4hbm::lyt::Material::GetTexture ( GXTexObj * pTexObj,
u8 texMapIdx ) const

◆ GetTextureCap()

u8 nw4hbm::lyt::Material::GetTextureCap ( ) const
inline

◆ GetTextureNum()

u8 nw4hbm::lyt::Material::GetTextureNum ( ) const
inline

◆ Init()

void nw4hbm::lyt::Material::Init ( )

◆ InitBitGXNums()

void nw4hbm::lyt::Material::InitBitGXNums ( detail::BitGXNums * ptr)

◆ IsAlphaCompareCap()

bool nw4hbm::lyt::Material::IsAlphaCompareCap ( ) const
inline

◆ IsBlendModeCap()

bool nw4hbm::lyt::Material::IsBlendModeCap ( ) const
inline

◆ IsChanCtrlCap()

bool nw4hbm::lyt::Material::IsChanCtrlCap ( ) const
inline

◆ IsMatColorCap()

bool nw4hbm::lyt::Material::IsMatColorCap ( ) const
inline

◆ IsTevSwapCap()

bool nw4hbm::lyt::Material::IsTevSwapCap ( ) const
inline

◆ IsUserAllocated()

bool nw4hbm::lyt::Material::IsUserAllocated ( ) const
inline

◆ ReserveGXMem()

void nw4hbm::lyt::Material::ReserveGXMem ( u8 texMapNum,
u8 texSRTNum,
u8 texCoordGenNum,
u8 tevStageNum,
bool allocTevSwap,
u8 indStageNum,
u8 indSRTNum,
bool allocChanCtrl,
bool allocMatCol,
bool allocAlpComp,
bool allocBlendMode )

◆ SetAnimationEnable()

void nw4hbm::lyt::Material::SetAnimationEnable ( AnimTransform * animTrans,
bool bEnable )
virtual

◆ SetColorElement()

void nw4hbm::lyt::Material::SetColorElement ( u32 colorType,
s16 value )

◆ SetIndStageNum()

void nw4hbm::lyt::Material::SetIndStageNum ( u8 num)

◆ SetIndTexSRTElement()

void nw4hbm::lyt::Material::SetIndTexSRTElement ( u32 texSRTIdx,
u32 eleIdx,
f32 value )
inline

◆ SetName()

void nw4hbm::lyt::Material::SetName ( const char * name)

◆ SetTevStageNum()

void nw4hbm::lyt::Material::SetTevStageNum ( u8 num)

◆ SetTexCoordGen()

void nw4hbm::lyt::Material::SetTexCoordGen ( u32 idx,
TexCoordGen value )
inline

◆ SetTexCoordGenNum()

void nw4hbm::lyt::Material::SetTexCoordGenNum ( u8 num)

◆ SetTexSRTElement()

void nw4hbm::lyt::Material::SetTexSRTElement ( u32 texSRTIdx,
u32 eleIdx,
f32 value )
inline

◆ SetTexture() [1/2]

void nw4hbm::lyt::Material::SetTexture ( u8 texMapIdx,
const GXTexObj & texObj )

◆ SetTexture() [2/2]

void nw4hbm::lyt::Material::SetTexture ( u8 texMapIdx,
TPLPalette * pTplRes )

◆ SetTextureNoWrap()

void nw4hbm::lyt::Material::SetTextureNoWrap ( u8 texMapIdx,
TPLPalette * pTplRes )

◆ SetTextureNum()

void nw4hbm::lyt::Material::SetTextureNum ( u8 num)

◆ SetupGX()

bool nw4hbm::lyt::Material::SetupGX ( bool bModVtxCol,
u8 alpha )
virtual

◆ UnbindAllAnimation()

void nw4hbm::lyt::Material::UnbindAllAnimation ( )
virtual

◆ UnbindAnimation()

void nw4hbm::lyt::Material::UnbindAnimation ( AnimTransform * animTrans)
virtual

Member Data Documentation

◆ mAnimList

AnimationLinkList nw4hbm::lyt::Material::mAnimList
private

◆ MAX_IND_SRT

const int nw4hbm::lyt::Material::MAX_IND_SRT = (GX_ITM_2 - GX_ITM_0) + 1
staticprivate

◆ MAX_TEX_SRT

const int nw4hbm::lyt::Material::MAX_TEX_SRT = (GX_TEXMTX9 - GX_TEXMTX0) / 3 + 1
staticprivate

◆ mbUserAllocated

bool nw4hbm::lyt::Material::mbUserAllocated
private

◆ mGXMemCap

detail::BitGXNums nw4hbm::lyt::Material::mGXMemCap
private

◆ mGXMemNum

detail::BitGXNums nw4hbm::lyt::Material::mGXMemNum
private

◆ mName

char nw4hbm::lyt::Material::mName[20]
private

◆ mpGXMem

void* nw4hbm::lyt::Material::mpGXMem
private

◆ mTevCols

GXColorS10 nw4hbm::lyt::Material::mTevCols[TEVCOLOR_MAX]
private

◆ mTevKCols

ut::Color nw4hbm::lyt::Material::mTevKCols[GX_MAX_KCOLOR]
private

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