Sophie

Sophie

distrib > Mandriva > 2010.1 > x86_64 > media > contrib-release > by-pkgid > 58828b263d8f56d90ac336dea07a4586 > files > 635

irrlicht-doc-1.6.1-1mdv2010.1.x86_64.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>Irrlicht Engine: irr::scene::ISceneCollisionManager Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<table class="irrlicht" >
  <tr valign="middle"> 
    <td><font size="2"><a class="qindex" href="index.html"><font color="#FFFFFF">Home</font></a> 
      | <a class="qindex" href="namespaces.html"><font color="#FFFFFF">Namespaces</font></a> 
      | <a class="qindex" href="hierarchy.html"><font color="#FFFFFF">Hierarchy</font></a> 
      | <a class="qindex" href="classes.html"><font color="#FFFFFF">Alphabetical 
      List</font></a> | <a class="qindex" href="annotated.html"><font color="#FFFFFF"> 
      Class list</font></a> | <a class="qindex" href="files.html"><font color="#FFFFFF">Files</font></a> 
      | <a class="qindex" href="namespacemembers.html"><font color="#FFFFFF"> 
      Namespace&nbsp;Members</font></a> | <a class="qindex" href="functions.html"><font color="#FFFFFF">Class 
      members</font></a> | <a class="qindex" href="globals.html"><font color="#FFFFFF">File 
      members</font></a> | <a class="qindex" href="pages.html"><font color="#FFFFFF">Tutorials</font></a></font> </td>
  </tr>
</table>
<!-- Generated by Doxygen 1.5.6 -->
  <div class="navpath"><a class="el" href="namespaceirr.html">irr</a>::<a class="el" href="namespaceirr_1_1scene.html">scene</a>::<a class="el" href="classirr_1_1scene_1_1_i_scene_collision_manager.html">ISceneCollisionManager</a>
  </div>
<div class="contents">
<h1>irr::scene::ISceneCollisionManager Class Reference</h1><!-- doxytag: class="irr::scene::ISceneCollisionManager" --><!-- doxytag: inherits="irr::IReferenceCounted" -->The Scene Collision Manager provides methods for performing collision tests and picking on <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes.  
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="_i_scene_collision_manager_8h-source.html">ISceneCollisionManager.h</a>&gt;</code>
<p>
<div class="dynheader">
Inheritance diagram for irr::scene::ISceneCollisionManager:</div>
<div class="dynsection">

<p><center><img src="classirr_1_1scene_1_1_i_scene_collision_manager.png" usemap="#irr::scene::ISceneCollisionManager_map" border="0" alt=""></center>
<map name="irr::scene::ISceneCollisionManager_map">
<area href="classirr_1_1_i_reference_counted.html" alt="irr::IReferenceCounted" shape="rect" coords="0,0,209,24">
</map>
</div>

<p>
<a href="classirr_1_1scene_1_1_i_scene_collision_manager-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1scene_1_1_i_scene_collision_manager.html#c47762d28d6576f60883a5f4f80311e6">getCollisionPoint</a> (const <a class="el" href="classirr_1_1core_1_1line3d.html">core::line3d</a>&lt; <a class="el" href="namespaceirr.html#0277be98d67dc26ff93b1a6a1d086b07">f32</a> &gt; &amp;ray, <a class="el" href="classirr_1_1scene_1_1_i_triangle_selector.html">ITriangleSelector</a> *selector, <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;outCollisionPoint, <a class="el" href="classirr_1_1core_1_1triangle3d.html">core::triangle3df</a> &amp;outTriangle, const <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&amp;outNode)=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Finds the collision point of a line and lots of triangles, if there is one.  <a href="#c47762d28d6576f60883a5f4f80311e6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1scene_1_1_i_scene_collision_manager.html#5824886c9b402f1e6048b171191aca23">getCollisionResultPosition</a> (<a class="el" href="classirr_1_1scene_1_1_i_triangle_selector.html">ITriangleSelector</a> *selector, const <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;ellipsoidPosition, const <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;ellipsoidRadius, const <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;ellipsoidDirectionAndSpeed, <a class="el" href="classirr_1_1core_1_1triangle3d.html">core::triangle3df</a> &amp;triout, <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;hitPosition, bool &amp;outFalling, const <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&amp;outNode, <a class="el" href="namespaceirr.html#0277be98d67dc26ff93b1a6a1d086b07">f32</a> slidingSpeed=0.0005f, const core::vector3df &amp;gravityDirectionAndSpeed=core::vector3df(0.0f, 0.0f, 0.0f))=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Collides a moving ellipsoid with a 3d world with gravity and returns the resulting new position of the ellipsoid.  <a href="#5824886c9b402f1e6048b171191aca23"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classirr_1_1core_1_1line3d.html">core::line3d</a>&lt; <a class="el" href="namespaceirr.html#0277be98d67dc26ff93b1a6a1d086b07">f32</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1scene_1_1_i_scene_collision_manager.html#db95809ed422e138405f30844740666b">getRayFromScreenCoordinates</a> (const core::position2d&lt; <a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a> &gt; &amp;pos, <a class="el" href="classirr_1_1scene_1_1_i_camera_scene_node.html">ICameraSceneNode</a> *camera=0)=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns a 3d ray which would go through the 2d screen coodinates.  <a href="#db95809ed422e138405f30844740666b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1scene_1_1_i_scene_collision_manager.html#25af822d52bce9acd88adfc7ce484982">getSceneNodeAndCollisionPointFromRay</a> (<a class="el" href="classirr_1_1core_1_1line3d.html">core::line3df</a> ray, <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;outCollisionPoint, <a class="el" href="classirr_1_1core_1_1triangle3d.html">core::triangle3df</a> &amp;outTriangle, <a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a> idBitMask=0, <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *collisionRootNode=0, bool noDebugObjects=false)=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Perform a ray/box and ray/triangle collision check on a heirarchy of <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes.  <a href="#25af822d52bce9acd88adfc7ce484982"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1scene_1_1_i_scene_collision_manager.html#b29e0a261409a95a20e15ee09cc0de64">getSceneNodeFromCameraBB</a> (<a class="el" href="classirr_1_1scene_1_1_i_camera_scene_node.html">ICameraSceneNode</a> *camera, <a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a> idBitMask=0, bool bNoDebugObjects=false)=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node, which the given camera is looking at and whose id matches the bitmask.  <a href="#b29e0a261409a95a20e15ee09cc0de64"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1scene_1_1_i_scene_collision_manager.html#420ffad2d3a8bcd2f51b504cb8709ac6">getSceneNodeFromRayBB</a> (const <a class="el" href="classirr_1_1core_1_1line3d.html">core::line3d</a>&lt; <a class="el" href="namespaceirr.html#0277be98d67dc26ff93b1a6a1d086b07">f32</a> &gt; &amp;ray, <a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a> idBitMask=0, bool bNoDebugObjects=false, <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *root=0)=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns the nearest <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node which collides with a 3d ray and whose id matches a bitmask.  <a href="#420ffad2d3a8bcd2f51b504cb8709ac6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1scene_1_1_i_scene_collision_manager.html#ca97a47ae237373bbd681268a462f4a0">getSceneNodeFromScreenCoordinatesBB</a> (const core::position2d&lt; <a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a> &gt; &amp;pos, <a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a> idBitMask=0, bool bNoDebugObjects=false, <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *root=0)=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Gets the <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node, which is currently visible under the given screencoordinates, viewed from the currently active camera.  <a href="#ca97a47ae237373bbd681268a462f4a0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual core::position2d&lt; <a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a> &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1scene_1_1_i_scene_collision_manager.html#664fb2a7fd950996ebdf47411b4de443">getScreenCoordinatesFrom3DPosition</a> (const <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;pos, <a class="el" href="classirr_1_1scene_1_1_i_camera_scene_node.html">ICameraSceneNode</a> *camera=0)=0</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Calculates 2d screen position from a 3d position.  <a href="#664fb2a7fd950996ebdf47411b4de443"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
The Scene Collision Manager provides methods for performing collision tests and picking on <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes. 
<p>Definition at line <a class="el" href="_i_scene_collision_manager_8h-source.html#l00024">24</a> of file <a class="el" href="_i_scene_collision_manager_8h-source.html">ISceneCollisionManager.h</a>.</p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="c47762d28d6576f60883a5f4f80311e6"></a><!-- doxytag: member="irr::scene::ISceneCollisionManager::getCollisionPoint" ref="c47762d28d6576f60883a5f4f80311e6" args="(const core::line3d&lt; f32 &gt; &amp;ray, ITriangleSelector *selector, core::vector3df &amp;outCollisionPoint, core::triangle3df &amp;outTriangle, const ISceneNode *&amp;outNode)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool irr::scene::ISceneCollisionManager::getCollisionPoint           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classirr_1_1core_1_1line3d.html">core::line3d</a>&lt; <a class="el" href="namespaceirr.html#0277be98d67dc26ff93b1a6a1d086b07">f32</a> &gt; &amp;&nbsp;</td>
          <td class="paramname"> <em>ray</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1scene_1_1_i_triangle_selector.html">ITriangleSelector</a> *&nbsp;</td>
          <td class="paramname"> <em>selector</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>outCollisionPoint</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1core_1_1triangle3d.html">core::triangle3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>outTriangle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&amp;&nbsp;</td>
          <td class="paramname"> <em>outNode</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Finds the collision point of a line and lots of triangles, if there is one. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>ray,:</em>&nbsp;</td><td>Line with witch collisions are tested. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>selector,:</em>&nbsp;</td><td>TriangleSelector containing the triangles. It can be created for example using <a class="el" href="classirr_1_1scene_1_1_i_scene_manager.html#266625379b1558e9be1dc062ea4e71f7" title="Creates a simple ITriangleSelector, based on a mesh.">ISceneManager::createTriangleSelector()</a> or ISceneManager::createTriangleOctTreeSelector(). </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>outCollisionPoint,:</em>&nbsp;</td><td>If a collision is detected, this will contain the position of the nearest collision. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>outTriangle,:</em>&nbsp;</td><td>If a collision is detected, this will contain the triangle with which the ray collided. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>outNode,:</em>&nbsp;</td><td>If a collision is detected, this will contain the <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node associated with the triangle that was hit. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>True if a collision was detected and false if not. </dd></dl>

</div>
</div><p>
<a class="anchor" name="5824886c9b402f1e6048b171191aca23"></a><!-- doxytag: member="irr::scene::ISceneCollisionManager::getCollisionResultPosition" ref="5824886c9b402f1e6048b171191aca23" args="(ITriangleSelector *selector, const core::vector3df &amp;ellipsoidPosition, const core::vector3df &amp;ellipsoidRadius, const core::vector3df &amp;ellipsoidDirectionAndSpeed, core::triangle3df &amp;triout, core::vector3df &amp;hitPosition, bool &amp;outFalling, const ISceneNode *&amp;outNode, f32 slidingSpeed=0.0005f, const core::vector3df &amp;gravityDirectionAndSpeed=core::vector3df(0.0f, 0.0f, 0.0f))=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> irr::scene::ISceneCollisionManager::getCollisionResultPosition           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classirr_1_1scene_1_1_i_triangle_selector.html">ITriangleSelector</a> *&nbsp;</td>
          <td class="paramname"> <em>selector</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>ellipsoidPosition</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>ellipsoidRadius</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>ellipsoidDirectionAndSpeed</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1core_1_1triangle3d.html">core::triangle3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>triout</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>hitPosition</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool &amp;&nbsp;</td>
          <td class="paramname"> <em>outFalling</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&amp;&nbsp;</td>
          <td class="paramname"> <em>outNode</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespaceirr.html#0277be98d67dc26ff93b1a6a1d086b07">f32</a>&nbsp;</td>
          <td class="paramname"> <em>slidingSpeed</em> = <code>0.0005f</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>gravityDirectionAndSpeed</em> = <code><a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a>(0.0f,&nbsp;0.0f,&nbsp;0.0f)</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Collides a moving ellipsoid with a 3d world with gravity and returns the resulting new position of the ellipsoid. 
