MercuryMaterial Class Reference

[internal] Material to apply to object More...

#include <MercuryMaterial.h>

Inheritance diagram for MercuryMaterial:

Inheritance graph
Collaboration diagram for MercuryMaterial:

Collaboration graph
List of all members.

Public Member Functions

 MercuryMaterial ()
 ~MercuryMaterial ()
virtual void Message (int Message, PStack &data, const MString &name)
 Receive message (When subscribing to messages, you receive them via this command).
void AddTexture (MercuryTexture *texture)
MercuryTextureEditTexture (unsigned int i)
const MercuryTextureGetTexture (unsigned int i) const
unsigned int NumTextures () const
bool LoadMaterial (const MString &filename, const MString &path="")
void ClearTextures ()
int GetShaderID () const
const MercuryMaterialoperator= (const MercuryMaterial &m)
const MercuryMaterial operator * (const MercuryMaterial &m)
const MercuryMaterialoperator *= (const MercuryMaterial &m)

Public Attributes

MString m_name
MercuryColor m_diffuse
MercuryColor m_ambient
MercuryColor m_specular
MercuryColor m_emissive
float m_shininess
float m_alpha
MVector< MStringm_vUniformNames
MVector< PStackm_vUniformValues

Private Member Functions

void BuildShader ()

Private Attributes

MString m_completePath
MVector< MAutoPtr< MercuryTexture > > m_textures
int m_iGLSLShaderID
unsigned m_iGLSLVertTime
unsigned m_iGLSLFragTime
MString m_GLSLFragmentFile
MString m_GLSLVertexFile
bool m_bHasRegistered

Detailed Description

[internal] Material to apply to object

Definition at line 10 of file MercuryMaterial.h.

Constructor & Destructor Documentation

MercuryMaterial::MercuryMaterial (  ) 

Definition at line 17 of file MercuryMaterial.cpp.

MercuryMaterial::~MercuryMaterial (  ) 

Definition at line 10 of file MercuryMaterial.cpp.

Member Function Documentation

void MercuryMaterial::Message ( int  Message,
PStack data,
const MString name 
) [virtual]

Receive message (When subscribing to messages, you receive them via this command).

Reimplemented from MercuryMessageHandler.

Definition at line 31 of file MercuryMaterial.cpp.

void MercuryMaterial::AddTexture ( MercuryTexture texture  ) 

Definition at line 25 of file MercuryMaterial.cpp.

MercuryTexture* MercuryMaterial::EditTexture ( unsigned int  i  )  [inline]

Definition at line 18 of file MercuryMaterial.h.

const MercuryTexture* MercuryMaterial::GetTexture ( unsigned int  i  )  const [inline]

Definition at line 19 of file MercuryMaterial.h.

unsigned int MercuryMaterial::NumTextures (  )  const [inline]

Definition at line 20 of file MercuryMaterial.h.

bool MercuryMaterial::LoadMaterial ( const MString filename,
const MString path = "" 

Definition at line 73 of file MercuryMaterial.cpp.

void MercuryMaterial::ClearTextures (  ) 

Definition at line 256 of file MercuryMaterial.cpp.

int MercuryMaterial::GetShaderID (  )  const [inline]

Definition at line 23 of file MercuryMaterial.h.

const MercuryMaterial & MercuryMaterial::operator= ( const MercuryMaterial m  ) 

Definition at line 261 of file MercuryMaterial.cpp.

const MercuryMaterial MercuryMaterial::operator * ( const MercuryMaterial m  ) 

Definition at line 275 of file MercuryMaterial.cpp.

const MercuryMaterial & MercuryMaterial::operator *= ( const MercuryMaterial m  ) 

Definition at line 287 of file MercuryMaterial.cpp.

void MercuryMaterial::BuildShader (  )  [private]

Definition at line 60 of file MercuryMaterial.cpp.

Member Data Documentation

MString MercuryMaterial::m_name

Definition at line 29 of file MercuryMaterial.h.

MercuryColor MercuryMaterial::m_diffuse

Definition at line 32 of file MercuryMaterial.h.

MercuryColor MercuryMaterial::m_ambient

Definition at line 33 of file MercuryMaterial.h.

MercuryColor MercuryMaterial::m_specular

Definition at line 34 of file MercuryMaterial.h.

MercuryColor MercuryMaterial::m_emissive

Definition at line 35 of file MercuryMaterial.h.

float MercuryMaterial::m_shininess

Definition at line 36 of file MercuryMaterial.h.

float MercuryMaterial::m_alpha

Definition at line 38 of file MercuryMaterial.h.

MVector<MString> MercuryMaterial::m_vUniformNames

Definition at line 40 of file MercuryMaterial.h.

MVector<PStack> MercuryMaterial::m_vUniformValues

Definition at line 41 of file MercuryMaterial.h.

MString MercuryMaterial::m_completePath [private]

Definition at line 46 of file MercuryMaterial.h.

MVector< MAutoPtr<MercuryTexture> > MercuryMaterial::m_textures [private]

Definition at line 47 of file MercuryMaterial.h.

int MercuryMaterial::m_iGLSLShaderID [private]

Definition at line 50 of file MercuryMaterial.h.

unsigned MercuryMaterial::m_iGLSLVertTime [private]

Definition at line 52 of file MercuryMaterial.h.

unsigned MercuryMaterial::m_iGLSLFragTime [private]

Definition at line 53 of file MercuryMaterial.h.

MString MercuryMaterial::m_GLSLFragmentFile [private]

Definition at line 54 of file MercuryMaterial.h.

MString MercuryMaterial::m_GLSLVertexFile [private]

Definition at line 55 of file MercuryMaterial.h.

bool MercuryMaterial::m_bHasRegistered [private]

Definition at line 56 of file MercuryMaterial.h.

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