This is a helper class for configuring graphics settings of a World Object. More...
#include <worldobjectgraphicssettings.h>
Public Member Functions | |
| WorldObjectGraphicsSettings (WorldObject *WO, Ogre::Entity *GraphicsObject) | |
| Standard Constructor. | |
| virtual | ~WorldObjectGraphicsSettings () |
| Class destructor. | |
| virtual void | CloneMaterial (const String &NewName) |
| Creates a copy of the material script of the graphics object and places it in the same resource group. | |
| virtual ColourValue | GetMaterialAmbient (const Whole &Submesh=0) const |
| Gets the Ambient colour value of the material belonging to the specified submesh. | |
| virtual ColourValue | GetMaterialDiffuse (const Whole &Submesh=0) const |
| Gets the Diffuse colour value of the material belonging to the specified submesh. | |
| virtual ConstString | GetMaterialName (const Whole &Submesh=0) const |
| Gets the material name of the specified submesh. | |
| virtual ColourValue | GetMaterialSpecular (const Whole &Submesh=0) const |
| Gets the Specular colour value of the material belonging to the specified submesh. | |
| virtual Mesh * | GetMesh () const |
| Gets the mesh being used by this World Object. | |
| virtual Whole | GetNumSubmeshes () const |
| Gets the number of submeshes in the mesh of the graphics ohject. | |
| virtual bool | HasMaterialSet (const Whole &Submesh=0) |
| Gets whether or not the specified submesh has a material script assigned to it. | |
| virtual void | ProtoDeSerialize (const xml::Node &OneNode) |
| Take the data stored in an XML and overwrite this instance of this object with it. | |
| virtual void | ProtoSerialize (xml::Node &CurrentRoot) const |
| Convert this class to an xml::Node ready for serialization. | |
| virtual void | SetMaterial (const String &MatName, const Whole &Submesh=0) |
| Sets the material of the specified submesh. | |
| virtual void | SetMaterialAmbient (const ColourValue &Ambient, const Whole &Submesh=0) |
| Sets the Ambient colour value of the material belonging to the specified submesh. | |
| virtual void | SetMaterialDiffuse (const ColourValue &Diffuse, const Whole &Submesh=0) |
| Sets the Diffuse colour value of the material belonging to the specified submesh. | |
| virtual void | SetMaterialSpecular (const ColourValue &Specular, const Whole &Submesh=0) |
| Sets the Specular colour value of the material belonging to the specified submesh. | |
| virtual void | SetMesh (const String &MeshName, const String &Group) |
| Sets the mesh to be used along with this World Object. | |
| virtual void | SetMesh (Mesh *ObjectMesh) |
| Sets the mesh to be used along with this World Object. | |
Static Public Member Functions | |
| static String | SerializableName () |
| Get the name of the the XML tag this class will leave behind as its instances are serialized. | |
Protected Member Functions | |
| virtual Ogre::MaterialPtr | GetMaterial (const Whole &Submesh=0) |
| Material/textures for the World Object. | |
Protected Attributes | |
| internal::InternalWorldObjectGraphicsSettings * | IWOGS |
| Stores all the data to go with the. | |
| WorldObject * | Parent |
| The World Object this belongs to. | |
| Mesh * | WorldObjectMesh |
| The mesh being used by the World Object. | |
This is a helper class for configuring graphics settings of a World Object.
This class contains functions for the configuring of graphics specific settings of an actor. This class can only configure the actors graphics. For configuring World Object physics, see ActorBasePhysicsSettings.
Definition at line 71 of file worldobjectgraphicssettings.h.
| Mezzanine::WorldObjectGraphicsSettings::WorldObjectGraphicsSettings | ( | WorldObject * | WO, |
| Ogre::Entity * | GraphicsObject | ||
| ) |
Standard Constructor.
| WO | The World Object this settings class configures. |
| GraphicsObject | The graphics object belonging to the World Object this class configures. |
Definition at line 96 of file worldobjectgraphicssettings.cpp.
| void Mezzanine::WorldObjectGraphicsSettings::CloneMaterial | ( | const String & | NewName | ) | [virtual] |
Creates a copy of the material script of the graphics object and places it in the same resource group.
| NewName | of the cloned material script. |
Definition at line 162 of file worldobjectgraphicssettings.cpp.
| ColourValue Mezzanine::WorldObjectGraphicsSettings::GetMaterialAmbient | ( | const Whole & | Submesh = 0 | ) | const [virtual] |
Gets the Ambient colour value of the material belonging to the specified submesh.
If no Ambient colour was specified for a given submesh a default ColourValue is returned.
| Submesh | The submesh you want to alter the material of. |
Definition at line 217 of file worldobjectgraphicssettings.cpp.
| ColourValue Mezzanine::WorldObjectGraphicsSettings::GetMaterialDiffuse | ( | const Whole & | Submesh = 0 | ) | const [virtual] |
Gets the Diffuse colour value of the material belonging to the specified submesh.
If no Diffuse colour was specified for a given submesh a default ColourValue is returned.
| Submesh | The submesh you want to alter the material of. |
Definition at line 231 of file worldobjectgraphicssettings.cpp.
| ConstString Mezzanine::WorldObjectGraphicsSettings::GetMaterialName | ( | const Whole & | Submesh = 0 | ) | const [virtual] |
Gets the material name of the specified submesh.
Note the returned name isn't of the .material file, but the material script.
| Submesh | The submesh you want to get the material name from. |
Definition at line 169 of file worldobjectgraphicssettings.cpp.
| ColourValue Mezzanine::WorldObjectGraphicsSettings::GetMaterialSpecular | ( | const Whole & | Submesh = 0 | ) | const [virtual] |
Gets the Specular colour value of the material belonging to the specified submesh.
If no Specular colour was specified for a given submesh a default ColourValue is returned.
| Submesh | The submesh you want to alter the material of. |
Definition at line 224 of file worldobjectgraphicssettings.cpp.
| Mesh * Mezzanine::WorldObjectGraphicsSettings::GetMesh | ( | ) | const [virtual] |
Gets the mesh being used by this World Object.
Definition at line 142 of file worldobjectgraphicssettings.cpp.
| Whole Mezzanine::WorldObjectGraphicsSettings::GetNumSubmeshes | ( | ) | const [virtual] |
Gets the number of submeshes in the mesh of the graphics ohject.
Definition at line 183 of file worldobjectgraphicssettings.cpp.
| bool Mezzanine::WorldObjectGraphicsSettings::HasMaterialSet | ( | const Whole & | Submesh = 0 | ) | [virtual] |
Gets whether or not the specified submesh has a material script assigned to it.
| Submesh | The submesh to check. |
Definition at line 176 of file worldobjectgraphicssettings.cpp.
| void Mezzanine::WorldObjectGraphicsSettings::ProtoDeSerialize | ( | const xml::Node & | OneNode | ) | [virtual] |
Take the data stored in an XML and overwrite this instance of this object with it.
| OneNode | and xml::Node containing the data. |
Definition at line 302 of file worldobjectgraphicssettings.cpp.
| void Mezzanine::WorldObjectGraphicsSettings::ProtoSerialize | ( | xml::Node & | CurrentRoot | ) | const [virtual] |
Convert this class to an xml::Node ready for serialization.
| CurrentRoot | The point in the XML hierarchy that all this quaternion should be appended to. |
Definition at line 240 of file worldobjectgraphicssettings.cpp.
| String Mezzanine::WorldObjectGraphicsSettings::SerializableName | ( | ) | [static] |
Get the name of the the XML tag this class will leave behind as its instances are serialized.
Definition at line 362 of file worldobjectgraphicssettings.cpp.
| void Mezzanine::WorldObjectGraphicsSettings::SetMaterial | ( | const String & | MatName, |
| const Whole & | Submesh = 0 |
||
| ) | [virtual] |
Sets the material of the specified submesh.
The name of the material isn't the same as the name of the .material file. As a single material file can contain several material scripts. The name this function expects is the name of the material script inside a .material file.
| MatName | The name of the material to be applied. |
| Submesh | The submesh to apply the material to. |
Definition at line 155 of file worldobjectgraphicssettings.cpp.
| void Mezzanine::WorldObjectGraphicsSettings::SetMaterialAmbient | ( | const ColourValue & | Ambient, |
| const Whole & | Submesh = 0 |
||
| ) | [virtual] |
Sets the Ambient colour value of the material belonging to the specified submesh.
The set value is applied to every technique of every pass in the material.
| Ambient | The colour you wish to set as the material Ambient. |
| Submesh | The submesh you want to alter the material of. |
Definition at line 193 of file worldobjectgraphicssettings.cpp.
| void Mezzanine::WorldObjectGraphicsSettings::SetMaterialDiffuse | ( | const ColourValue & | Diffuse, |
| const Whole & | Submesh = 0 |
||
| ) | [virtual] |
Sets the Diffuse colour value of the material belonging to the specified submesh.
The set value is applied to every technique of every pass in the material.
| Diffuse | The colour you wish to set as the material Diffuse. |
| Submesh | The submesh you want to alter the material of. |
Definition at line 209 of file worldobjectgraphicssettings.cpp.
| void Mezzanine::WorldObjectGraphicsSettings::SetMaterialSpecular | ( | const ColourValue & | Specular, |
| const Whole & | Submesh = 0 |
||
| ) | [virtual] |
Sets the Specular colour value of the material belonging to the specified submesh.
The set value is applied to every technique of every pass in the material.
| Specular | The colour you wish to set as the material Specular. |
| Submesh | The submesh you want to alter the material of. |
Definition at line 201 of file worldobjectgraphicssettings.cpp.
| void Mezzanine::WorldObjectGraphicsSettings::SetMesh | ( | Mesh * | ObjectMesh | ) | [virtual] |
Sets the mesh to be used along with this World Object.
Definition at line 112 of file worldobjectgraphicssettings.cpp.
| void Mezzanine::WorldObjectGraphicsSettings::SetMesh | ( | const String & | MeshName, |
| const String & | Group | ||
| ) | [virtual] |
Sets the mesh to be used along with this World Object.
| MeshName | The name of the mesh to apply to this World Object. |
| Group | The resource group to which the mesh belongs. |
Definition at line 136 of file worldobjectgraphicssettings.cpp.
1.7.3