#include <OgreMaterial.hh>
Public Member Functions | |
virtual | ~OgreMaterial () |
virtual math::Color | Ambient () const |
Get the ambient color. More... | |
virtual bool | CastShadows () const |
Determine if this material casts shadows. More... | |
virtual void | ClearNormalMap () |
Removes any normal map mapped to this material. More... | |
virtual void | ClearTexture () |
Removes any texture mapped to this material. More... | |
virtual math::Color | Diffuse () const |
Get the diffuse color. More... | |
virtual math::Color | Emissive () const |
Get the emissive color. More... | |
virtual bool | HasNormalMap () const |
Determine if this material has a normal map. More... | |
virtual bool | HasTexture () const |
Determine if this material has a texture. More... | |
virtual bool | LightingEnabled () const |
Determine if lighting affects this material. More... | |
virtual Ogre::MaterialPtr | Material () const |
virtual std::string | NormalMap () const |
Get the URI of the normal map file. More... | |
virtual bool | ReceiveShadows () const |
Determine if this material receives shadows. More... | |
virtual bool | ReflectionEnabled () const |
Determine if this material has a reflection. More... | |
virtual double | Reflectivity () const |
Get the reflectivity value. More... | |
virtual void | SetAmbient (const math::Color &_color) |
Set the ambient color. More... | |
virtual void | SetCastShadows (const bool _castShadows) |
Specify if this material casts shadows. More... | |
virtual void | SetDiffuse (const math::Color &_color) |
Set the diffuse color. More... | |
virtual void | SetEmissive (const math::Color &_color) |
Set the emissive color. More... | |
virtual void | SetLightingEnabled (const bool _enabled) |
Specify if lighting affects this material. More... | |
virtual void | SetNormalMap (const std::string &_name) |
Set the material normal map. More... | |
virtual void | SetReceiveShadows (const bool _receiveShadows) |
Specify if this material receives shadows. More... | |
virtual void | SetReflectionEnabled (const bool _enabled) |
Specify if this material has a reflection. More... | |
virtual void | SetReflectivity (const double _reflectivity) |
Set the reflectivity value. More... | |
virtual void | SetShaderType (enum ShaderType _type) |
Set the ShaderType value. More... | |
virtual void | SetShininess (const double _shininess) |
Set the shininess value. More... | |
virtual void | SetSpecular (const math::Color &_color) |
Set the specular color. More... | |
virtual void | SetTexture (const std::string &_name) |
Set the material texture. More... | |
virtual void | SetTransparency (const double _transparency) |
Set the transparency value. More... | |
virtual enum ShaderType | ShaderType () const |
Get the ShaderType value. More... | |
virtual double | Shininess () const |
Get the shininess value. More... | |
virtual math::Color | Specular () const |
Get the specular color. More... | |
virtual std::string | Texture () const |
Get the URI of the texture file. More... | |
virtual double | Transparency () const |
Get the transparency value. More... | |
Public Member Functions inherited from BaseMaterial< OgreObject > | |
virtual | ~BaseMaterial () |
virtual MaterialPtr | Clone (const std::string &_name="") const |
Clone this material. More... | |
virtual void | CopyFrom (ConstMaterialPtr _material) |
Copy properties from given Material. More... | |
virtual void | CopyFrom (const common::Material &_material) |
Copy properties from given Material. More... | |
virtual void | PreRender () |
Prepare this object and any of its children for rendering. This should be called for each object in a scene just before rendering, which can be achieved by a single call to Scene::PreRender. More... | |
virtual void | SetAmbient (const double _r, const double _g, const double _b, const double _a=1.0) |
Set the ambient color. More... | |
virtual void | SetDiffuse (const double _r, const double _g, const double _b, const double _a=1.0) |
Set the diffuse color. More... | |
virtual void | SetEmissive (const double _r, const double _g, const double _b, const double _a=1.0) |
Set the emissive color. More... | |
virtual void | SetSpecular (const double _r, const double _g, const double _b, const double _a=1.0) |
Set the specular color. More... | |
Public Member Functions inherited from Material | |
virtual | ~Material () |
Deconstructor. More... | |
Public Member Functions inherited from Object | |
virtual | ~Object () |
Deconstructor. More... | |
Public Member Functions inherited from OgreObject | |
virtual | ~OgreObject () |
virtual ScenePtr | Scene () const |
Get the Scene that created this object. More... | |
Public Member Functions inherited from BaseObject | |
virtual | ~BaseObject () |
virtual void | Destroy () |
Destroy any resources associated with this object. Invoking any other functions after destroying an object will result in undefined behavior. More... | |
virtual unsigned int | Id () const |
Get the object ID. This ID will be unique across all objects inside a given scene, but necessarily true for objects across different scenes. More... | |
virtual std::string | Name () const |
Get the object name. This name will be unique across all objects inside a given scene, but necessarily true for objects across different scenes. More... | |
Public Member Functions inherited from enable_shared_from_this< BaseObject > | |
T | enable_shared_from_this (T... args) |
T | ~enable_shared_from_this (T... args) |
T | operator= (T... args) |
T | shared_from_this (T... args) |
Protected Member Functions | |
OgreMaterial () | |
virtual Ogre::TexturePtr | CreateTexture (const std::string &_name) |
virtual void | Init () |
virtual void | LoadImage (const std::string &_name, Ogre::Image &_image) |
virtual void | SetTextureImpl (const std::string &_texture) |
Set the texture for this material. More... | |
virtual Ogre::TexturePtr | Texture (const std::string &_name) |
virtual void | UpdateColorOperation () |
virtual void | UpdateTransparency () |
Protected Member Functions inherited from BaseMaterial< OgreObject > | |
BaseMaterial () | |
virtual void | Reset () |
Protected Member Functions inherited from OgreObject | |
OgreObject () | |
Protected Member Functions inherited from BaseObject | |
BaseObject () | |
virtual void | Load () |
Protected Attributes | |
bool | castShadows = true |
std::string | normalMapName |
Ogre::String | ogreGroup |
Ogre::MaterialPtr | ogreMaterial |
Ogre::Pass * | ogrePass = nullptr |
Ogre::Technique * | ogreTechnique = nullptr |
Ogre::TextureUnitState * | ogreTexState = nullptr |
bool | reflectionEnabled = true |
double | reflectivity = 0.0 |
enum ShaderType | shaderType = ST_PIXEL |
double | shininess = 0.0 |
std::string | textureName |
double | transparency = 0.0 |
Protected Attributes inherited from OgreObject | |
OgreScenePtr | scene |
Protected Attributes inherited from BaseObject | |
unsigned int | id |
std::string | name |
Constructor & Destructor Documentation
◆ OgreMaterial()
|
protected |
◆ ~OgreMaterial()
|
virtual |
Member Function Documentation
◆ Ambient()
|
virtual |
◆ CastShadows()
|
virtual |
Determine if this material casts shadows.
- Returns
- True if this material casts shadows
Implements Material.
◆ ClearNormalMap()
|
virtual |
Removes any normal map mapped to this material.
Implements BaseMaterial< OgreObject >.
◆ ClearTexture()
|
virtual |
Removes any texture mapped to this material.
Implements BaseMaterial< OgreObject >.
◆ CreateTexture()
|
protectedvirtual |
◆ Diffuse()
|
virtual |
◆ Emissive()
|
virtual |
◆ HasNormalMap()
|
virtual |
Determine if this material has a normal map.
- Returns
- True if this material has a normal map
Implements Material.
◆ HasTexture()
|
virtual |
Determine if this material has a texture.
- Returns
- True if this material has a texture
Implements Material.
◆ Init()
|
protectedvirtual |
Reimplemented from BaseObject.
◆ LightingEnabled()
|
virtual |
Determine if lighting affects this material.
- Returns
- True if lighting affects this material
Implements Material.
◆ LoadImage()
|
protectedvirtual |
◆ Material()
|
virtual |
◆ NormalMap()
|
virtual |
◆ ReceiveShadows()
|
virtual |
Determine if this material receives shadows.
- Returns
- True if this material receives shadows
Implements Material.
◆ ReflectionEnabled()
|
virtual |
Determine if this material has a reflection.
- Returns
- True if this material has a reflection
Implements Material.
◆ Reflectivity()
|
virtual |
◆ SetAmbient()
|
virtual |
Set the ambient color.
- Parameters
-
[in] _color New ambient color
Implements BaseMaterial< OgreObject >.
◆ SetCastShadows()
|
virtual |
Specify if this material casts shadows.
- Parameters
-
[in] _castShadows True if this material casts shadows
Implements Material.
◆ SetDiffuse()
|
virtual |
Set the diffuse color.
- Parameters
-
[in] _color New diffuse color
Implements BaseMaterial< OgreObject >.
◆ SetEmissive()
|
virtual |
Set the emissive color.
- Parameters
-
[in] _color New emissive color
Implements BaseMaterial< OgreObject >.
◆ SetLightingEnabled()
|
virtual |
Specify if lighting affects this material.
- Parameters
-
[in] _enabled True if lighting affects this material
Implements Material.
◆ SetNormalMap()
|
virtual |
Set the material normal map.
- Parameters
-
[in] _name URI of the new normal map file
Implements Material.
◆ SetReceiveShadows()
|
virtual |
Specify if this material receives shadows.
- Parameters
-
[in] _receiveShadows True if this material receives shadows
Implements BaseMaterial< OgreObject >.
◆ SetReflectionEnabled()
|
virtual |
Specify if this material has a reflection.
- Parameters
-
[in] _enabled True if this material has a reflection
Implements Material.
◆ SetReflectivity()
|
virtual |
◆ SetShaderType()
|
virtual |
Set the ShaderType value.
- Parameters
-
[in] _type New ShaderType value
Implements BaseMaterial< OgreObject >.
◆ SetShininess()
|
virtual |
◆ SetSpecular()
|
virtual |
Set the specular color.
- Parameters
-
[in] _color New specular color
Implements BaseMaterial< OgreObject >.
◆ SetTexture()
|
virtual |
◆ SetTextureImpl()
|
protectedvirtual |
Set the texture for this material.
- Parameters
-
[in] _texture Name of the texture.
◆ SetTransparency()
|
virtual |
◆ ShaderType()
|
virtual |
◆ Shininess()
|
virtual |
◆ Specular()
|
virtual |
◆ Texture() [1/2]
|
virtual |
◆ Texture() [2/2]
|
protectedvirtual |
◆ Transparency()
|
virtual |
◆ UpdateColorOperation()
|
protectedvirtual |
◆ UpdateTransparency()
|
protectedvirtual |
Member Data Documentation
◆ castShadows
|
protected |
◆ normalMapName
|
protected |
◆ ogreGroup
|
protected |
◆ ogreMaterial
|
protected |
◆ ogrePass
|
protected |
◆ ogreTechnique
|
protected |
◆ ogreTexState
|
protected |
◆ reflectionEnabled
|
protected |
◆ reflectivity
|
protected |
◆ shaderType
|
protected |
◆ shininess
|
protected |
◆ textureName
|
protected |
◆ transparency
|
protected |
The documentation for this class was generated from the following file: