blob: 7c902ccd01cb27fcbd22a23614838fbc14aff2f6 [file] [log] [blame]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.10"/>
<title>0.9.8: GLM_GTX_rotate_vector</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectlogo"><img alt="Logo" src="logo.png"/></td>
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">0.9.8
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.10 -->
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main&#160;Page</span></a></li>
<li><a href="modules.html"><span>Modules</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#func-members">Functions</a> </div>
<div class="headertitle">
<div class="title">GLM_GTX_rotate_vector<div class="ingroups"><a class="el" href="a00155.html">GTX Extensions (Experimental)</a></div></div> </div>
</div><!--header-->
<div class="contents">
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ga49b4d082305cdfcfe0a5c184f684a902"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:ga49b4d082305cdfcfe0a5c184f684a902"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tmat4x4&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#ga49b4d082305cdfcfe0a5c184f684a902">orientation</a> (tvec3&lt; T, P &gt; const &amp;Normal, tvec3&lt; T, P &gt; const &amp;Up)</td></tr>
<tr class="separator:ga49b4d082305cdfcfe0a5c184f684a902"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga9bff444fb191e2e089a906b899cd033d"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:ga9bff444fb191e2e089a906b899cd033d"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tvec2&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#ga9bff444fb191e2e089a906b899cd033d">rotate</a> (tvec2&lt; T, P &gt; const &amp;v, T const &amp;angle)</td></tr>
<tr class="separator:ga9bff444fb191e2e089a906b899cd033d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga526b6f8995bc0946aa1a04e9297de7c6"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:ga526b6f8995bc0946aa1a04e9297de7c6"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tvec3&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#ga526b6f8995bc0946aa1a04e9297de7c6">rotate</a> (tvec3&lt; T, P &gt; const &amp;v, T const &amp;angle, tvec3&lt; T, P &gt; const &amp;normal)</td></tr>
<tr class="separator:ga526b6f8995bc0946aa1a04e9297de7c6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaf4d59dd2f668f9ffb38048055d1316bd"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:gaf4d59dd2f668f9ffb38048055d1316bd"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tvec4&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#gaf4d59dd2f668f9ffb38048055d1316bd">rotate</a> (tvec4&lt; T, P &gt; const &amp;v, T const &amp;angle, tvec3&lt; T, P &gt; const &amp;normal)</td></tr>
<tr class="separator:gaf4d59dd2f668f9ffb38048055d1316bd"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga0c2dc9f8507bffcbb957db9818b18508"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:ga0c2dc9f8507bffcbb957db9818b18508"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tvec3&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#ga0c2dc9f8507bffcbb957db9818b18508">rotateX</a> (tvec3&lt; T, P &gt; const &amp;v, T const &amp;angle)</td></tr>
<tr class="separator:ga0c2dc9f8507bffcbb957db9818b18508"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gadab312d430a564741ae02215255027a0"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:gadab312d430a564741ae02215255027a0"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tvec4&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#gadab312d430a564741ae02215255027a0">rotateX</a> (tvec4&lt; T, P &gt; const &amp;v, T const &amp;angle)</td></tr>
<tr class="separator:gadab312d430a564741ae02215255027a0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gabb5d19eba5befeebcb35a0aad4a114e3"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:gabb5d19eba5befeebcb35a0aad4a114e3"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tvec3&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#gabb5d19eba5befeebcb35a0aad4a114e3">rotateY</a> (tvec3&lt; T, P &gt; const &amp;v, T const &amp;angle)</td></tr>
<tr class="separator:gabb5d19eba5befeebcb35a0aad4a114e3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gae2507577c4bffa3548b32852791dd90c"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:gae2507577c4bffa3548b32852791dd90c"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tvec4&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#gae2507577c4bffa3548b32852791dd90c">rotateY</a> (tvec4&lt; T, P &gt; const &amp;v, T const &amp;angle)</td></tr>
<tr class="separator:gae2507577c4bffa3548b32852791dd90c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gae30ac01b89d4f16a972fee696c964908"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:gae30ac01b89d4f16a972fee696c964908"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tvec3&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#gae30ac01b89d4f16a972fee696c964908">rotateZ</a> (tvec3&lt; T, P &gt; const &amp;v, T const &amp;angle)</td></tr>
<tr class="separator:gae30ac01b89d4f16a972fee696c964908"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga034e5d197ab4bd8685624bc2cf16e586"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:ga034e5d197ab4bd8685624bc2cf16e586"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tvec4&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#ga034e5d197ab4bd8685624bc2cf16e586">rotateZ</a> (tvec4&lt; T, P &gt; const &amp;v, T const &amp;angle)</td></tr>
<tr class="separator:ga034e5d197ab4bd8685624bc2cf16e586"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gafc9ab3101c3f3799f3d5d6d9d3baac09"><td class="memTemplParams" colspan="2">template&lt;typename T , precision P&gt; </td></tr>
<tr class="memitem:gafc9ab3101c3f3799f3d5d6d9d3baac09"><td class="memTemplItemLeft" align="right" valign="top">GLM_FUNC_DECL tvec3&lt; T, P &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00224.html#gafc9ab3101c3f3799f3d5d6d9d3baac09">slerp</a> (tvec3&lt; T, P &gt; const &amp;x, tvec3&lt; T, P &gt; const &amp;y, T const &amp;a)</td></tr>
<tr class="separator:gafc9ab3101c3f3799f3d5d6d9d3baac09"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<p>Function to directly rotate a vector. </p>
<p>&lt;<a class="el" href="a00094.html" title="GLM_GTX_rotate_vector ">glm/gtx/rotate_vector.hpp</a>&gt; need to be included to use these functionalities. </p>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="ga49b4d082305cdfcfe0a5c184f684a902"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tmat4x4&lt;T, P&gt; glm::orientation </td>
<td>(</td>
<td class="paramtype">tvec3&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>Normal</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">tvec3&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>Up</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Build a rotation matrix from a normal and a up vector. </p>
<p>From GLM_GTX_rotate_vector extension. </p>
</div>
</div>
<a class="anchor" id="ga9bff444fb191e2e089a906b899cd033d"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tvec2&lt;T, P&gt; glm::rotate </td>
<td>(</td>
<td class="paramtype">tvec2&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>v</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">T const &amp;&#160;</td>
<td class="paramname"><em>angle</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Rotate a two dimensional vector. </p>
<p>From GLM_GTX_rotate_vector extension. </p>
</div>
</div>
<a class="anchor" id="ga526b6f8995bc0946aa1a04e9297de7c6"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tvec3&lt;T, P&gt; glm::rotate </td>
<td>(</td>
<td class="paramtype">tvec3&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>v</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">T const &amp;&#160;</td>
<td class="paramname"><em>angle</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">tvec3&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>normal</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Rotate a three dimensional vector around an axis. </p>
<p>From GLM_GTX_rotate_vector extension. </p>
</div>
</div>
<a class="anchor" id="gaf4d59dd2f668f9ffb38048055d1316bd"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tvec4&lt;T, P&gt; glm::rotate </td>
<td>(</td>
<td class="paramtype">tvec4&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>v</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">T const &amp;&#160;</td>
<td class="paramname"><em>angle</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">tvec3&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>normal</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Rotate a four dimensional vector around an axis. </p>
<p>From GLM_GTX_rotate_vector extension. </p>
</div>
</div>
<a class="anchor" id="ga0c2dc9f8507bffcbb957db9818b18508"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tvec3&lt;T, P&gt; glm::rotateX </td>
<td>(</td>
<td class="paramtype">tvec3&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>v</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">T const &amp;&#160;</td>
<td class="paramname"><em>angle</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Rotate a three dimensional vector around the X axis. </p>
<p>From GLM_GTX_rotate_vector extension. </p>
</div>
</div>
<a class="anchor" id="gadab312d430a564741ae02215255027a0"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tvec4&lt;T, P&gt; glm::rotateX </td>
<td>(</td>
<td class="paramtype">tvec4&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>v</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">T const &amp;&#160;</td>
<td class="paramname"><em>angle</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Rotate a four dimentionnals vector around the X axis. </p>
<p>From GLM_GTX_rotate_vector extension. </p>
</div>
</div>
<a class="anchor" id="gabb5d19eba5befeebcb35a0aad4a114e3"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tvec3&lt;T, P&gt; glm::rotateY </td>
<td>(</td>
<td class="paramtype">tvec3&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>v</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">T const &amp;&#160;</td>
<td class="paramname"><em>angle</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Rotate a three dimensional vector around the Y axis. </p>
<p>From GLM_GTX_rotate_vector extension. </p>
</div>
</div>
<a class="anchor" id="gae2507577c4bffa3548b32852791dd90c"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tvec4&lt;T, P&gt; glm::rotateY </td>
<td>(</td>
<td class="paramtype">tvec4&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>v</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">T const &amp;&#160;</td>
<td class="paramname"><em>angle</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Rotate a four dimensional vector around the X axis. </p>
<p>From GLM_GTX_rotate_vector extension. </p>
</div>
</div>
<a class="anchor" id="gae30ac01b89d4f16a972fee696c964908"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tvec3&lt;T, P&gt; glm::rotateZ </td>
<td>(</td>
<td class="paramtype">tvec3&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>v</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">T const &amp;&#160;</td>
<td class="paramname"><em>angle</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Rotate a three dimensional vector around the Z axis. </p>
<p>From GLM_GTX_rotate_vector extension. </p>
</div>
</div>
<a class="anchor" id="ga034e5d197ab4bd8685624bc2cf16e586"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tvec4&lt;T, P&gt; glm::rotateZ </td>
<td>(</td>
<td class="paramtype">tvec4&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>v</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">T const &amp;&#160;</td>
<td class="paramname"><em>angle</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Rotate a four dimensional vector around the X axis. </p>
<p>From GLM_GTX_rotate_vector extension. </p>
</div>
</div>
<a class="anchor" id="gafc9ab3101c3f3799f3d5d6d9d3baac09"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">GLM_FUNC_DECL tvec3&lt;T, P&gt; glm::slerp </td>
<td>(</td>
<td class="paramtype">tvec3&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>x</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">tvec3&lt; T, P &gt; const &amp;&#160;</td>
<td class="paramname"><em>y</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">T const &amp;&#160;</td>
<td class="paramname"><em>a</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns Spherical interpolation between two vectors. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">x</td><td>A first vector </td></tr>
<tr><td class="paramname">y</td><td>A second vector </td></tr>
<tr><td class="paramname">a</td><td>Interpolation factor. The interpolation is defined beyond the range [0, 1].</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="a00224.html" title="Function to directly rotate a vector. ">GLM_GTX_rotate_vector</a> </dd></dl>
</div>
</div>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.10
</small></address>
</body>
</html>