ScummVM API documentation
hpl::cMaterial_Modulative Class Reference
Inheritance diagram for hpl::cMaterial_Modulative:
hpl::iMaterial hpl::iResourceBase

Public Member Functions

 cMaterial_Modulative (const tString &asName, iLowLevelGraphics *apLowLevelGraphics, cImageManager *apImageManager, cTextureManager *apTextureManager, cRenderer2D *apRenderer, cGpuProgramManager *apProgramManager, eMaterialPicture aPicture, cRenderer3D *apRenderer3D)
 
tTextureTypeList GetTextureTypes ()
 
bool UsesType (eMaterialRenderType aType)
 
iGpuProgram * getGpuProgram (const eMaterialRenderType aType, const int alPass, iLight3D *apLight)
 
iMaterialProgramSetup * getGpuProgramSetup (const eMaterialRenderType aType, const int alPass, iLight3D *apLight)
 
bool VertexProgramUsesLight (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
bool VertexProgramUsesEye (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
eMaterialAlphaMode GetAlphaMode (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
eMaterialBlendMode GetBlendMode (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
eMaterialChannelMode GetChannelMode (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
iTexture * GetTexture (int alUnit, eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
eMaterialBlendMode GetTextureBlend (int alUnit, eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
int GetNumOfPasses (eMaterialRenderType aType, iLight3D *apLight)
 
void Compile ()
 
bool StartRendering (eMaterialRenderType aType, iCamera *apCam, iLight *pLight)
 
void EndRendering (eMaterialRenderType aType)
 
tVtxBatchFlag GetBatchFlags (eMaterialRenderType aType)
 
bool NextPass (eMaterialRenderType aType)
 
bool HasMultiplePasses (eMaterialRenderType aType)
 
eMaterialType GetType (eMaterialRenderType aType)
 
void EditVertexes (eMaterialRenderType aType, iCamera *apCam, iLight *pLight, tVertexVec *apVtxVec, cVector3f *apTransform, unsigned int alIndexAdd)
 
- Public Member Functions inherited from hpl::iMaterial
 iMaterial (const tString &asName, iLowLevelGraphics *apLowLevelGraphics, cImageManager *apImageManager, cTextureManager *apTextureManager, cRenderer2D *apRenderer, cGpuProgramManager *apProgramManager, eMaterialPicture aPicture, cRenderer3D *apRenderer3D)
 
bool reload ()
 
void unload ()
 
void destroy ()
 
virtual void Compile ()=0
 
virtual void Update (float afTimeStep)
 
virtual iGpuProgram * getGpuProgram (const eMaterialRenderType aType, const int alPass, iLight3D *apLight)
 
virtual iMaterialProgramSetup * getGpuProgramSetup (const eMaterialRenderType aType, const int alPass, iLight3D *apLight)
 
virtual iGpuProgram * GetVertexProgram (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual bool VertexProgramUsesLight (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual bool VertexProgramUsesEye (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual iMaterialProgramSetup * GetVertexProgramSetup (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual iGpuProgram * GetFragmentProgram (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual iMaterialProgramSetup * GetFragmentProgramSetup (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual eMaterialAlphaMode GetAlphaMode (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual eMaterialBlendMode GetBlendMode (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual eMaterialChannelMode GetChannelMode (eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual iTexture * GetTexture (int alUnit, eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual eMaterialBlendMode GetTextureBlend (int alUnit, eMaterialRenderType aType, int alPass, iLight3D *apLight)
 
virtual int GetNumOfPasses (eMaterialRenderType aType, iLight3D *apLight)
 
virtual bool UsesType (eMaterialRenderType aType)
 
bool HasAlpha ()
 
void SetHasAlpha (bool abX)
 
bool GetDepthTest ()
 
void SetDepthTest (bool abX)
 
float GetValue ()
 
void SetValue (float afX)
 
virtual bool LoadData (TiXmlElement *apRootElem)
 
virtual bool StartRendering (eMaterialRenderType aType, iCamera *apCam, iLight *pLight)=0
 
virtual void EndRendering (eMaterialRenderType mType)=0
 
virtual tVtxBatchFlag GetBatchFlags (eMaterialRenderType mType)=0
 
virtual bool NextPass (eMaterialRenderType mType)=0
 
virtual bool HasMultiplePasses (eMaterialRenderType mType)=0
 
virtual eMaterialType GetType (eMaterialRenderType mType)=0
 
virtual void EditVertexes (eMaterialRenderType mType, iCamera *apCam, iLight *pLight, tVertexVec *apVtxVec, cVector3f *apTransform, unsigned int alIndexAdd)=0
 
iTexture * GetTexture (eMaterialTexture aType)
 
cRect2f GetTextureOffset (eMaterialTexture aType)
 
void SetTexture (iTexture *apTex, eMaterialTexture aType)
 
void SetImage (cResourceImage *apImg, eMaterialTexture aType)
 
cResourceImage * GetImage (eMaterialTexture aType)
 
void SetProgram (iGpuProgram *apProgram, eGpuProgramType aType, unsigned int alNum)
 
iGpuProgram * GetProgram (eGpuProgramType aType, unsigned int alNum)
 
virtual bool IsTransperant ()
 
virtual bool IsGlowing ()
 
virtual bool UsesLights ()
 
virtual tTextureTypeList GetTextureTypes ()
 
void SetId (int alId)
 
int GetId ()
 
virtual iGpuProgram * getRefractionProgram ()
 
virtual bool GetRefractionUsesDiffuse ()
 
virtual eMaterialTexture GetRefractionDiffuseTexture ()
 
virtual bool GetRefractionUsesEye ()
 
virtual bool GetRefractionUsesTime ()
 
virtual bool GetRefractionSkipsStandardTrans ()
 
const tString & GetPhysicsMaterial ()
 
void SetPhysicsMaterial (const tString &asName)
 
- Public Member Functions inherited from hpl::iResourceBase
 iResourceBase (tString asName, unsigned long alPrio)
 
virtual bool reload ()=0
 
virtual void unload ()=0
 
virtual void destroy ()=0
 
tString GetName ()
 
unsigned long GetHandle ()
 
void SetHandle (unsigned long alHandle)
 
tString GetFilePath ()
 
unsigned long GetTime ()
 
unsigned long GetPrio ()
 
unsigned long GetSize ()
 
void SetLogDestruction (bool abX)
 
unsigned int GetUserCount ()
 
void IncUserCount ()
 
void DecUserCount ()
 
bool HasUsers ()
 

Additional Inherited Members

- Static Public Member Functions inherited from hpl::iMaterial
static void SetQuality (eMaterialQuality aQuality)
 
static eMaterialQuality GetQuality ()
 
- Static Public Member Functions inherited from hpl::iResourceBase
static bool GetLogCreateAndDelete ()
 
static void SetLogCreateAndDelete (bool abX)
 
- Protected Attributes inherited from hpl::iMaterial
iLowLevelGraphics * mpLowLevelGraphics
 
cImageManager * mpImageManager
 
cTextureManager * mpTextureManager
 
cRenderer2D * mpRenderer
 
cRenderer3D * mpRenderer3D
 
cRenderSettings * mpRenderSettings
 
cGpuProgramManager * mpProgramManager
 
bool mbIsTransperant
 
bool mbIsGlowing
 
bool mbUsesLights
 
bool mbHasAlpha
 
bool mbDepthTest
 
float mfValue
 
int mlId
 
tString msPhysicsMaterial
 
tTextureVec mvTexture
 
tResourceImageVec mvImage
 
eMaterialType mType
 
eMaterialPicture mPicture
 
iGpuProgram * mpProgram [2][(5)]
 
int mlPassCount
 
- Protected Attributes inherited from hpl::iResourceBase
unsigned int mlPrio
 
unsigned long mlTime
 
unsigned long mlSize
 
unsigned int mlUserCount
 
unsigned long mlHandle
 
tString msName
 
tString msFilePath
 
bool mbLogDestruction
 
- Static Protected Attributes inherited from hpl::iMaterial
static eMaterialQuality mQuality
 
- Static Protected Attributes inherited from hpl::iResourceBase
static bool mbLogCreateAndDelete
 

Member Function Documentation

◆ GetTextureTypes()

tTextureTypeList hpl::cMaterial_Modulative::GetTextureTypes ( )
virtual

Reimplemented from hpl::iMaterial.

◆ UsesType()

bool hpl::cMaterial_Modulative::UsesType ( eMaterialRenderType  aType)
virtual

Reimplemented from hpl::iMaterial.

◆ getGpuProgram()

iGpuProgram * hpl::cMaterial_Modulative::getGpuProgram ( const eMaterialRenderType  aType,
const int  alPass,
iLight3D *  apLight 
)
virtual

Reimplemented from hpl::iMaterial.

◆ getGpuProgramSetup()

iMaterialProgramSetup * hpl::cMaterial_Modulative::getGpuProgramSetup ( const eMaterialRenderType  aType,
const int  alPass,
iLight3D *  apLight 
)
virtual

Reimplemented from hpl::iMaterial.

◆ VertexProgramUsesLight()

bool hpl::cMaterial_Modulative::VertexProgramUsesLight ( eMaterialRenderType  aType,
int  alPass,
iLight3D *  apLight 
)
virtual

Reimplemented from hpl::iMaterial.

◆ VertexProgramUsesEye()

bool hpl::cMaterial_Modulative::VertexProgramUsesEye ( eMaterialRenderType  aType,
int  alPass,
iLight3D *  apLight 
)
virtual

Reimplemented from hpl::iMaterial.

◆ GetAlphaMode()

eMaterialAlphaMode hpl::cMaterial_Modulative::GetAlphaMode ( eMaterialRenderType  aType,
int  alPass,
iLight3D *  apLight 
)
virtual

Reimplemented from hpl::iMaterial.

◆ GetBlendMode()

eMaterialBlendMode hpl::cMaterial_Modulative::GetBlendMode ( eMaterialRenderType  aType,
int  alPass,
iLight3D *  apLight 
)
virtual

Reimplemented from hpl::iMaterial.

◆ GetChannelMode()

eMaterialChannelMode hpl::cMaterial_Modulative::GetChannelMode ( eMaterialRenderType  aType,
int  alPass,
iLight3D *  apLight 
)
virtual

Reimplemented from hpl::iMaterial.

◆ GetTexture()

iTexture * hpl::cMaterial_Modulative::GetTexture ( int  alUnit,
eMaterialRenderType  aType,
int  alPass,
iLight3D *  apLight 
)
virtual

Reimplemented from hpl::iMaterial.

◆ GetTextureBlend()

eMaterialBlendMode hpl::cMaterial_Modulative::GetTextureBlend ( int  alUnit,
eMaterialRenderType  aType,
int  alPass,
iLight3D *  apLight 
)
virtual

Reimplemented from hpl::iMaterial.

◆ GetNumOfPasses()

int hpl::cMaterial_Modulative::GetNumOfPasses ( eMaterialRenderType  aType,
iLight3D *  apLight 
)
inlinevirtual

Reimplemented from hpl::iMaterial.

◆ Compile()

void hpl::cMaterial_Modulative::Compile ( )
inlinevirtual

Implements hpl::iMaterial.

◆ StartRendering()

bool hpl::cMaterial_Modulative::StartRendering ( eMaterialRenderType  aType,
iCamera *  apCam,
iLight *  pLight 
)
inlinevirtual

Here the set up should be done like setting texture units, blend mode, etc

Parameters
mType
apCam
*pLight
Returns

Implements hpl::iMaterial.

◆ EndRendering()

void hpl::cMaterial_Modulative::EndRendering ( eMaterialRenderType  mType)
inlinevirtual

Here all stuff should be set back to normal, like unbinding gpu programs

Parameters
mType

Implements hpl::iMaterial.

◆ GetBatchFlags()

tVtxBatchFlag hpl::cMaterial_Modulative::GetBatchFlags ( eMaterialRenderType  mType)
inlinevirtual

Return the data types needed for rendering.

Parameters
mType
Returns

Implements hpl::iMaterial.

◆ NextPass()

bool hpl::cMaterial_Modulative::NextPass ( eMaterialRenderType  mType)
inlinevirtual

Set new states and return true for another pass

Parameters
mType
Returns

Implements hpl::iMaterial.

◆ HasMultiplePasses()

bool hpl::cMaterial_Modulative::HasMultiplePasses ( eMaterialRenderType  mType)
inlinevirtual

return true if the program has multple passes

Parameters
mType
Returns

Implements hpl::iMaterial.

◆ GetType()

eMaterialType hpl::cMaterial_Modulative::GetType ( eMaterialRenderType  mType)
inlinevirtual

Get type

Parameters
mType
Returns

Implements hpl::iMaterial.

◆ EditVertexes()

void hpl::cMaterial_Modulative::EditVertexes ( eMaterialRenderType  aType,
iCamera *  apCam,
iLight *  pLight,
tVertexVec *  apVtxVec,
cVector3f *  apTransform,
unsigned int  alIndexAdd 
)
inlinevirtual

Implements hpl::iMaterial.


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