<p>
This can be used for moving a character in a 3d world: The character will slide at walls and is able to walk up stairs. The method used how to calculate the collision result position is based on the paper "Improved Collision detection and Response" by Kasper Fauerby. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>selector,:</em>&nbsp;</td><td>TriangleSelector containing the triangles of the world. It can be created for example using <a class="el" href="classirr_1_1scene_1_1_i_scene_manager.html#266625379b1558e9be1dc062ea4e71f7" title="Creates a simple ITriangleSelector, based on a mesh.">ISceneManager::createTriangleSelector()</a> or ISceneManager::createTriangleOctTreeSelector(). </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>ellipsoidPosition,:</em>&nbsp;</td><td>Position of the ellipsoid. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>ellipsoidRadius,:</em>&nbsp;</td><td>Radius of the ellipsoid. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>ellipsoidDirectionAndSpeed,:</em>&nbsp;</td><td>Direction and speed of the movement of the ellipsoid. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>triout,:</em>&nbsp;</td><td>Optional parameter where the last triangle causing a collision is stored, if there is a collision. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>hitPosition,:</em>&nbsp;</td><td>Return value for the position of the collision </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>outFalling,:</em>&nbsp;</td><td>Is set to true if the ellipsoid is falling down, caused by gravity. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>outNode,:</em>&nbsp;</td><td>the node with which the ellipoid collided (if any) </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>slidingSpeed,:</em>&nbsp;</td><td>DOCUMENTATION NEEDED. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>gravityDirectionAndSpeed,:</em>&nbsp;</td><td>Direction and force of gravity. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>New position of the ellipsoid. </dd></dl>

