如何获得一个Node的bounding box算法Box

OGRE: Ogre::SceneNode Class Reference - OGRE Documentation
Ogre::SceneNode Class Reference
Class representing a node in the scene graph.
#include &&
Public Types
typedef HashMap& ,
enum & { ,
&Enumeration denoting the spaces which a transform can be relative to.
typedef HashMap& ,
Public Member Functions
& ( *creator)
&Constructor, only to be called by the creator .
& ( *creator, const
&Constructor, only to be called by the creator .
virtual void& ( *obj)
&Adds an instance of a scene object to this node.
virtual unsigned short& (void) const
&Reports the number of objects attached to this node.
*& (unsigned short index)
&Retrieves a pointer to an attached object.
&Retrieves a pointer to an attached object.
*& (unsigned short index)
&Detaches the indexed object from this scene node.
virtual void& ( *obj)
&Detaches an object by pointer.
&Detaches the named object from this node and returns a pointer to it.
virtual void& (void)
&Detaches all objects attached to this node.
virtual bool& (void) const
&Determines whether this node is in the scene graph, i.e.
virtual void& (void)
&Notifies this
that it is the root scene node.
virtual void& (bool updateChildren, bool parentHasChanged)
&Internal method to update the .
virtual void& (void)
&Tells the
to update the world bound info it stores.
virtual void& ( *cam,
*visibleBounds, bool includeChildren=true, bool displayNodes=false, bool onlyShadowCasters=false)
&Internal method which locates any visible objects attached to this node and adds them to the passed in queue.
virtual const
&& (void) const
&Gets the axis-aligned bounding box of this node (and hence all subnodes).
virtual & (void)
&Retrieves an iterator which can be used to efficiently step through the objects attached to this node.
virtual & (void) const
&Retrieves an iterator which can be used to efficiently step through the objects attached to this node.
*& (void) const
&Gets the creator of this scene node.
virtual void& (const
&This method removes and destroys the named child and all of its children.
virtual void& (unsigned short index)
&This method removes and destroys the child and all of its children.
virtual void& (void)
&Removes and destroys all children of this node.
virtual void& (bool bShow)
&Allows the showing of the node's bounding box.
virtual void& (bool bHide)
&Allows the overriding of the node's bounding box over the SceneManager's bounding box setting.
virtual void& ( *queue)
&Add the bounding box to the rendering queue.
virtual bool& () const
&This allows scene managers to determine if the node's bounding box should be added to the rendering queue.
&translate=, const
&Creates an unnamed new
as a child of this node.
&name, const
&translate=, const
&Creates a new named
as a child of this node.
virtual void& ( &destList,
lightMask=0xFFFFFFFF) const
&Allows retrieval of the nearest lights to the centre of this .
virtual void& (bool useFixed, const
&fixedAxis=)
&Tells the node whether to yaw around it's own local Y axis or a fixed axis of choice.
virtual void& (const
relativeTo=TS_LOCAL)
&Rotate the node around the Y-axis.
virtual void& ( x,
relativeTo=TS_LOCAL, const
&localDirectionVector=)
&Sets the node's direction vector ie it's local -z.
virtual void& (const
relativeTo=TS_LOCAL, const
&localDirectionVector=)
&Sets the node's direction vector ie it's local -z.
virtual void& (const
&targetPoint,
relativeTo, const
&localDirectionVector=)
&Points the local -Z direction of this node at a point in space.
virtual void& (bool enabled,
*const target=0, const
&localDirectionVector=, const
&Enables / disables automatic tracking of another .
&Get the auto tracking target for this node, if any.
virtual const
&Get the auto tracking offset for this node, if the node is auto tracking.
virtual const
&Get the auto tracking local direction for this node, if it is auto tracking.
void& (void)
&Internal method used by OGRE to update auto-tracking cameras.
*& (void) const
&Gets the parent of this .
virtual void& (bool visible, bool cascade=true)
&Makes all objects attached to this node become visible / invisible.
virtual void& (bool cascade=true)
&Inverts the visibility of all objects attached to this node.
virtual void& (bool enabled, bool cascade=true)
&Tells all objects attached to this node whether to display their debug information or not.
&As , except scaling is automatically determined.
&& (void) const
&Returns the name of the node.
*& (void) const
&Gets this node's parent (NULL if this is the root).
virtual const
&& () const
&Returns a quaternion representing the nodes orientation.
virtual void& (const
&Sets the orientation of this node via a quaternion.
virtual void& ( w,
&Sets the orientation of this node via quaternion parameters.
virtual void& (void)
&Resets the nodes orientation (local axes as world axes, no rotation).
virtual void& (const
&Sets the position of the node relative to it's parent.
virtual void& ( x,
&Sets the position of the node relative to it's parent.
virtual const
&& (void) const
&Gets the position of the node relative to it's parent.
virtual void& (const
&Sets the scaling factor applied to this node.
virtual void& ( x,
&Sets the scaling factor applied to this node.
virtual const
&& (void) const
&Gets the scaling factor of this node.
virtual void& (bool inherit)
&Tells the node whether it should inherit orientation from it's parent node.
virtual bool& (void) const
&Returns true if this node is affected by orientation applied to the parent node.
virtual void& (bool inherit)
&Tells the node whether it should inherit scaling factors from it's parent node.
virtual bool& (void) const
&Returns true if this node is affected by scaling factors applied to the parent node.
virtual void& (const
&Scales the node, combining it's current scale with the passed in scaling factor.
virtual void& ( x,
&Scales the node, combining it's current scale with the passed in scaling factor.
virtual void& (const
relativeTo=TS_PARENT)
&Moves the node along the Cartesian axes.
virtual void& ( x,
relativeTo=TS_PARENT)
&Moves the node along the Cartesian axes.
virtual void& (const
&axes, const
relativeTo=TS_PARENT)
&Moves the node along arbitrary axes.
virtual void& (const
relativeTo=TS_PARENT)
&Moves the node along arbitrary axes.
virtual void& (const
relativeTo=TS_LOCAL)
&Rotate the node around the Z-axis.
virtual void& (const
relativeTo=TS_LOCAL)
&Rotate the node around the X-axis.
virtual void& (const
&axis, const
relativeTo=TS_LOCAL)
&Rotate the node around an arbitrary axis.
virtual void& (const
relativeTo=TS_LOCAL)
&Rotate the node around an aritrary axis using a Quarternion.
virtual & (void) const
&Gets a matrix whose columns are the local axes based on the nodes orientation relative to it's parent.
&translate=, const
&Creates an unnamed new
as a child of this node.
&name, const
&translate=, const
&Creates a new named
as a child of this node.
virtual void& ( *child)
&Adds a (precreated) child scene node to this node.
virtual unsigned short& (void) const
&Reports the number of child nodes under this one.
*& (unsigned short index) const
&Gets a pointer to a child node.
&name) const
&Gets a pointer to a named child node.
virtual & (void)
&Retrieves an iterator for efficiently looping through all children of this node.
virtual & (void) const
&Retrieves an iterator for efficiently looping through all children of this node.
*& (unsigned short index)
&Drops the specified child from this node.
*& ( *child)
&Drops the specified child from this node.
&Drops the named child from this node.
virtual void& (void)
&Removes all child Nodes attached to this node.
virtual void& (const
&Sets the final world position of the node directly.
virtual void& (const
&Sets the final world orientation of the node directly.
virtual const
&& (void) const
&Gets the orientation of the node as derived from all parents.
virtual const
&& (void) const
&Gets the position of the node as derived from all parents.
virtual const
&& (void) const
&Gets the scaling factor of the node as derived from all parents.
virtual const
&& (void) const
&Gets the full transformation matrix for this node.
virtual void& ( *listener)
&Sets a listener for this .
*& (void) const
&Gets the current listener for this .
virtual void& (void)
&Sets the current transform of this node to be the 'initial state' ie that position / orientation / scale to be used as a basis for delta values used in keyframe animation.
virtual void& (void)
&Resets the position / orientation / scale of this node to it's initial state, see setInitialState for more info.
virtual const
&& (void) const
&Gets the initial position of this node, see setInitialState for more info.
virtual & (const
&worldPos)
&Gets the local position, relative to this node, of the given world-space position.
virtual & (const
&localPos)
&Gets the world position of a point in the node local space useful for simple transforms that don't require a child node.
virtual & (const
&worldOrientation)
&Gets the local orientation, relative to this node, of the given world-space orientation.
virtual & (const
&localOrientation)
&Gets the world orientation of an orientation in the node local space useful for simple transforms that don't require a child node.
virtual const
&& (void) const
&Gets the initial orientation of this node, see setInitialState for more info.
virtual const
&& (void) const
&Gets the initial position of this node, see setInitialState for more info.
virtual & (const
*cam) const
&Helper function, get the squared view depth.
virtual void& (bool forceParentUpdate=false)
&To be called in the event of transform changes to this node that require it's recalculation.
virtual void& ( *child, bool forceParentUpdate=false)
&Called by children to notify their parent that they need an update.
virtual void& ( *child)
&Called by children to notify their parent that they no longer need an update.
*& ( scaling)
&Get a debug renderable for rendering the .
virtual void& (const
&anything)
virtual const
&& (void) const
&Return an instance of user objects binding associated with this class.
&& () const
&Return an instance of user objects binding associated with this class.
void *& (size_t sz, const char *file, int line, const char *func)
&operator new, with debug line info
void *& (size_t sz)
void *& (size_t sz, void *ptr)
&placement operator new
void *& (size_t sz, const char *file, int line, const char *func)
&array operator new, with debug line info
void *& (size_t sz)
void& (void *ptr)
void& (void *ptr, void *)
void& (void *ptr, const char *, int, const char *)
void& (void *ptr)
void& (void *ptr, const char *, int, const char *)
Static Public Member Functions
static void& ( *n)
&Queue a 'needUpdate' call to a node safely.
static void& (void)
&Process queued 'needUpdate' calls.
Protected Types
* &::type&
* &::type&
Protected Member Functions
void& (void) const
void& ( *parent)
virtual void& (bool inGraph)
&Internal method for setting whether the node is in the scene graph.
virtual void& (void) const
&Triggers the node to update it's combined transforms.
Protected Attributes
&Pointer to a Wire Bounding
for this .
&Flag that determines if the bounding box of the node should be displayed.
& which created this node.
&World-Axis aligned bounding box, updated only through _update.
&Whether to yaw around a fixed axis.
&Fixed axis to yaw around.
&Auto tracking target.
&Tracking offset for fine tuning.
&Local 'normal' direction vector.
&Is this node a current part of the scene graph?
&Pointer to parent node.
&Collection of pointer hashmap for efficiency.
&List of children which need updating, used if self is not out of date but children are.
&Flag to indicate own transform from parent is out of date.
&Flag indicating that all children need to be updated.
&Flag indicating that parent has been notified about update request.
&Flag indicating that the node has been queued for update.
&Friendly name of this node, can be automatically generated if you don't care.
&Stores the orientation of the node relative to it's parent.
&Stores the position/translation of the node relative to its parent.
&Stores the scaling factor applied to this node.
&Stores whether this node inherits orientation from it's parent.
&Stores whether this node inherits scale from it's parent.
&Cached combined orientation.
&Cached combined position.
&Cached combined scale.
&The position to use as a base for keyframe animation.
&The orientation to use as a base for keyframe animation.
&The scale to use as a base for keyframe animation.
&Cached derived transform as a 4x4 matrix.
& listener - only one allowed (no list) for size & performance reasons.
&User objects binding.
Static Protected Attributes
&Incremented count for next name extension.
Detailed Description
Class representing a node in the scene graph.
is a type of
which is used to organise objects in a scene. It has the same hierarchical transformation properties of the generic
class, but also adds the ability to attach world objects to the node, and stores hierarchical bounding volumes of the nodes in the tree. Child nodes are contained within the bounds of the parent, and so on down the tree, allowing for fast culling.
Definition at line
Member Typedef Documentation
typedef &&
[inherited]
Definition at line
typedef HashMap&, *&
[inherited]
Definition at line
typedef &*&::type
[protected, inherited]
Definition at line
typedef &&
[inherited]
Definition at line
typedef &&
Definition at line
typedef &&
Definition at line
typedef HashMap&, *&
Definition at line
typedef &*&::type
[protected, inherited]
Definition at line
Member Enumeration Documentation
[inherited]
Enumeration denoting the spaces which a transform can be relative to.
Enumerator:
Transform is relative to the local space.
TS_PARENT&
Transform is relative to the space of the parent node.
Transform is relative to world space.
Definition at line
Constructor & Destructor Documentation
Ogre::SceneNode::SceneNode
Constructor, only to be called by the creator .
Remarks:Creates a node with a generated name.
Ogre::SceneNode::SceneNode
Constructor, only to be called by the creator .
Remarks:Creates a node with a specified name.
Ogre::SceneNode::~SceneNode
Member Function Documentation
virtual void Ogre::SceneNode::_addBoundingBoxToQueue
Add the bounding box to the rendering queue.
void Ogre::SceneNode::_autoTrack
Internal method used by OGRE to update auto-tracking cameras.
virtual void Ogre::SceneNode::_findVisibleObjects
visibleBounds,
includeChildren = true,
displayNodes = false,
onlyShadowCasters = false&
Internal method which locates any visible objects attached to this node and adds them to the passed in queue.
Remarks:Should only be called by a
implementation, and only after the _updat method has been called to ensure transforms and world bounds are up to date.
implementations can choose to let the search cascade automatically, or choose to prevent this and select nodes themselves based on some other criteria.
Parameters:
cam&The active camera
queue&The SceneManager's rendering queue
visibleBounds&bounding information created on the fly containing all visible objects by the camera
includeChildren&If true, the call is cascaded down to all child nodes automatically.
displayNodes&If true, the nodes themselves are rendered as a set of 3 axes as well as the objects being rendered. For debugging purposes.
virtual const & Ogre::Node::_getDerivedOrientation
const [virtual, inherited]
Gets the orientation of the node as derived from all parents.
virtual const & Ogre::Node::_getDerivedPosition
const [virtual, inherited]
Gets the position of the node as derived from all parents.
virtual const & Ogre::Node::_getDerivedScale
const [virtual, inherited]
Gets the scaling factor of the node as derived from all parents.
virtual const & Ogre::Node::_getFullTransform
const [virtual, inherited]
Gets the full transformation matrix for this node.
Remarks:This method returns the full transformation matrix for this node, including the effect of any parent node transformations, provided they have been updated using the
method. This should only be called by a
which knows the derived transforms have been updated before calling this method. Applications using
should just use the relative transforms.
virtual const & Ogre::SceneNode::_getWorldAABB
const [virtual]
Gets the axis-aligned bounding box of this node (and hence all subnodes).
Remarks:Recommended only if you are extending a , because the bounding box returned from this method is only up to date after the
has called _update.
virtual void Ogre::SceneNode::_notifyRootNode
Notifies this
that it is the root scene node.
Remarks:Only
should call this!
Definition at line
virtual void Ogre::Node::_setDerivedOrientation
[virtual, inherited]
Sets the final world orientation of the node directly.
Remarks:It's advisable to use the local setOrientation if possible, this simply does the conversion for you.
virtual void Ogre::Node::_setDerivedPosition
[virtual, inherited]
Sets the final world position of the node directly.
Remarks:It's advisable to use the local setPosition if possible
virtual void Ogre::SceneNode::_update
updateChildren,
parentHasChanged&
Internal method to update the .
Note:Updates this scene node and any relevant children to incorporate transforms etc. Don't call this yourself unless you are writing a
implementation.
Parameters:
updateChildren&If true, the update cascades down to all children. Specify false if you wish to update children separately, e.g. because of a more selective
implementation.
parentHasChanged&This flag indicates that the parent transform has changed, so the child should retrieve the parent's transform and combine it with its own even if it hasn't changed itself.
Reimplemented from .
virtual void Ogre::SceneNode::_updateBounds
to update the world bound info it stores.
virtual void Ogre::Node::_updateFromParent
const [protected, virtual, inherited]
Triggers the node to update it's combined transforms.
This method is called internally by
to ask the node to update it's complete transformation based on it's parents derived transform.
virtual void Ogre::Node::addChild
[virtual, inherited]
Adds a (precreated) child scene node to this node.
If it is attached to another node, it must be detached first.
Parameters:
which is to become a child node of this one
virtual void Ogre::SceneNode::attachObject
Adds an instance of a scene object to this node.
Remarks:Scene objects can include
objects etc. Anything that subclasses from .
virtual void Ogre::Node::cancelUpdate
[virtual, inherited]
Called by children to notify their parent that they no longer need an update.
Ogre::Node::convertLocalToWorldOrientation
localOrientation
[virtual, inherited]
Gets the world orientation of an orientation in the node local space useful for simple transforms that don't require a child node.
Ogre::Node::convertLocalToWorldPosition
[virtual, inherited]
Gets the world position of a point in the node local space useful for simple transforms that don't require a child node.
Ogre::Node::convertWorldToLocalOrientation
worldOrientation
[virtual, inherited]
Gets the local orientation, relative to this node, of the given world-space orientation.
Ogre::Node::convertWorldToLocalPosition
[virtual, inherited]
Gets the local position, relative to this node, of the given world-space position.
virtual * Ogre::Node::createChild
translate = ,
rotate = &
[virtual, inherited]
Creates a new named
as a child of this node.
Remarks:This creates a child node with a given name, which allows you to look the node up from the parent which holds this collection of nodes.
Parameters:
translate&Initial translation offset of child relative to parent
rotate&Initial rotation relative to parent
virtual * Ogre::Node::createChild
translate = ,
rotate = &
[virtual, inherited]
Creates an unnamed new
as a child of this node.
Parameters:
translate&Initial translation offset of child relative to parent
rotate&Initial rotation relative to parent
* Ogre::SceneNode::createChildImpl
[protected, virtual]
Implements .
* Ogre::SceneNode::createChildImpl
[protected, virtual]
Implements .
virtual * Ogre::SceneNode::createChildSceneNode
translate = ,
rotate = &
Creates a new named
as a child of this node.
Remarks:This creates a child node with a given name, which allows you to look the node up from the parent which holds this collection of nodes.
Parameters:
translate&Initial translation offset of child relative to parent
rotate&Initial rotation relative to parent
virtual * Ogre::SceneNode::createChildSceneNode
translate = ,
rotate = &
Creates an unnamed new
as a child of this node.
Parameters:
translate&Initial translation offset of child relative to parent
rotate&Initial rotation relative to parent
virtual void Ogre::SceneNode::detachAllObjects
Detaches all objects attached to this node.
virtual * Ogre::SceneNode::detachObject
Detaches the named object from this node and returns a pointer to it.
virtual void Ogre::SceneNode::detachObject
Detaches an object by pointer.
virtual * Ogre::SceneNode::detachObject
unsigned short&
Detaches the indexed object from this scene node.
Remarks:Detaches by index, see the alternate version to detach by name. Object indexes may change as other objects are added / removed.
virtual void Ogre::SceneNode::findLights
lightMask = 0xFFFFFFFF&
const [virtual]
Allows retrieval of the nearest lights to the centre of this .
Remarks:This method allows a list of lights, ordered by proximity to the centre of this , to be retrieved. Can be useful when implementing
Note that only lights could be affecting the frustum will take into account, which cached in scene manager.
Parameters:
destList&List to be populated with o will be cleared by this method before population.
radius&Parameter to specify lights intersecting a given radius of this SceneNode's centre.
lightMask&The mask with which to include / exclude lights
virtual void Ogre::SceneNode::flipVisibility
cascade = true
Inverts the visibility of all objects attached to this node.
Remarks:This is a shortcut to calling setVisible(!isVisible()) on the objects attached to this node, and optionally to all objects attached to child nodes.
Parameters:
cascade&If true, this setting cascades into child nodes too.
virtual * Ogre::SceneNode::getAttachedObject
Retrieves a pointer to an attached object.
Remarks:Retrieves by object name, see alternate version to retrieve by index.
virtual * Ogre::SceneNode::getAttachedObject
unsigned short&
Retrieves a pointer to an attached object.
Remarks:Retrieves by index, see alternate version to retrieve by name. The index of an object may change as other objects are added / removed.
Ogre::SceneNode::getAttachedObjectIterator
const [virtual]
Retrieves an iterator which can be used to efficiently step through the objects attached to this node.
Remarks:This is a much faster way to go through all the objects attached to the node than using getAttachedObject. But the iterator returned is only valid until a change is made to the collection (ie an addition or removal) so treat the returned iterator as transient, and don't add / remove items as you go through the iterator, save changes until the end, or retrieve a new iterator after making the change. Making changes to the object returned through the iterator is OK though.
Ogre::SceneNode::getAttachedObjectIterator
Retrieves an iterator which can be used to efficiently step through the objects attached to this node.
Remarks:This is a much faster way to go through all the objects attached to the node than using getAttachedObject. But the iterator returned is only valid until a change is made to the collection (ie an addition or removal) so treat the returned iterator as transient, and don't add / remove items as you go through the iterator, save changes until the end, or retrieve a new iterator after making the change. Making changes to the object returned through the iterator is OK though.
virtual const & Ogre::SceneNode::getAutoTrackLocalDirection
Get the auto tracking local direction for this node, if it is auto tracking.
Definition at line
virtual const & Ogre::SceneNode::getAutoTrackOffset
Get the auto tracking offset for this node, if the node is auto tracking.
Definition at line
virtual * Ogre::SceneNode::getAutoTrackTarget
Get the auto tracking target for this node, if any.
Definition at line
virtual * Ogre::Node::getChild
const [virtual, inherited]
Gets a pointer to a named child node.
virtual * Ogre::Node::getChild
unsigned short&
const [virtual, inherited]
Gets a pointer to a child node.
Remarks:There is an alternate getChild method which returns a named child.
Ogre::Node::getChildIterator
const [virtual, inherited]
Retrieves an iterator for efficiently looping through all children of this node.
Remarks:Using this is faster than repeatedly calling getChild if you want to go through all (or most of) the children of this node. Note that the returned iterator is only valid whilst no children are added or removed from this node. Thus you should not store this returned iterator for later use, nor should you add / remove children whilst
store up changes for later. Note that calling methods on returned items in the iterator IS allowed and does not invalidate the iterator.
Ogre::Node::getChildIterator
[virtual, inherited]
Retrieves an iterator for efficiently looping through all children of this node.
Remarks:Using this is faster than repeatedly calling getChild if you want to go through all (or most of) the children of this node. Note that the returned iterator is only valid whilst no children are added or removed from this node. Thus you should not store this returned iterator for later use, nor should you add / remove children whilst
store up changes for later. Note that calling methods on returned items in the iterator IS allowed and does not invalidate the iterator.
* Ogre::SceneNode::getCreator
Gets the creator of this scene node.
Remarks:This method returns the
which created this node. This can be useful for destroying this node.
Definition at line
virtual * Ogre::Node::getDebugRenderable
[virtual, inherited]
Get a debug renderable for rendering the .
virtual * Ogre::SceneNode::getDebugRenderable
As , except scaling is automatically determined.
virtual bool Ogre::Node::getInheritOrientation
const [virtual, inherited]
Returns true if this node is affected by orientation applied to the parent node.
Remarks:Orientations, unlike other transforms, are not always inherited by child nodes. Whether or not orientations affect the orientation of the child nodes depends on the setInheritOrientation option of the child. In some cases you want a orientating of a parent node to apply to a child node (e.g. where the child node is a part of the same object, so you want it to be the same relative orientation based on the parent's orientation), but not in other cases (e.g. where the child node is just for positioning another object, you want it to maintain it's own orientation). The default is to inherit as with other transforms.
See setInheritOrientation for more info.
virtual bool Ogre::Node::getInheritScale
const [virtual, inherited]
Returns true if this node is affected by scaling factors applied to the parent node.
Remarks:See setInheritScale for more info.
virtual const & Ogre::Node::getInitialOrientation
const [virtual, inherited]
Gets the initial orientation of this node, see setInitialState for more info.
virtual const & Ogre::Node::getInitialPosition
const [virtual, inherited]
Gets the initial position of this node, see setInitialState for more info.
Remarks:Also resets the cumulative animation weight used for blending.
virtual const & Ogre::Node::getInitialScale
const [virtual, inherited]
Gets the initial position of this node, see setInitialState for more info.
virtual * Ogre::Node::getListener
const [virtual, inherited]
Gets the current listener for this .
Definition at line
Ogre::Node::getLocalAxes
const [virtual, inherited]
Gets a matrix whose columns are the local axes based on the nodes orientation relative to it's parent.
const & Ogre::Node::getName
const [inherited]
Returns the name of the node.
virtual const & Ogre::Node::getOrientation
const [virtual, inherited]
Returns a quaternion representing the nodes orientation.
virtual * Ogre::Node::getParent
const [virtual, inherited]
Gets this node's parent (NULL if this is the root).
* Ogre::SceneNode::getParentSceneNode
Gets the parent of this .
virtual const & Ogre::Node::getPosition
const [virtual, inherited]
Gets the position of the node relative to it's parent.
virtual const & Ogre::Node::getScale
const [virtual, inherited]
Gets the scaling factor of this node.
virtual bool Ogre::SceneNode::getShowBoundingBox
const [virtual]
This allows scene managers to determine if the node's bounding box should be added to the rendering queue.
Remarks:Scene Managers that implement their own _findVisibleObjects will have to check this flag and then use _addBoundingBoxToQueue to add the bounding box wireframe.
Ogre::Node::getSquaredViewDepth
const [virtual, inherited]
Helper function, get the squared view depth.
virtual const & Ogre::Node::getUserAny
const [virtual, inherited]
instead. Retrieves the custom user value associated with this object.
Definition at line
const & Ogre::Node::getUserObjectBindings
const [inherited]
Return an instance of user objects binding associated with this class.
You can use it to associate one or more custom objects with this class instance.
See also:.
Definition at line
& Ogre::Node::getUserObjectBindings
[inherited]
Return an instance of user objects binding associated with this class.
You can use it to associate one or more custom objects with this class instance.
See also:.
Definition at line
virtual void Ogre::SceneNode::hideBoundingBox
Allows the overriding of the node's bounding box over the SceneManager's bounding box setting.
Remarks:Use this to override the bounding box setting of the node.
virtual bool Ogre::SceneNode::isInSceneGraph
const [virtual]
Determines whether this node is in the scene graph, i.e.
whether it's ultimate ancestor is the root scene node.
Definition at line
virtual void Ogre::SceneNode::lookAt
targetPoint,
relativeTo,
localDirectionVector = &
Points the local -Z direction of this node at a point in space.
Parameters:
targetPoint&A vector specifying the look at point.
relativeTo&The space in which the point resides
localDirectionVector&The vector which normally describes the natural direction of the node, usually -Z
virtual void Ogre::Node::needUpdate
forceParentUpdate = false
[virtual, inherited]
To be called in the event of transform changes to this node that require it's recalculation.
Remarks:This not only tags the node state as being 'dirty', it also requests it's parent to know about it's dirtiness so it will get an update next time.
Parameters:
forceParentUpdate&Even if the node thinks it has already told it's parent, tell it anyway
Reimplemented in , and .
virtual unsigned short Ogre::SceneNode::numAttachedObjects
const [virtual]
Reports the number of objects attached to this node.
virtual unsigned short Ogre::Node::numChildren
const [virtual, inherited]
Reports the number of child nodes under this one.
template&class Alloc &
void & Alloc &::operator delete
const char *&
const char *&
[inherited]
Definition at line
template&class Alloc &
void & Alloc &::operator delete
[inherited]
Definition at line
template&class Alloc &
void & Alloc &::operator delete
[inherited]
Definition at line
template&class Alloc &
void & Alloc &::operator delete[]
const char *&
const char *&
[inherited]
Definition at line
template&class Alloc &
void & Alloc &::operator delete[]
[inherited]
Definition at line
template&class Alloc &
void* & Alloc &::operator new
[inherited]
placement operator new
Definition at line
template&class Alloc &
void* & Alloc &::operator new
[inherited]
Definition at line
template&class Alloc &
void* & Alloc &::operator new
const char *&
const char *&
[inherited]
operator new, with debug line info
Definition at line
template&class Alloc &
void* & Alloc &::operator new[]
[inherited]
Definition at line
template&class Alloc &
void* & Alloc &::operator new[]
const char *&
const char *&
[inherited]
array operator new, with debug line info
Definition at line
virtual void Ogre::Node::pitch
relativeTo = TS_LOCAL&
[virtual, inherited]
Rotate the node around the X-axis.
static void Ogre::Node::processQueuedUpdates
[static, inherited]
Process queued 'needUpdate' calls.
static void Ogre::Node::queueNeedUpdate
[static, inherited]
Queue a 'needUpdate' call to a node safely.
Remarks:You can't call
during the scene graph update, e.g. in response to a
hook, because the graph is already being updated, and update flag changes cannot be made reliably in that context. Call this method if you need to queue a needUpdate call in this case.
virtual void Ogre::Node::removeAllChildren
[virtual, inherited]
Removes all child Nodes attached to this node.
Does not delete the nodes, just detaches them from this parent, potentially to be reattached elsewhere.
virtual void Ogre::SceneNode::removeAndDestroyAllChildren
Removes and destroys all children of this node.
Remarks:Use this to destroy all child nodes of this node and remove them from the scene graph. Note that all objects attached to this node will be detached but will not be destroyed.
virtual void Ogre::SceneNode::removeAndDestroyChild
unsigned short&
This method removes and destroys the child and all of its children.
Remarks:Unlike removeChild, which removes a single named child from this node but does not destroy it, this method destroys the child and all of it's children.
Use this if you wish to recursively destroy a node as well as detaching it from it's parent. Note that any objects attached to the nodes will be detached but will not themselves be destroyed.
virtual void Ogre::SceneNode::removeAndDestroyChild
This method removes and destroys the named child and all of its children.
Remarks:Unlike removeChild, which removes a single named child from this node but does not destroy it, this method destroys the child and all of it's children.
Use this if you wish to recursively destroy a node as well as detaching it from it's parent. Note that any objects attached to the nodes will be detached but will not themselves be destroyed.
virtual * Ogre::Node::removeChild
[virtual, inherited]
Drops the named child from this node.
Remarks:Does not delete the node, just detaches it from this parent, potentially to be reattached elsewhere.
virtual * Ogre::Node::removeChild
[virtual, inherited]
Drops the specified child from this node.
Remarks:Does not delete the node, just detaches it from this parent, potentially to be reattached elsewhere. There is also an alternate version which drops a named child from this node.
virtual * Ogre::Node::removeChild
unsigned short&
[virtual, inherited]
Drops the specified child from this node.
Remarks:Does not delete the node, just detaches it from this parent, potentially to be reattached elsewhere. There is also an alternate version which drops a named child from this node.
virtual void Ogre::Node::requestUpdate
forceParentUpdate = false&
[virtual, inherited]
Called by children to notify their parent that they need an update.
Parameters:
forceParentUpdate&Even if the node thinks it has already told it's parent, tell it anyway
virtual void Ogre::Node::resetOrientation
[virtual, inherited]
Resets the nodes orientation (local axes as world axes, no rotation).
Remarks:Orientations, unlike other transforms, are not always inherited by child nodes. Whether or not orientations affect the orientation of the child nodes depends on the setInheritOrientation option of the child. In some cases you want a orientating of a parent node to apply to a child node (e.g. where the child node is a part of the same object, so you want it to be the same relative orientation based on the parent's orientation), but not in other cases (e.g. where the child node is just for positioning another object, you want it to maintain it's own orientation). The default is to inherit as with other transforms.
Note that rotations are oriented around the node's origin.
virtual void Ogre::Node::resetToInitialState
[virtual, inherited]
Resets the position / orientation / scale of this node to it's initial state, see setInitialState for more info.
virtual void Ogre::Node::roll
relativeTo = TS_LOCAL&
[virtual, inherited]
Rotate the node around the Z-axis.
virtual void Ogre::Node::rotate
relativeTo = TS_LOCAL&
[virtual, inherited]
Rotate the node around an aritrary axis using a Quarternion.
virtual void Ogre::Node::rotate
relativeTo = TS_LOCAL&
[virtual, inherited]
Rotate the node around an arbitrary axis.
virtual void Ogre::Node::scale
[virtual, inherited]
Scales the node, combining it's current scale with the passed in scaling factor.
Remarks:This method applies an extra scaling factor to the node's existing scale, (unlike setScale which overwrites it) combining it's current scale with the new one. E.g. calling this method twice with Vector3(2,2,2) would have the same effect as setScale(Vector3(4,4,4)) if the existing scale was 1.
Note that like rotations, scalings are oriented around the node's origin.
virtual void Ogre::Node::scale
[virtual, inherited]
Scales the node, combining it's current scale with the passed in scaling factor.
Remarks:This method applies an extra scaling factor to the node's existing scale, (unlike setScale which overwrites it) combining it's current scale with the new one. E.g. calling this method twice with Vector3(2,2,2) would have the same effect as setScale(Vector3(4,4,4)) if the existing scale was 1.
Note that like rotations, scalings are oriented around the node's origin.
virtual void Ogre::SceneNode::setAutoTracking
target = 0,
localDirectionVector = ,
offset = &
Enables / disables automatic tracking of another .
Remarks:If you enable auto-tracking, this
will automatically rotate to point it's -Z at the target
every frame, no matter how it or the other
move. Note that by default the -Z points at the origin of the target , if you want to tweak this, provide a vector in the 'offset' parameter and the target point will be adjusted.
Parameters:
enabled&If true, tracking will be enabled and the next parameter cannot be null. If false tracking will be disabled and the current orientation will be maintained.
target&Pointer to the
to track. Make sure you don't delete this
before turning off tracking (e.g.
will delete it so be careful of this). Can be null if and only if the enabled param is false.
localDirectionVector&The local vector considered to be the usual 'direction' normally the local -Z but can be another direction.
offset&If supplied, this is the target point in local space of the target node instead of the origin of the target node. Good for fine tuning the look at point.
virtual void Ogre::SceneNode::setDebugDisplayEnabled
cascade = true&
Tells all objects attached to this node whether to display their debug information or not.
Remarks:This is a shortcut to calling
on the objects attached to this node, and optionally to all objects attached to child nodes.
Parameters:
enabled&Whether the objects are to display debug info or not
cascade&If true, this setting cascades into child nodes too.
virtual void Ogre::SceneNode::setDirection
relativeTo = TS_LOCAL,
localDirectionVector = &
Sets the node's direction vector ie it's local -z.
Remarks:Note that the 'up' vector for the orientation will automatically be recalculated based on the current 'up' vector (i.e. the roll will remain the same). If you need more control, use setOrientation.
Parameters:
vec&The direction vector
relativeTo&The space in which this direction vector is expressed
localDirectionVector&The vector which normally describes the natural direction of the node, usually -Z
virtual void Ogre::SceneNode::setDirection
relativeTo = TS_LOCAL,
localDirectionVector = &
Sets the node's direction vector ie it's local -z.
Remarks:Note that the 'up' vector for the orientation will automatically be recalculated based on the current 'up' vector (i.e. the roll will remain the same). If you need more control, use setOrientation.
Parameters:
x,y,z&The components of the direction vector
relativeTo&The space in which this direction vector is expressed
localDirectionVector&The vector which normally describes the natural direction of the node, usually -Z
virtual void Ogre::SceneNode::setFixedYawAxis
fixedAxis = &
Tells the node whether to yaw around it's own local Y axis or a fixed axis of choice.
Remarks:This method allows you to change the yaw behaviour of the node - by default, it yaws around it's own local Y axis when told to yaw with TS_LOCAL, this makes it yaw around a fixed axis. You only really need this when you're using auto tracking (see setAutoTracking, because when you're manually rotating a node you can specify the TransformSpace in which you wish to work anyway.
Parameters:
useFixed&If true, the axis passed in the second parameter will always be the yaw axis no matter what the node orientation. If false, the node returns to it's default behaviour.
fixedAxis&The axis to use if the first parameter is true.
virtual void Ogre::Node::setInheritOrientation
[virtual, inherited]
Tells the node whether it should inherit orientation from it's parent node.
Remarks:Orientations, unlike other transforms, are not always inherited by child nodes. Whether or not orientations affect the orientation of the child nodes depends on the setInheritOrientation option of the child. In some cases you want a orientating of a parent node to apply to a child node (e.g. where the child node is a part of the same object, so you want it to be the same relative orientation based on the parent's orientation), but not in other cases (e.g. where the child node is just for positioning another object, you want it to maintain it's own orientation). The default is to inherit as with other transforms.
Parameters:
inherit&If true, this node's orientation will be affected by its parent's orientation. If false, it will not be affected.
virtual void Ogre::Node::setInheritScale
[virtual, inherited]
Tells the node whether it should inherit scaling factors from it's parent node.
Remarks:Scaling factors, unlike other transforms, are not always inherited by child nodes. Whether or not scalings affect the size of the child nodes depends on the setInheritScale option of the child. In some cases you want a scaling factor of a parent node to apply to a child node (e.g. where the child node is a part of the same object, so you want it to be the same relative size based on the parent's size), but not in other cases (e.g. where the child node is just for positioning another object, you want it to maintain it's own size). The default is to inherit as with other transforms.
Parameters:
inherit&If true, this node's scale will be affected by its parent's scale. If false, it will not be affected.
virtual void Ogre::Node::setInitialState
[virtual, inherited]
Sets the current transform of this node to be the 'initial state' ie that position / orientation / scale to be used as a basis for delta values used in keyframe animation.
Remarks:You never need to call this method unless you plan to animate this node. If you do plan to animate it, call this method once you've loaded the node with it's base state, ie the state on which all keyframes are based.
If you never call this method, the initial state is the identity transform, ie do nothing.
virtual void Ogre::SceneNode::setInSceneGraph
[protected, virtual]
Internal method for setting whether the node is in the scene graph.
virtual void Ogre::Node::setListener
[virtual, inherited]
Sets a listener for this .
Remarks:Note for size and performance reasons only one listener per node is allowed.
Definition at line
virtual void Ogre::Node::setOrientation
[virtual, inherited]
Sets the orientation of this node via quaternion parameters.
Remarks:Orientations, unlike other transforms, are not always inherited by child nodes. Whether or not orientations affect the orientation of the child nodes depends on the setInheritOrientation option of the child. In some cases you want a orientating of a parent node to apply to a child node (e.g. where the child node is a part of the same object, so you want it to be the same relative orientation based on the parent's orientation), but not in other cases (e.g. where the child node is just for positioning another object, you want it to maintain it's own orientation). The default is to inherit as with other transforms.
Note that rotations are oriented around the node's origin.
virtual void Ogre::Node::setOrientation
[virtual, inherited]
Sets the orientation of this node via a quaternion.
Remarks:Orientations, unlike other transforms, are not always inherited by child nodes. Whether or not orientations affect the orientation of the child nodes depends on the setInheritOrientation option of the child. In some cases you want a orientating of a parent node to apply to a child node (e.g. where the child node is a part of the same object, so you want it to be the same relative orientation based on the parent's orientation), but not in other cases (e.g. where the child node is just for positioning another object, you want it to maintain it's own orientation). The default is to inherit as with other transforms.
Note that rotations are oriented around the node's origin.
void Ogre::SceneNode::setParent
[protected, virtual]
Reimplemented from .
virtual void Ogre::Node::setPosition
[virtual, inherited]
Sets the position of the node relative to it's parent.
virtual void Ogre::Node::setPosition
[virtual, inherited]
Sets the position of the node relative to it's parent.
virtual void Ogre::Node::setScale
[virtual, inherited]
Sets the scaling factor applied to this node.
Remarks:Scaling factors, unlike other transforms, are not always inherited by child nodes. Whether or not scalings affect the size of the child nodes depends on the setInheritScale option of the child. In some cases you want a scaling factor of a parent node to apply to a child node (e.g. where the child node is a part of the same object, so you want it to be the same relative size based on the parent's size), but not in other cases (e.g. where the child node is just for positioning another object, you want it to maintain it's own size). The default is to inherit as with other transforms.
Note that like rotations, scalings are oriented around the node's origin.
virtual void Ogre::Node::setScale
[virtual, inherited]
Sets the scaling factor applied to this node.
Remarks:Scaling factors, unlike other transforms, are not always inherited by child nodes. Whether or not scalings affect the size of the child nodes depends on the setInheritScale option of the child. In some cases you want a scaling factor of a parent node to apply to a child node (e.g. where the child node is a part of the same object, so you want it to be the same relative size based on the parent's size), but not in other cases (e.g. where the child node is just for positioning another object, you want it to maintain it's own size). The default is to inherit as with other transforms.
Note that like rotations, scalings are oriented around the node's origin.
virtual void Ogre::Node::setUserAny
[virtual, inherited]
instead. Sets any kind of user value on this object.
Remarks:This method allows you to associate any user value you like with this . This can be a pointer back to one of your own classes for instance.
Definition at line
virtual void Ogre::SceneNode::setVisible
cascade = true&
Makes all objects attached to this node become visible / invisible.
Remarks:This is a shortcut to calling
on the objects attached to this node, and optionally to all objects attached to child nodes.
Parameters:
visible&Whether the objects are to be made visible or invisible
cascade&If true, this setting cascades into child nodes too.
virtual void Ogre::SceneNode::showBoundingBox
Allows the showing of the node's bounding box.
Remarks:Use this to show or hide the bounding box of the node.
virtual void Ogre::Node::translate
relativeTo = TS_PARENT&
[virtual, inherited]
Moves the node along arbitrary axes.
Remarks:This method translates the node by a vector which is relative to a custom set of axes.
Parameters:
axes&A 3x3 Matrix containg 3 column vectors each representing the axes X, Y and Z respectively. In this format the standard cartesian axes would be expressed as
i.e. the identity matrix.
x,y,z&Translation components relative to the axes above.
relativeTo&The space which this transform is relative to.
virtual void Ogre::Node::translate
relativeTo = TS_PARENT&
[virtual, inherited]
Moves the node along arbitrary axes.
Remarks:This method translates the node by a vector which is relative to a custom set of axes.
Parameters:
axes&A 3x3 Matrix containg 3 column vectors each representing the axes X, Y and Z respectively. In this format the standard cartesian axes would be expressed as:
i.e. the identity matrix.
move&Vector relative to the axes above.
relativeTo&The space which this transform is relative to.
virtual void Ogre::Node::translate
relativeTo = TS_PARENT&
[virtual, inherited]
Moves the node along the Cartesian axes.
This method moves the node by the supplied vector along the world Cartesian axes, i.e. along world x,y,z
Parameters:
z&Real x, y and z values representing the translation.
relativeTo&The space which this transform is relative to.
virtual void Ogre::Node::translate
relativeTo = TS_PARENT&
[virtual, inherited]
Moves the node along the Cartesian axes.
This method moves the node by the supplied vector along the world Cartesian axes, i.e. along world x,y,z
Parameters:
d&Vector with x,y,z values representing the translation.
relativeTo&The space which this transform is relative to.
void Ogre::SceneNode::updateFromParentImpl
const [protected, virtual]
Class-specific implementation of _updateFromParent. Remarks:Splitting the implementation of the update away from the update call itself allows the detail to be overridden without disrupting the general sequence of updateFromParent (e.g. raising events)
Reimplemented from .
virtual void Ogre::SceneNode::yaw
relativeTo = TS_LOCAL&
Rotate the node around the Y-axis.
Reimplemented from .
Member Data Documentation
[protected]
Local 'normal' direction vector.
Definition at line
[protected]
Tracking offset for fine tuning.
Definition at line
[protected]
Auto tracking target.
Definition at line
[mutable, protected, inherited]
Cached derived transform as a 4x4 matrix.
Definition at line
[mutable, protected, inherited]
Definition at line
[protected, inherited]
Collection of pointer hashmap for efficiency.
Definition at line
[mutable, protected, inherited]
List of children which need updating, used if self is not out of date but children are.
Definition at line
[protected]
which created this node.
Definition at line
[protected, inherited]
Definition at line
[mutable, protected, inherited]
Cached combined orientation.
This member is the orientation derived by combining the local transformations and those of it's parents. This is updated when _updateFromParent is called by the
or the nodes parent.
Definition at line
[mutable, protected, inherited]
Cached combined position.
This member is the position derived by combining the local transformations and those of it's parents. This is updated when _updateFromParent is called by the
or the nodes parent.
Definition at line
[mutable, protected, inherited]
Cached combined scale.
This member is the position derived by combining the local transformations and those of it's parents. This is updated when _updateFromParent is called by the
or the nodes parent.
Definition at line
[protected]
Definition at line
[protected, inherited]
Stores whether this node inherits orientation from it's parent.
Definition at line
[protected, inherited]
Stores whether this node inherits scale from it's parent.
Definition at line
[protected, inherited]
The orientation to use as a base for keyframe animation.
Definition at line
[protected, inherited]
The position to use as a base for keyframe animation.
Definition at line
[protected, inherited]
The scale to use as a base for keyframe animation.
Definition at line
[protected]
Is this node a current part of the scene graph?
Definition at line
[protected, inherited]
listener - only one allowed (no list) for size & performance reasons.
Definition at line
[protected, inherited]
Friendly name of this node, can be automatically generated if you don't care.
Definition at line
[mutable, protected, inherited]
Flag indicating that all children need to be updated.
Definition at line
[mutable, protected, inherited]
Flag to indicate own transform from parent is out of date.
Definition at line
[protected]
Definition at line
[protected, inherited]
Stores the orientation of the node relative to it's parent.
Definition at line
[protected, inherited]
Pointer to parent node.
Definition at line
[mutable, protected, inherited]
Flag indicating that parent has been notified about update request.
Definition at line
[protected, inherited]
Stores the position/translation of the node relative to its parent.
Definition at line
[mutable, protected, inherited]
Flag indicating that the node has been queued for update.
Definition at line
[protected, inherited]
Stores the scaling factor applied to this node.
Definition at line
[protected]
Flag that determines if the bounding box of the node should be displayed.
Definition at line
[static, protected, inherited]
Incremented count for next name extension.
Definition at line
[static, protected, inherited]
Definition at line
[protected, inherited]
User objects binding.
Definition at line
[protected]
Pointer to a Wire Bounding
for this .
Definition at line
[protected]
World-Axis aligned bounding box, updated only through _update.
Definition at line
[protected]
Whether to yaw around a fixed axis.
Definition at line
[protected]
Fixed axis to yaw around.
Definition at line
The documentation for this class was generated from the following file:
Copyright & 2012 Torus Knot Software Ltd
This work is licensed under a .
Last modified Fri May 25 23:39:57 2012

我要回帖

更多关于 opencv bounding box 的文章

 

随机推荐