This is the proxy class for placing and manipulating lighting in the scene. More...
#include <lightproxy.h>
Public Member Functions | |
LightProxy (const UInt32 ID, SceneManager *Creator) | |
Blank constructor. More... | |
LightProxy (const UInt32 ID, const Graphics::LightType Type, SceneManager *Creator) | |
Type constructor. More... | |
LightProxy (const XML::Node &SelfRoot, SceneManager *Creator) | |
XML constructor. More... | |
virtual | ~LightProxy () |
Class destructor. | |
virtual Ogre::MovableObject * | _GetBaseGraphicsObject () const |
Accessor for the internal graphics object. More... | |
virtual Ogre::Light * | _GetGraphicsObject () const |
Accessor for the internal light. More... | |
virtual Real | GetAttenuationConstant () const |
Gets the constant factor of the attenuation. More... | |
virtual Real | GetAttenuationLinear () const |
Gets the linear factor of the attentuation. More... | |
virtual Real | GetAttenuationQuadratic () const |
Gets the quadric factor of the attenuation. More... | |
virtual Real | GetAttenuationRange () const |
Gets the absolute range of attenuation in world units. More... | |
virtual String | GetDerivedSerializableName () const |
Gets the most derived serializable name of this WorldProxy. More... | |
virtual ColourValue | GetDiffuseColour () const |
Gets the current colour of Diffuse light being emitted by this proxy. More... | |
virtual Vector3 | GetDirection () const |
Gets the direction the light from this source is being emitted. More... | |
virtual Real | GetPowerScale () const |
Gets the power scale of this light, which indicates it's relative power. More... | |
virtual Mezzanine::ProxyType | GetProxyType () const |
Accessor for the type of proxy. More... | |
virtual ColourValue | GetSpecularColour () const |
Gets the current colour of Specular light being emitted by this proxy. More... | |
virtual Real | GetSpotlightFalloff () const |
Gets the rate of falloff of the cone of light emitted by this spotlight. More... | |
virtual Real | GetSpotlightInnerAngle () const |
Gets the Inner angle of the cone of light emitted by this spotlight. More... | |
virtual Real | GetSpotlightNearClipDistance () const |
Gets the near clip plane distance to be used by spotlights that use light clipping. More... | |
virtual Real | GetSpotlightOuterAngle () const |
Gets the Outer angle of the cone of light emitted by this spotlight. More... | |
virtual Graphics::LightType | GetType () const |
Gets the type of light that this light is. More... | |
virtual void | ProtoDeSerializeProperties (const XML::Node &SelfRoot) |
Take the data stored in an XML Node and overwrite the properties of this object with it. More... | |
virtual void | ProtoSerializeProperties (XML::Node &SelfRoot) const |
Convert the properties of this class to an XML::Node ready for serialization. More... | |
virtual void | SetAttenuation (const Real Range, const Real Constant, const Real Linear, const Real Quadratic) |
Sets the factors for the attenuation formula applied to this light. More... | |
virtual void | SetDiffuseColour (const ColourValue &Diffuse) |
Sets the colour for the Diffuse light from this source. More... | |
virtual void | SetDirection (const Vector3 &Dir) |
Sets the direction the light will be emitted from this source. More... | |
virtual void | SetPowerScale (const Real Scale) |
Sets the power scale of this light, which indicates it's relative power. More... | |
virtual void | SetSpecularColour (const ColourValue &Specular) |
Sets the colour for the Specular light from this source. More... | |
virtual void | SetSpotlightFalloff (const Real Falloff) |
Sets the rate of falloff of the cone of light emitted by a spotlight. More... | |
virtual void | SetSpotlightInnerAngle (const Real Angle) |
Sets the Inner angle of the cone of light emitted by a spotlight. More... | |
virtual void | SetSpotlightNearClipDistance (const Real NearClip) |
Sets the near clip plane distance to be used by spotlights that use light clipping. More... | |
virtual void | SetSpotlightOuterAngle (const Real Angle) |
Sets the Outer angle of the cone of light emitted by a spotlight. More... | |
virtual void | SetSpotlightRange (const Real InnerAngle, const Real OuterAngle, const Real Falloff=1.0) |
Defines the cone of light emitted by a spotlight. More... | |
virtual void | SetType (const Graphics::LightType Type) |
Sets the type of light this light is. More... | |
Public Member Functions inherited from Mezzanine::Graphics::RenderableProxy | |
RenderableProxy (SceneManager *Creator) | |
XML-assist Constructor. More... | |
RenderableProxy (const UInt32 ID, SceneManager *Creator) | |
Normal Constructor. More... | |
virtual | ~RenderableProxy () |
Class destructor. | |
virtual Ogre::SceneNode * | _GetGraphicsNode () const |
Accessor for the internal node in the scenegraph for this proxy. More... | |
virtual void | AddToWorld () |
Performs all the necessary task to ensure this object is connected to it's respective world and ready for use. More... | |
virtual AxisAlignedBox | GetAABB () const |
Gets this proxies AABB. More... | |
virtual Boole | GetCastShadows () const |
Gets whether or not this proxy can cast a shadow. More... | |
virtual WorldManager * | GetCreator () const |
Gets a pointer to this proxies creator. More... | |
virtual UInt32 | GetLightMask () const |
Gets which types of lights will affect this proxy. More... | |
virtual Vector3 | GetLocation () const |
Gets this objects current location. More... | |
virtual Quaternion | GetOrientation () const |
Gets this objects current orientation. More... | |
virtual UInt32 | GetQueryMask () const |
Gets the bitmask that will be used to determine if this object should be counted in scene queries. More... | |
virtual Boole | GetReceiveShadows () const |
Gets whether or not this proxy can be rendered with a shadow casted on it. More... | |
virtual Real | GetRenderDistance () const |
Gets the distance at which the proxy will stop rendering. More... | |
virtual Vector3 | GetScale () const |
Gets the scaling currently being applied to this object. More... | |
virtual UInt32 | GetVisibilityMask () const |
Gets the bitmask that will be used to determine if this object should be visible when rendering. More... | |
virtual Boole | GetVisible () const |
Gets whether or not this proxy is visible. More... | |
virtual Boole | IsInWorld () const |
Gets whether or not this object is inside of it's world. More... | |
virtual void | Pitch (const Real Angle) |
Rotate the object around the X axis. More... | |
virtual void | RemoveFromWorld () |
Unhooks this proxy from it's respective world. More... | |
virtual void | Roll (const Real Angle) |
Rotate the object around the Z axis. More... | |
virtual void | Rotate (const Vector3 &Axis, const Real Angle) |
Rotates the object from it's existing rotation. More... | |
virtual void | Rotate (const Quaternion &Rotation) |
Rotates the object from it's existing rotation. More... | |
virtual void | Scale (const Vector3 &Scale) |
Scales the object from it's current size. More... | |
virtual void | Scale (const Real X, const Real Y, const Real Z) |
Scales the object from it's current size. More... | |
virtual void | SetCastShadows (const Boole CastShadows) |
Sets whether or not this proxy can cast a shadow. More... | |
virtual void | SetLightMask (const UInt32 Mask) |
Sets which types of lights will affect this proxy. More... | |
virtual void | SetLocation (const Vector3 &Loc) |
Sets the location of this object in parent space. More... | |
virtual void | SetLocation (const Real X, const Real Y, const Real Z) |
Sets the location of this object in parent space via Reals. More... | |
virtual void | SetOrientation (const Quaternion &Ori) |
Sets the orientation of this object in parent space. More... | |
virtual void | SetOrientation (const Real X, const Real Y, const Real Z, const Real W) |
Sets the orientation of this object in parent space via Reals. More... | |
virtual void | SetQueryMask (const UInt32 Mask) |
Sets the bitmesk that will be used to determine if this object should be counted in scene queries. More... | |
virtual void | SetRenderDistance (const Real Distance) |
Sets the distance at which the proxy will stop rendering. More... | |
virtual void | SetScale (const Vector3 &Sc) |
Sets the scaling to be applied to this object. More... | |
virtual void | SetScale (const Real X, const Real Y, const Real Z) |
Sets the scaling to be applied to this object via Reals. More... | |
virtual void | SetVisibilityMask (const UInt32 Mask) |
Sets the bitmask that will be used to determine if this object should be visible when rendering. More... | |
virtual void | SetVisible (const Boole Visible) |
Sets whether or not this proxy is visible. More... | |
virtual void | Translate (const Vector3 &Trans) |
Moves this object from it's current location. More... | |
virtual void | Translate (const Real X, const Real Y, const Real Z) |
Moves this object from it's current location. More... | |
virtual void | Yaw (const Real Angle) |
Rotate the object around the Y axis. More... | |
Public Member Functions inherited from Mezzanine::WorldProxy | |
WorldProxy () | |
Blank constructor. | |
WorldProxy (const UInt32 ID) | |
Normal/ID constructor. More... | |
virtual | ~WorldProxy () |
Class destructor. | |
void | _Bind (WorldObject *NewParent) |
Binds this proxy to a WorldObject. More... | |
virtual WorldObject * | GetParentObject () const |
Gets a pointer to the parent object controlling this proxy. More... | |
virtual UInt32 | GetProxyID () const |
Gets the unique ID of this proxy. More... | |
virtual void | ProtoDeSerialize (const XML::Node &SelfRoot) |
Take the data stored in an XML Node and overwrite this object with it. More... | |
virtual void | ProtoSerialize (XML::Node &ParentNode) const |
Convert this class to an XML::Node ready for serialization. More... | |
Public Member Functions inherited from Mezzanine::TransformableObject | |
virtual | ~TransformableObject () |
Class Destructor. | |
virtual Vector3 | ConvertGlobalToLocal (const Vector3 &Location) const |
Converts a point in global space to the same point in local space. More... | |
virtual Quaternion | ConvertGlobalToLocal (const Quaternion &Orientation) const |
Converts a rotation in global space to the same rotation in local space. More... | |
virtual Vector3 | ConvertLocalToGlobal (const Vector3 &Location) const |
Converts a point in local space to the same point in global space. More... | |
virtual Quaternion | ConvertLocalToGlobal (const Quaternion &Orientation) const |
Converts a rotation in local space to the same rotation in global space. More... | |
Static Public Member Functions | |
static String | GetSerializableName () |
Get the name of the the XML tag the proxy class will leave behind as its instances are serialized. More... | |
Static Public Member Functions inherited from Mezzanine::Graphics::RenderableProxy | |
static String | GetSerializableName () |
Get the name of the the XML tag the proxy class will leave behind as its instances are serialized. More... | |
Static Public Member Functions inherited from Mezzanine::WorldProxy | |
static String | GetSerializableName () |
Get the name of the the XML tag the proxy class will leave behind as its instances are serialized. More... | |
Protected Member Functions | |
virtual void | CreateLight () |
Creates an internal light to be used by the calling instance. More... | |
virtual void | DestroyLight () |
Destroys the internal light in use by this proxy. More... | |
Protected Member Functions inherited from Mezzanine::WorldProxy | |
virtual void | ProtoDeSerializeImpl (const XML::Node &SelfRoot) |
Implementation method for deseriailizing additional sets of data. More... | |
virtual void | ProtoSerializeImpl (XML::Node &SelfRoot) const |
Implementation method for serializing additional sets of data. More... | |
Protected Attributes | |
Ogre::Light * | GraphicsLight |
A pointer to the internal Light this proxy is based on. More... | |
Protected Attributes inherited from Mezzanine::Graphics::RenderableProxy | |
Ogre::SceneNode * | GraphicsNode |
A pointer to the internal object storing the proxy transform. More... | |
Boole | InWorld |
This stores whether the proxy is currently in the graphics world or not. More... | |
SceneManager * | Manager |
This is a pointer to the scene manager that created and owns this proxy. More... | |
UInt32 | QueryMask |
This is a bitmask identifying this objects type when being queried. Used for advanced query configuration. More... | |
UInt32 | VisibilityMask |
This is a bitmask identifying this objects type when being rendered. Used for advanced visibility configuration. More... | |
Protected Attributes inherited from Mezzanine::WorldProxy | |
WorldObject * | ParentObject |
Pointer to the Object this proxy belongs to. More... | |
UInt32 | ProxyID |
The unique ID assigned to the type of proxy an instance is. More... | |
This is the proxy class for placing and manipulating lighting in the scene.
Definition at line 63 of file lightproxy.h.
Mezzanine::Graphics::LightProxy::LightProxy | ( | const UInt32 | ID, |
SceneManager * | Creator | ||
) |
Blank constructor.
ID | The unique ID assigned to this LightProxy. |
Creator | A pointer to the manager that created this proxy. |
Definition at line 92 of file lightproxy.cpp.
Mezzanine::Graphics::LightProxy::LightProxy | ( | const UInt32 | ID, |
const Graphics::LightType | Type, | ||
SceneManager * | Creator | ||
) |
Type constructor.
ID | The unique ID assigned to this LightProxy. |
Type | The type of light this light is to be constructed as. |
Creator | A pointer to the manager that created this proxy. |
Definition at line 97 of file lightproxy.cpp.
Mezzanine::Graphics::LightProxy::LightProxy | ( | const XML::Node & | SelfRoot, |
SceneManager * | Creator | ||
) |
XML constructor.
SelfRoot | An XML::Node containing the data to populate this class with. |
Creator | A pointer to the manager that created this proxy. |
Definition at line 102 of file lightproxy.cpp.
|
virtual |
Accessor for the internal graphics object.
Implements Mezzanine::Graphics::RenderableProxy.
Definition at line 327 of file lightproxy.cpp.
|
virtual |
Accessor for the internal light.
Definition at line 324 of file lightproxy.cpp.
|
protectedvirtual |
Creates an internal light to be used by the calling instance.
Definition at line 113 of file lightproxy.cpp.
|
protectedvirtual |
Destroys the internal light in use by this proxy.
Definition at line 122 of file lightproxy.cpp.
|
virtual |
Gets the constant factor of the attenuation.
Definition at line 169 of file lightproxy.cpp.
|
virtual |
Gets the linear factor of the attentuation.
Definition at line 172 of file lightproxy.cpp.
|
virtual |
Gets the quadric factor of the attenuation.
Definition at line 175 of file lightproxy.cpp.
|
virtual |
Gets the absolute range of attenuation in world units.
Definition at line 166 of file lightproxy.cpp.
|
virtual |
Gets the most derived serializable name of this WorldProxy.
Reimplemented from Mezzanine::Graphics::RenderableProxy.
Definition at line 315 of file lightproxy.cpp.
|
virtual |
Gets the current colour of Diffuse light being emitted by this proxy.
Definition at line 148 of file lightproxy.cpp.
|
virtual |
Gets the direction the light from this source is being emitted.
Definition at line 139 of file lightproxy.cpp.
|
virtual |
Gets the power scale of this light, which indicates it's relative power.
Definition at line 181 of file lightproxy.cpp.
|
virtual |
Accessor for the type of proxy.
Implements Mezzanine::WorldProxy.
Definition at line 133 of file lightproxy.cpp.
|
static |
Get the name of the the XML tag the proxy class will leave behind as its instances are serialized.
Definition at line 318 of file lightproxy.cpp.
|
virtual |
Gets the current colour of Specular light being emitted by this proxy.
Definition at line 154 of file lightproxy.cpp.
|
virtual |
Gets the rate of falloff of the cone of light emitted by this spotlight.
Definition at line 202 of file lightproxy.cpp.
|
virtual |
Gets the Inner angle of the cone of light emitted by this spotlight.
Definition at line 190 of file lightproxy.cpp.
|
virtual |
Gets the near clip plane distance to be used by spotlights that use light clipping.
Definition at line 208 of file lightproxy.cpp.
|
virtual |
Gets the Outer angle of the cone of light emitted by this spotlight.
Definition at line 196 of file lightproxy.cpp.
|
virtual |
Gets the type of light that this light is.
Definition at line 160 of file lightproxy.cpp.
|
virtual |
Take the data stored in an XML Node and overwrite the properties of this object with it.
SelfRoot | An XML::Node containing the data to populate this class with. |
Reimplemented from Mezzanine::Graphics::RenderableProxy.
Definition at line 243 of file lightproxy.cpp.
|
virtual |
Convert the properties of this class to an XML::Node ready for serialization.
SelfRoot | The root node containing all the serialized data for this instance. |
Reimplemented from Mezzanine::Graphics::RenderableProxy.
Definition at line 214 of file lightproxy.cpp.
|
virtual |
Sets the factors for the attenuation formula applied to this light.
Range | The absolute range of the light in world units. Objects beyond this range will not be influenced by this light. |
Constant | The constant of the attenuation, ranging from 0.0 to 1.0. 1.0 means never attenuate, 0.0 is complete attenuation. |
Linear | The linear factor of the attentuation, ranging from 0.0 to 1.0. 1.0 means attenuate evenly over the distance. |
Quadratic | The Quadratic factor of the attenuation. This value adds curvature to the attenuation. |
Definition at line 163 of file lightproxy.cpp.
|
virtual |
Sets the colour for the Diffuse light from this source.
Diffuse | ColourValue representing the color of the Diffuse light to be set. |
Definition at line 145 of file lightproxy.cpp.
|
virtual |
Sets the direction the light will be emitted from this source.
Dir | A Vector3 representing the direction the light will travel from this source. |
Definition at line 136 of file lightproxy.cpp.
|
virtual |
Sets the power scale of this light, which indicates it's relative power.
Scale | The power scale to set for this light. |
Definition at line 178 of file lightproxy.cpp.
|
virtual |
Sets the colour for the Specular light from this source.
Specular | ColourValue representing the color of the Specular light to be set. |
Definition at line 151 of file lightproxy.cpp.
|
virtual |
Sets the rate of falloff of the cone of light emitted by a spotlight.
Falloff | The rate of falloff between the inner and outer cones. 1.0 means linear falloff. Less means slower falloff and higher means faster falloff. |
Definition at line 199 of file lightproxy.cpp.
|
virtual |
Sets the Inner angle of the cone of light emitted by a spotlight.
Angle | The angle of the inner cone in radians. |
Definition at line 187 of file lightproxy.cpp.
|
virtual |
Sets the near clip plane distance to be used by spotlights that use light clipping.
NearClip | A Real representing the near clip distance used by spotlights. |
Definition at line 205 of file lightproxy.cpp.
|
virtual |
Sets the Outer angle of the cone of light emitted by a spotlight.
Angle | The angle of the outer cone in radians. |
Definition at line 193 of file lightproxy.cpp.
|
virtual |
Defines the cone of light emitted by a spotlight.
InnerAngle | Angle of the inner cone in radians. |
OuterAngle | Angle of the outer cone in radions. |
Falloff | The rate of falloff between the inner and outer cones. 1.0 means linear falloff. Less means slower falloff and higher means faster falloff. |
Definition at line 184 of file lightproxy.cpp.
|
virtual |
Sets the type of light this light is.
Type | The enum value representing the type of light this will become. |
Definition at line 157 of file lightproxy.cpp.
|
protected |
A pointer to the internal Light this proxy is based on.
Definition at line 68 of file lightproxy.h.