</div>
</div><p>
<a class="anchor" name="db95809ed422e138405f30844740666b"></a><!-- doxytag: member="irr::scene::ISceneCollisionManager::getRayFromScreenCoordinates" ref="db95809ed422e138405f30844740666b" args="(const core::position2d&lt; s32 &gt; &amp;pos, ICameraSceneNode *camera=0)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classirr_1_1core_1_1line3d.html">core::line3d</a>&lt;<a class="el" href="namespaceirr.html#0277be98d67dc26ff93b1a6a1d086b07">f32</a>&gt; irr::scene::ISceneCollisionManager::getRayFromScreenCoordinates           </td>
          <td>(</td>
          <td class="paramtype">const core::position2d&lt; <a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a> &gt; &amp;&nbsp;</td>
          <td class="paramname"> <em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1scene_1_1_i_camera_scene_node.html">ICameraSceneNode</a> *&nbsp;</td>
          <td class="paramname"> <em>camera</em> = <code>0</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Returns a 3d ray which would go through the 2d screen coodinates. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>pos,:</em>&nbsp;</td><td>Screen coordinates in pixels. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>camera,:</em>&nbsp;</td><td>Camera from which the ray starts. If null, the active camera is used. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Ray starting from the position of the camera and ending at a length of the far value of the camera at a position which would be behind the 2d screen coodinates. </dd></dl>

</div>
</div><p>
<a class="anchor" name="25af822d52bce9acd88adfc7ce484982"></a><!-- doxytag: member="irr::scene::ISceneCollisionManager::getSceneNodeAndCollisionPointFromRay" ref="25af822d52bce9acd88adfc7ce484982" args="(core::line3df ray, core::vector3df &amp;outCollisionPoint, core::triangle3df &amp;outTriangle, s32 idBitMask=0, ISceneNode *collisionRootNode=0, bool noDebugObjects=false)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a>* irr::scene::ISceneCollisionManager::getSceneNodeAndCollisionPointFromRay           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classirr_1_1core_1_1line3d.html">core::line3df</a>&nbsp;</td>
          <td class="paramname"> <em>ray</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>outCollisionPoint</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1core_1_1triangle3d.html">core::triangle3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>outTriangle</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a>&nbsp;</td>
          <td class="paramname"> <em>idBitMask</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&nbsp;</td>
          <td class="paramname"> <em>collisionRootNode</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>noDebugObjects</em> = <code>false</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Perform a ray/box and ray/triangle collision check on a heirarchy of <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes. 
<p>
This checks all <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes under the specified one, first by ray/bounding box, and then by accurate ray/triangle collision, finding the nearest collision, and the <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node containg it. It returns the node hit, and (via output parameters) the position of the collision, and the triangle that was hit.<p>
All <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes in the hierarchy tree under the specified node are checked. Only notes that are visible, with an ID that matches at least one bit in the supplied bitmask, and which have a triangle selector are considered as candidates for being hit. You do not have to build a meta triangle selector; the individual triangle selectors of each candidate <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node are used automatically.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>ray,:</em>&nbsp;</td><td>Line with which collisions are tested. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>outCollisionPoint,:</em>&nbsp;</td><td>If a collision is detected, this will contain the position of the nearest collision. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>outTriangle,:</em>&nbsp;</td><td>If a collision is detected, this will contain the triangle with which the ray collided. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>idBitMask,:</em>&nbsp;</td><td>Only <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes with an id which matches at least one of the bits contained in this mask will be tested. However, if this parameter is 0, then all nodes are checked. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>collisionRootNode,:</em>&nbsp;</td><td>the <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node at which to begin checking. Only this node and its children will be checked. If you want to check the entire <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a>, pass 0, and the root <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node will be used (this is the default). </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>noDebugObjects,:</em>&nbsp;</td><td>when true, debug objects are not considered viable targets. Debug objects are <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes with IsDebugObject() = true. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Returns the <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node containing the hit triangle nearest to ray.start. If no collision is detected, then 0 is returned. </dd></dl>

</div>
</div><p>
<a class="anchor" name="b29e0a261409a95a20e15ee09cc0de64"></a><!-- doxytag: member="irr::scene::ISceneCollisionManager::getSceneNodeFromCameraBB" ref="b29e0a261409a95a20e15ee09cc0de64" args="(ICameraSceneNode *camera, s32 idBitMask=0, bool bNoDebugObjects=false)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a>* irr::scene::ISceneCollisionManager::getSceneNodeFromCameraBB           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classirr_1_1scene_1_1_i_camera_scene_node.html">ICameraSceneNode</a> *&nbsp;</td>
          <td class="paramname"> <em>camera</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a>&nbsp;</td>
          <td class="paramname"> <em>idBitMask</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>bNoDebugObjects</em> = <code>false</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Get the <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node, which the given camera is looking at and whose id matches the bitmask. 
<p>
A ray is simply casted from the position of the camera to the view target position, and all <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes are tested against this ray. The collision tests are done using a bounding box for each <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>camera,:</em>&nbsp;</td><td>Camera from which the ray is casted. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>idBitMask,:</em>&nbsp;</td><td>Only <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes with an id which matches at least one of the bits contained in this mask will be tested. However, if this parameter is 0, then all nodes are checked. feature is disabled. Please note that the default node id of -1 will match with every bitmask != 0 </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>bNoDebugObjects,:</em>&nbsp;</td><td>Doesn't take debug objects into account when true. These are <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes with IsDebugObject() = true. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Scene node nearest to the camera, which collides with the ray and matches the idBitMask, if the mask is not null. If no <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node is found, 0 is returned. </dd></dl>

</div>
</div><p>
<a class="anchor" name="420ffad2d3a8bcd2f51b504cb8709ac6"></a><!-- doxytag: member="irr::scene::ISceneCollisionManager::getSceneNodeFromRayBB" ref="420ffad2d3a8bcd2f51b504cb8709ac6" args="(const core::line3d&lt; f32 &gt; &amp;ray, s32 idBitMask=0, bool bNoDebugObjects=false, ISceneNode *root=0)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a>* irr::scene::ISceneCollisionManager::getSceneNodeFromRayBB           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classirr_1_1core_1_1line3d.html">core::line3d</a>&lt; <a class="el" href="namespaceirr.html#0277be98d67dc26ff93b1a6a1d086b07">f32</a> &gt; &amp;&nbsp;</td>
          <td class="paramname"> <em>ray</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a>&nbsp;</td>
          <td class="paramname"> <em>idBitMask</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>bNoDebugObjects</em> = <code>false</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&nbsp;</td>
          <td class="paramname"> <em>root</em> = <code>0</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Returns the nearest <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node which collides with a 3d ray and whose id matches a bitmask. 
<p>
The collision tests are done using a bounding box for each <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node. The recursive search can be limited be specifying a <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>ray</em>&nbsp;</td><td>Line with which collisions are tested. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>idBitMask</em>&nbsp;</td><td>Only <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes with an id which matches at least one of the bits contained in this mask will be tested. However, if this parameter is 0, then all nodes are checked. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>bNoDebugObjects,:</em>&nbsp;</td><td>Doesn't take debug objects into account when true. These are <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes with IsDebugObject() = true. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>root</em>&nbsp;</td><td>If different from 0, the search is limited to the children of this node. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Scene node nearest to ray.start, which collides with the ray and matches the idBitMask, if the mask is not null. If no <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node is found, 0 is returned. </dd></dl>

</div>
</div><p>
<a class="anchor" name="ca97a47ae237373bbd681268a462f4a0"></a><!-- doxytag: member="irr::scene::ISceneCollisionManager::getSceneNodeFromScreenCoordinatesBB" ref="ca97a47ae237373bbd681268a462f4a0" args="(const core::position2d&lt; s32 &gt; &amp;pos, s32 idBitMask=0, bool bNoDebugObjects=false, ISceneNode *root=0)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a>* irr::scene::ISceneCollisionManager::getSceneNodeFromScreenCoordinatesBB           </td>
          <td>(</td>
          <td class="paramtype">const core::position2d&lt; <a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a> &gt; &amp;&nbsp;</td>
          <td class="paramname"> <em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a>&nbsp;</td>
          <td class="paramname"> <em>idBitMask</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>bNoDebugObjects</em> = <code>false</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1scene_1_1_i_scene_node.html">ISceneNode</a> *&nbsp;</td>
          <td class="paramname"> <em>root</em> = <code>0</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Gets the <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node, which is currently visible under the given screencoordinates, viewed from the currently active camera. 
<p>
The collision tests are done using a bounding box for each <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node. You can limit the recursive search so just all children of the specified root are tested. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>pos,:</em>&nbsp;</td><td>Position in pixel screen coordinates, under which the returned <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node will be. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>idBitMask,:</em>&nbsp;</td><td>Only <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes with an id with bits set like in this mask will be tested. If the BitMask is 0, this feature is disabled. Please note that the default node id of -1 will match with every bitmask != 0 </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>bNoDebugObjects,:</em>&nbsp;</td><td>Doesn't take debug objects into account when true. These are <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> nodes with IsDebugObject() = true. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>root</em>&nbsp;</td><td>If different from 0, the search is limited to the children of this node. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Visible <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node under screen coordinates with matching bits in its id. If there is no <a class="el" href="namespaceirr_1_1scene.html" title="All scene management can be found in this namespace: Mesh loading, special scene...">scene</a> node under this position, 0 is returned. </dd></dl>

</div>
</div><p>
<a class="anchor" name="664fb2a7fd950996ebdf47411b4de443"></a><!-- doxytag: member="irr::scene::ISceneCollisionManager::getScreenCoordinatesFrom3DPosition" ref="664fb2a7fd950996ebdf47411b4de443" args="(const core::vector3df &amp;pos, ICameraSceneNode *camera=0)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual core::position2d&lt;<a class="el" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6">s32</a>&gt; irr::scene::ISceneCollisionManager::getScreenCoordinatesFrom3DPosition           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classirr_1_1core_1_1vector3d.html">core::vector3df</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1scene_1_1_i_camera_scene_node.html">ICameraSceneNode</a> *&nbsp;</td>
          <td class="paramname"> <em>camera</em> = <code>0</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Calculates 2d screen position from a 3d position. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>pos,:</em>&nbsp;</td><td>3D position in world space to be transformed into 2d. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>camera,:</em>&nbsp;</td><td>Camera to be used. If null, the currently active camera is used. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>2d screen coordinates which a object in the 3d world would have if it would be rendered to the screen. If the 3d position is behind the camera, it is set to (-10000,-10000). In most cases you can ignore this fact, because if you use this method for drawing a decorator over a 3d object, it will be clipped by the screen borders. </dd></dl>

</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="_i_scene_collision_manager_8h-source.html">ISceneCollisionManager.h</a></ul>
</div>
<hr size="1">
<address style="align: right;">
<small> </small>
</address>
<table width="100%" border="0" cellspacing="0" cellpadding="2">
  <tr> 
    <td width="0"> <div align="left"><small><a href="http://irrlicht.sourceforge.net" target="_blank"><img src="irrlicht.png" alt="The Irrlicht Engine" align="middle" border=0 width=88 height=31></a></small></div></td>
    <td> <div align="left"><small><em><font size="2">The <a href="http://irrlicht.sourceforge.net" target="_blank">Irrlicht 
        Engine</a> Documentation &copy; 2003-2009 by Nikolaus Gebhardt. Generated 
        on Sun Jan 10 09:24:14 2010 by <a href="http://www.doxygen.org" target="_blank">Doxygen</a> 
        (1.5.6)</font></em></small></div></td>
  </tr>
</table>
<address style="align: right;">
</address>
</body>
</html>