29 #ifndef __MovableObject_H__ 30 #define __MovableObject_H__ 47 class MovableObjectFactory;
196 virtual const String& getMovableType(
void)
const = 0;
204 virtual Node* getParentNode(
void)
const;
213 virtual SceneNode* getParentSceneNode(
void)
const;
220 virtual void _notifyAttached(
Node* parent,
bool isTagPoint =
false);
223 virtual bool isAttached(
void)
const;
226 virtual void detachFromParent(
void);
231 virtual bool isInScene(
void)
const;
235 virtual void _notifyMoved(
void);
242 virtual void _notifyCurrentCamera(
Camera* cam);
253 virtual Real getBoundingRadius(
void)
const = 0;
256 virtual const AxisAlignedBox& getWorldBoundingBox(
bool derive =
false)
const;
258 virtual const Sphere& getWorldBoundingSphere(
bool derive =
false)
const;
264 virtual void _updateRenderQueue(
RenderQueue* queue) = 0;
280 virtual void setVisible(
bool visible);
286 virtual bool getVisible(
void)
const;
292 virtual bool isVisible(
void)
const;
300 mUpperDistance = dist;
301 mSquaredUpperDistance = mUpperDistance * mUpperDistance;
313 mMinPixelSize = pixelSize;
319 return mMinPixelSize;
360 virtual void setRenderQueueGroup(
uint8 queueID);
377 virtual void setRenderQueueGroupAndPriority(
uint8 queueID,
ushort priority);
380 virtual uint8 getRenderQueueGroup(
void)
const;
383 virtual const Matrix4& _getParentNodeFullTransform(
void)
const;
470 virtual const LightList& queryLights(
void)
const;
483 virtual void setLightMask(
uint32 lightMask);
501 bool extrudeVertices,
Real extrusionDist,
unsigned long flags = 0);
525 bool getReceivesShadows();
528 Real getPointExtrusionDistance(
const Light* l)
const;
539 virtual uint32 getTypeFlags(
void)
const;
553 bool debugRenderables =
false) = 0;
591 virtual const String& getType(
void)
const = 0;
Real mUpperDistance
Upper distance to still render.
virtual OGRE_DEPRECATED void setUserAny(const Any &anything)
static uint32 getDefaultVisibilityFlags()
Get the default visibility flags for all future MovableObject instances.
void setCastShadows(bool enabled)
Sets whether or not this object will cast shadows.
static void setDefaultQueryFlags(uint32 flags)
Set the default query flags for all future MovableObject instances.
uint8 mRenderQueueID
The render queue to use when rendering this object.
static uint32 msDefaultVisibilityFlags
Default visibility flags.
uint32 getTypeFlags(void) const
Gets the type flag for this factory.
Concrete IteratorWrapper for nonconst access to the underlying container.
bool getCastShadows(void) const
Returns whether shadow casting is enabled for this object.
bool mRenderQueuePrioritySet
Flags whether the RenderQueue's default should be used.
Abstract class defining a movable object in a scene.
void _notifyTypeFlags(uint32 flag)
Notify this factory of the type mask to apply.
Shared pointer implementation used to share index buffers.
bool mRenderQueueIDSet
Flags whether the RenderQueue's default should be used.
AxisAlignedBox mWorldAABB
Cached world AABB of this object.
bool mCastShadows
Does this object cast shadows?
bool mRenderingDisabled
Does rendering this object disabled by listener?
static uint32 msDefaultQueryFlags
Default query flags.
virtual void _notifyCreator(MovableObjectFactory *fact)
Notify the object of it's creator (internal use only)
virtual uint32 getLightMask() const
Get a bitwise mask which will filter the lights affecting this object.
virtual void removeVisibilityFlags(uint32 flags)
As setVisibilityFlags, except the flags passed as parameters are removed from the existing flags on t...
A sphere primitive, mostly used for bounds checking.
virtual void setQueryFlags(uint32 flags)
Sets the query flags for this object.
virtual void setRenderingDistance(Real dist)
Sets the distance at which the object is no longer rendered.
virtual bool requestTypeFlags(void) const
Does this factory require the allocation of a 'type flag', used to selectively include / exclude this...
float Real
Software floating point type.
Class to manage the scene object rendering queue.
String mName
Name of this object.
virtual void objectDetached(MovableObject *)
MovableObject has been detached from a node.
bool hasEdgeList(void)
Define a default implementation of method from ShadowCaster which implements no shadows.
Class representing a node in the scene graph.
virtual void setVisibilityFlags(uint32 flags)
Sets the visibility flags for this object.
ShadowTechnique
An enumeration of broad shadow techniques.
virtual ~MovableObjectFactory()
virtual uint32 getQueryFlags(void) const
Returns the query flags relevant for this object.
UserObjectBindings & getUserObjectBindings()
Return an instance of user objects binding associated with this class.
virtual SceneManager * _getManager(void) const
Get the manager of this object, if any (internal use only)
static uint32 getDefaultQueryFlags()
Get the default query flags for all future MovableObject instances.
Variant type that can hold Any other type.
This class contains the information required to describe the edge connectivity of a given set of vert...
Listener * mListener
MovableObject listener - only one allowed (no list) for size & performance reasons. */.
Class encapsulating a standard 4x4 homogeneous matrix.
virtual const String & getName(void) const
Returns the name of this object.
virtual const LightList * objectQueryLights(const MovableObject *)
Called when the movable object needs to query a light list.
uint32 mLightMask
the light mask defined for this movable. This will be taken into consideration when deciding which li...
bool mDebugDisplay
Is debug display enabled?
virtual void objectAttached(MovableObject *)
MovableObject has been attached to a node.
virtual void setRenderingMinPixelSize(Real pixelSize)
Sets the minimum pixel size an object needs to be in both screen axes in order to be rendered...
static void setDefaultVisibilityFlags(uint32 flags)
Set the default visibility flags for all future MovableObject instances.
Real mSquaredUpperDistance
Visitor object that can be used to iterate over a collection of Renderable instances abstractly...
Class representing a general-purpose node an articulated scene graph.
ushort mRenderQueuePriority
The render queue group to use when rendering this object.
virtual Real getRenderingMinPixelSize() const
Returns the minimum pixel size an object needs to be in both screen axes in order to be rendered...
map< String, String >::type NameValuePairList
Name / value parameter pair (first = name, second = value)
virtual void setDebugDisplayEnabled(bool enabled)
Sets whether or not the debug display of this object is enabled.
This class defines the interface that must be implemented by shadow casters.
virtual bool isParentTagPoint() const
Gets whether the parent node is a TagPoint (or a SceneNode)
Defines an interface to classes which have one or more AnimableValue instances to expose...
uint32 mTypeFlag
Type flag, allocated if requested.
Listener which gets called back on MovableObject events.
A viewpoint from which the scene will be rendered.
ulong mLightListUpdated
The last frame that this light list was updated in.
virtual void objectDestroyed(MovableObject *)
MovableObject is being destroyed.
UserObjectBindings mUserObjectBindings
User objects binding.
virtual Listener * getListener(void) const
Gets the current listener for this object.
virtual uint32 getVisibilityFlags(void) const
Returns the visibility flags relevant for this object.
virtual void _notifyManager(SceneManager *man)
Notify the object of it's manager (internal use only)
This source file is part of OGRE (Object-oriented Graphics Rendering Engine) For the latest info...
EdgeData * getEdgeList(void)
Define a default implementation of method from ShadowCaster which implements no shadows.
const UserObjectBindings & getUserObjectBindings() const
Return an instance of user objects binding associated with this class.
Sphere mWorldBoundingSphere
uint32 mVisibilityFlags
Flags determining whether this object is visible (compared to SceneManager mask)
virtual void addVisibilityFlags(uint32 flags)
As setVisibilityFlags, except the flags passed as parameters are appended to the existing flags on th...
virtual bool isDebugDisplayEnabled(void) const
Gets whether debug display of this object is enabled.
virtual void objectMoved(MovableObject *)
MovableObject has been moved.
Class that provides convenient interface to establish a linkage between custom user application objec...
virtual void setListener(Listener *listener)
Sets a listener for this object.
bool mBeyondFarDistance
Hidden because of distance?
Node * mParentNode
node to which this object is attached
virtual MovableObjectFactory * _getCreator(void) const
Get the creator of this object, if any (internal use only)
uint32 mQueryFlags
Flags determining whether this object is included / excluded from scene queries.
AxisAlignedBox mWorldDarkCapBounds
World space AABB of this object's dark cap.
virtual Real getRenderingDistance(void) const
Gets the distance at which batches are no longer rendered.
LightList mLightList
List of lights for this object.
Interface definition for a factory class which produces a certain kind of MovableObject, and can be registered with Root in order to allow all clients to produce new instances of this object, integrated with the standard Ogre processing.
MovableObjectFactory * mCreator
Creator of this object (if created by a factory)
virtual LightList * _getLightList()
Returns a pointer to the current list of lights for this object.
virtual OGRE_DEPRECATED const Any & getUserAny(void) const
virtual void removeQueryFlags(uint32 flags)
As setQueryFlags, except the flags passed as parameters are removed from the existing flags on this o...
A 3D box aligned with the x/y/z axes.
Manages the organisation and rendering of a 'scene' i.e.
bool mVisible
Is this object visible?
Representation of a dynamic light source in the scene.
Superclass for all objects that wish to use custom memory allocators when their new / delete operator...
virtual void addQueryFlags(uint32 flags)
As setQueryFlags, except the flags passed as parameters are appended to the existing flags on this ob...
SceneManager * mManager
SceneManager holding this object (if applicable)
virtual bool objectRendering(const MovableObject *, const Camera *)
Called when the movable object of the camera to be used for rendering.