| <!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"/> |
| |
| <title>frameworks/rs/scriptc/rs_matrix.rsh File Reference</title> |
| <link href="tabs.css" rel="stylesheet" type="text/css"/> |
| <link href="doxygen.css" rel="stylesheet" type="text/css" /> |
| |
| |
| |
| </head> |
| <body> |
| <div id="top"><!-- do not remove this div! --> |
| |
| |
| <!-- Generated by Doxygen 1.7.5.1 --> |
| <div id="navrow1" class="tabs"> |
| <ul class="tablist"> |
| <li><a href="index.html"><span>Overview</span></a></li> |
| <li class="current"><a href="globals.html"><span>Globals</span></a></li> |
| <li><a href="annotated.html"><span>Structs</span></a></li> |
| </ul> |
| </div> |
| </div> |
| <div class="header"> |
| <div class="summary"> |
| <a href="#func-members">Functions</a> </div> |
| <div class="headertitle"> |
| <div class="title">frameworks/rs/scriptc/rs_matrix.rsh File Reference</div> </div> |
| </div> |
| <div class="contents"> |
| <table class="memberdecls"> |
| <tr><td colspan="2"><h2><a name="func-members"></a> |
| Functions</h2></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#aca88832ed720e301780152c60884393e">rsMatrixSet</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, float v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a08a247cdf2e70e78310bf04f9ecd5144">rsMatrixSet</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, float v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#af9707d7be5945bf55ed53683624176ff">rsMatrixSet</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, float v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#af26fdbf8b8f0ed5d1b53f62b2aef5110">rsMatrixGet</a> (const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#acfebfc7b97e7282b78cd9c65b791932a">rsMatrixGet</a> (const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a683b4537b98103c50cc66780dfe8cd69">rsMatrixGet</a> (const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a5b31e83553efa947db2198674d5db043">rsMatrixLoadIdentity</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ad2954a5ac11d2370227296be89e92471">rsMatrixLoadIdentity</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const float *v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#aef942535c5d56072125dcf5244970ea2">rsMatrixLoad</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, const float *v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#aa327089f7ad9161d7372094163147005">rsMatrixLoad</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, const float *v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a5239a3f5f2becd20507d0aa56638ba03">rsMatrixLoad</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a06176acb38405937cb94c835a712a3b3">rsMatrixLoad</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a3a3d0f0053720fb4afb3a3eb32e42a82">rsMatrixLoad</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a654e5abe095770979d740f7b55382bd0">rsMatrixLoad</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a5f3697805c794c9c9f2f8cfdde4b9a44">rsMatrixLoad</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *v)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a268032f3ac6d766b1d7fe72a6cb50464">rsMatrixLoadRotate</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float rot, float x, float y, float z)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#acaf51d1f9ad5041ce01fbf8b7c5923fd">rsMatrixLoadScale</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float x, float y, float z)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a1b521c8a3d1260fa732cbf0a71af0e74">rsMatrixLoadTranslate</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float x, float y, float z)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *lhs, const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *rhs)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a78872343ea6a5c1a846160ccdc4add52">rsMatrixLoadMultiply</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *lhs, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *rhs)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ae0dd4755c28fc896626ebf5dc784130f">rsMatrixLoadMultiply</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *lhs, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *rhs)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *rhs)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ae0b03aeec17ec8b9c5e75f8efb1bdc53">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *rhs)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ab1973ad3efa0ab2d53f466dd9fb190bb">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *rhs)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ad5ed05ca4880397fb29615e3c6798de1">rsMatrixRotate</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float rot, float x, float y, float z)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a94cc6b22bd1a6c07a9a1c1d21afb392c">rsMatrixScale</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float x, float y, float z)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a4df5f9b5bb6044f3c3426f2f58b94405">rsMatrixTranslate</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float x, float y, float z)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a4c59884a0e534dbbcdc5655842732d43">rsMatrixLoadOrtho</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float left, float right, float bottom, float top, float near, float far)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ad25760aaf01e95d0055237afab41bbb3">rsMatrixLoadFrustum</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float left, float right, float bottom, float top, float near, float far)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#aa404c34d7478f2921f7415d2da95d02b">rsMatrixLoadPerspective</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float fovy, float aspect, float near, float far)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a47b6abbf32ffaf77bb13d96c3f05779f">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> in)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a716bc2d29b80eb25388aba3ba8845aef">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a00b6a334ba5ac94d84850f22ec9f4de5">rsMatrixInverse</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ac05080d52da2d99a759ef34fa0655e82">rsMatrixInverseTranspose</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ac52acb31a705f6c68af8bddea0e79969">rsMatrixTranspose</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m)</td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a49164dd4d4e85b212196028b1fd89dc1">rsMatrixTranspose</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m)</td></tr> |
| </table> |
| <hr/><a name="details" id="details"></a><h2>Detailed Description</h2> |
| <div class="textblock"><p>Matrix functions. </p> |
| <p>These functions let you manipulate square matrices of rank 2x2, 3x3, and 4x4. They are particularly useful for graphical transformations and are compatible with OpenGL.</p> |
| <p>A few general notes:</p> |
| <ul> |
| <li>We use a zero-based index for rows and columns. E.g. the last element of a <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> is found at (3, 3).</li> |
| </ul> |
| <ul> |
| <li>RenderScript uses column-based vectors. Transforming a vector is done by postmultiplying the vector, e.g. <em>(matrix * vector)</em>, as provided by <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</li> |
| </ul> |
| <ul> |
| <li>To create a transformation matrix that performs two transformations at once, multiply the two source matrices, with the first transformation as the right argument. E.g. to create a transformation matrix that applies the transformation <em>s1</em> followed by <em>s2</em>, call rsMatrixLoadMultiply(&combined, &s2, &s1). This derives from <em>s2 * (s1 * v)</em>, which is <em>(s2 * s1) * v</em>.</li> |
| </ul> |
| <ul> |
| <li>We have two style of functions to create transformation matrices: rsMatrixLoad<em>Transformation</em> and rsMatrix<em>Transformation</em>. The former style simply stores the transformation matrix in the first argument. The latter modifies a pre-existing transformation matrix so that the new transformation happens first. E.g. if you call <a class="el" href="rs__matrix_8rsh.html#a4df5f9b5bb6044f3c3426f2f58b94405">rsMatrixTranslate</a> on a matrix that already does a scaling, the resulting matrix when applied to a vector will first do the translation then the scaling. </li> |
| </ul> |
| |
| <p>Definition in file <a class="el" href="rs__matrix_8rsh_source.html">rs_matrix.rsh</a>.</p> |
| </div><hr/><h2>Function Documentation</h2> |
| <a class="anchor" id="af26fdbf8b8f0ed5d1b53f62b2aef5110"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="af26fdbf8b8f0ed5d1b53f62b2aef5110" args="(const rs_matrix4x4 *m, uint32_t col, uint32_t row)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">_RS_RUNTIME float rsMatrixGet </td> |
| <td>(</td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>col</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>row</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Returns one element of a matrix.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to extract the element from. </td></tr> |
| <tr><td class="paramname">col</td><td>The zero-based column of the element to be extracted. </td></tr> |
| <tr><td class="paramname">row</td><td>The zero-based row of the element to extracted.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="warning"><dt><b>Warning:</b></dt><dd>The order of the column and row parameters may be unexpected.</dd></dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>float </dd></dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="acfebfc7b97e7282b78cd9c65b791932a"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="acfebfc7b97e7282b78cd9c65b791932a" args="(const rs_matrix3x3 *m, uint32_t col, uint32_t row)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">_RS_RUNTIME float rsMatrixGet </td> |
| <td>(</td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>col</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>row</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a683b4537b98103c50cc66780dfe8cd69"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="a683b4537b98103c50cc66780dfe8cd69" args="(const rs_matrix2x2 *m, uint32_t col, uint32_t row)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">_RS_RUNTIME float rsMatrixGet </td> |
| <td>(</td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>col</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>row</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a00b6a334ba5ac94d84850f22ec9f4de5"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixInverse" ref="a00b6a334ba5ac94d84850f22ec9f4de5" args="(rs_matrix4x4 *m)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">bool rsMatrixInverse </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Inverts a matrix in place.</p> |
| <p>Returns true if the matrix was successfully inversed.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to invert. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ac05080d52da2d99a759ef34fa0655e82"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixInverseTranspose" ref="ac05080d52da2d99a759ef34fa0655e82" args="(rs_matrix4x4 *m)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">bool rsMatrixInverseTranspose </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Inverts and transpose a matrix in place.</p> |
| <p>The matrix is first inverted then transposed. Returns true if the matrix was successfully inverted.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to modify. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ac380c4117e047da494a74f0dad20fab3"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="ac380c4117e047da494a74f0dad20fab3" args="(rs_matrix4x4 *m, const float *v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoad </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const float * </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Set the elements of a matrix from an array of floats.</p> |
| <p>The array of floats should be in row-major order, i.e. the element a <em>row 0, column 0</em> should be first, followed by the element at <em>row 0, column 1</em>, etc.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to set. </td></tr> |
| <tr><td class="paramname">v</td><td>The array of values to set the matrix to. These arrays should be 4, 9, or 16 floats long, depending on the matrix size. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="aef942535c5d56072125dcf5244970ea2"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="aef942535c5d56072125dcf5244970ea2" args="(rs_matrix3x3 *m, const float *v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoad </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const float * </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="aa327089f7ad9161d7372094163147005"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="aa327089f7ad9161d7372094163147005" args="(rs_matrix2x2 *m, const float *v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoad </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const float * </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a5239a3f5f2becd20507d0aa56638ba03"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="a5239a3f5f2becd20507d0aa56638ba03" args="(rs_matrix4x4 *m, const rs_matrix4x4 *v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoad </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Set the elements of a matrix from another matrix.</p> |
| <p>If the source matrix is smaller than the destination, the rest of the destination is filled with elements of the identity matrix. E.g. loading a <a class="el" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> into a <a class="el" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> will give:</p> |
| <table> |
| <tr><td>m00</td><td>m01</td><td>0.0</td><td>0.0</td></tr> |
| <tr><td>m10</td><td>m11</td><td>0.0</td><td>0.0</td></tr> |
| <tr><td>0.0</td><td>0.0</td><td>1.0</td><td>0.0</td></tr> |
| <tr><td>0.0</td><td>0.0</td><td>0.0</td><td>1.0</td></tr> |
| </table><dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to set. </td></tr> |
| <tr><td class="paramname">v</td><td>The source matrix. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a06176acb38405937cb94c835a712a3b3"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="a06176acb38405937cb94c835a712a3b3" args="(rs_matrix4x4 *m, const rs_matrix3x3 *v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoad </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a3a3d0f0053720fb4afb3a3eb32e42a82"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="a3a3d0f0053720fb4afb3a3eb32e42a82" args="(rs_matrix4x4 *m, const rs_matrix2x2 *v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoad </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a654e5abe095770979d740f7b55382bd0"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="a654e5abe095770979d740f7b55382bd0" args="(rs_matrix3x3 *m, const rs_matrix3x3 *v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoad </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a5f3697805c794c9c9f2f8cfdde4b9a44"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoad" ref="a5f3697805c794c9c9f2f8cfdde4b9a44" args="(rs_matrix2x2 *m, const rs_matrix2x2 *v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoad </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ad25760aaf01e95d0055237afab41bbb3"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadFrustum" ref="ad25760aaf01e95d0055237afab41bbb3" args="(rs_matrix4x4 *m, float left, float right, float bottom, float top, float near, float far)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadFrustum </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>left</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>right</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>bottom</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>top</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>near</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>far</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Load a frustum projection matrix.</p> |
| <p>Constructs a frustum projection matrix, transforming the box identified by the six clipping planes <em>left, right, bottom, top, near, far</em>.</p> |
| <p>To apply this projection to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p> |
| <p>See <a href="https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf">https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf</a></p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to set. </td></tr> |
| <tr><td class="paramname">left</td><td></td></tr> |
| <tr><td class="paramname">right</td><td></td></tr> |
| <tr><td class="paramname">bottom</td><td></td></tr> |
| <tr><td class="paramname">top</td><td></td></tr> |
| <tr><td class="paramname">near</td><td></td></tr> |
| <tr><td class="paramname">far</td><td></td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a0ffd9de971cf10d0a663ff565be8d3cc"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadIdentity" ref="a0ffd9de971cf10d0a663ff565be8d3cc" args="(rs_matrix4x4 *m)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadIdentity </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Set the elements of a matrix to the identity matrix.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to set. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a5b31e83553efa947db2198674d5db043"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadIdentity" ref="a5b31e83553efa947db2198674d5db043" args="(rs_matrix3x3 *m)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadIdentity </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>m</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ad2954a5ac11d2370227296be89e92471"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadIdentity" ref="ad2954a5ac11d2370227296be89e92471" args="(rs_matrix2x2 *m)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadIdentity </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>m</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a79f14c4c0f5ecc1bbd0bf54da8b653ef"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadMultiply" ref="a79f14c4c0f5ecc1bbd0bf54da8b653ef" args="(rs_matrix4x4 *m, const rs_matrix4x4 *lhs, const rs_matrix4x4 *rhs)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadMultiply </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>lhs</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>rhs</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Multiply two matrices.</p> |
| <p>Sets <em>m</em> to the matrix product of <em>lhs * rhs</em>.</p> |
| <p>To combine two 4x4 transformaton matrices, multiply the second transformation matrix by the first transformation matrix. E.g. to create a transformation matrix that applies the transformation <em>s1</em> followed by <em>s2</em>, call rsMatrixLoadMultiply(&combined, &s2, &s1).</p> |
| <dl class="warning"><dt><b>Warning:</b></dt><dd>As of version 21, storing the result back into right matrix is not supported and will result in undefined behavior. Use rsMatrixMulitply instead. E.g. instead of doing rsMatrixLoadMultiply (&m2r, &m2r, &m2l), use rsMatrixMultiply (&m2r, &m2l). rsMatrixLoadMultiply (&m2l, &m2r, &m2l) works as expected.</dd></dl> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to set. </td></tr> |
| <tr><td class="paramname">lhs</td><td>The left matrix of the product. </td></tr> |
| <tr><td class="paramname">rhs</td><td>The right matrix of the product. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a78872343ea6a5c1a846160ccdc4add52"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadMultiply" ref="a78872343ea6a5c1a846160ccdc4add52" args="(rs_matrix3x3 *m, const rs_matrix3x3 *lhs, const rs_matrix3x3 *rhs)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadMultiply </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>lhs</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>rhs</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ae0dd4755c28fc896626ebf5dc784130f"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadMultiply" ref="ae0dd4755c28fc896626ebf5dc784130f" args="(rs_matrix2x2 *m, const rs_matrix2x2 *lhs, const rs_matrix2x2 *rhs)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadMultiply </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>lhs</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>rhs</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a4c59884a0e534dbbcdc5655842732d43"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadOrtho" ref="a4c59884a0e534dbbcdc5655842732d43" args="(rs_matrix4x4 *m, float left, float right, float bottom, float top, float near, float far)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadOrtho </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>left</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>right</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>bottom</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>top</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>near</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>far</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Load an orthographic projection matrix.</p> |
| <p>Constructs an orthographic projection matrix, transforming the box identified by the six clipping planes <em>left, right, bottom, top, near, far</em> into a unit cube with a corner at <em>(-1, -1, -1)</em> and the opposite at <em>(1, 1, 1)</em>.</p> |
| <p>To apply this projection to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p> |
| <p>See <a href="https://en.wikipedia.org/wiki/Orthographic_projection">https://en.wikipedia.org/wiki/Orthographic_projection</a> and <a href="https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf">https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf</a></p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to set. </td></tr> |
| <tr><td class="paramname">left</td><td></td></tr> |
| <tr><td class="paramname">right</td><td></td></tr> |
| <tr><td class="paramname">bottom</td><td></td></tr> |
| <tr><td class="paramname">top</td><td></td></tr> |
| <tr><td class="paramname">near</td><td></td></tr> |
| <tr><td class="paramname">far</td><td></td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="aa404c34d7478f2921f7415d2da95d02b"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadPerspective" ref="aa404c34d7478f2921f7415d2da95d02b" args="(rs_matrix4x4 *m, float fovy, float aspect, float near, float far)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadPerspective </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>fovy</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>aspect</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>near</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>far</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Load a perspective projection matrix.</p> |
| <p>Constructs a perspective projection matrix, assuming a symmetrical field of view.</p> |
| <p>To apply this projection to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p> |
| <p>See <a href="https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf">https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf</a></p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to set. </td></tr> |
| <tr><td class="paramname">fovy</td><td>Field of view, in degrees along the Y axis. </td></tr> |
| <tr><td class="paramname">aspect</td><td>Ratio of x / y. </td></tr> |
| <tr><td class="paramname">near</td><td>The near clipping plane. </td></tr> |
| <tr><td class="paramname">far</td><td>The far clipping plane. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a268032f3ac6d766b1d7fe72a6cb50464"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadRotate" ref="a268032f3ac6d766b1d7fe72a6cb50464" args="(rs_matrix4x4 *m, float rot, float x, float y, float z)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadRotate </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>rot</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>x</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>y</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>z</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Load a rotation matrix.</p> |
| <p>This function creates a rotation matrix. The axis of rotation is the <em>(x, y, z)</em> vector.</p> |
| <p>To rotate a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p> |
| <p>See <a href="http://en.wikipedia.org/wiki/Rotation_matrix">http://en.wikipedia.org/wiki/Rotation_matrix</a> .</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to set. </td></tr> |
| <tr><td class="paramname">rot</td><td>How much rotation to do, in degrees. </td></tr> |
| <tr><td class="paramname">x</td><td>The x component of the vector that is the axis of rotation. </td></tr> |
| <tr><td class="paramname">y</td><td>The y component of the vector that is the axis of rotation. </td></tr> |
| <tr><td class="paramname">z</td><td>The z component of the vector that is the axis of rotation. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="acaf51d1f9ad5041ce01fbf8b7c5923fd"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadScale" ref="acaf51d1f9ad5041ce01fbf8b7c5923fd" args="(rs_matrix4x4 *m, float x, float y, float z)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadScale </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>x</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>y</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>z</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Load a scale matrix.</p> |
| <p>This function creates a scaling matrix, where each component of a vector is multiplied by a number. This number can be negative.</p> |
| <p>To scale a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to set. </td></tr> |
| <tr><td class="paramname">x</td><td>The multiple to scale the x components by. </td></tr> |
| <tr><td class="paramname">y</td><td>The multiple to scale the y components by. </td></tr> |
| <tr><td class="paramname">z</td><td>The multiple to scale the z components by. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a1b521c8a3d1260fa732cbf0a71af0e74"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixLoadTranslate" ref="a1b521c8a3d1260fa732cbf0a71af0e74" args="(rs_matrix4x4 *m, float x, float y, float z)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixLoadTranslate </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>x</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>y</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>z</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Load a translation matrix.</p> |
| <p>This function creates a translation matrix, where a number is added to each element of a vector.</p> |
| <p>To translate a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to set. </td></tr> |
| <tr><td class="paramname">x</td><td>The number to add to each x component. </td></tr> |
| <tr><td class="paramname">y</td><td>The number to add to each y component. </td></tr> |
| <tr><td class="paramname">z</td><td>The number to add to each z component. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a97953ab2606900a839e5816c619abe66"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a97953ab2606900a839e5816c619abe66" args="(rs_matrix4x4 *m, const rs_matrix4x4 *rhs)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixMultiply </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>rhs</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Multiply a matrix into another one.</p> |
| <p>Sets <em>m</em> to the matrix product <em>m * rhs</em>.</p> |
| <p>When combining two 4x4 transformation matrices using this function, the resulting matrix will correspond to performing the <em>rhs</em> transformation first followed by the original <em>m</em> transformation.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The left matrix of the product and the matrix to be set. </td></tr> |
| <tr><td class="paramname">rhs</td><td>The right matrix of the product. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ae0b03aeec17ec8b9c5e75f8efb1bdc53"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="ae0b03aeec17ec8b9c5e75f8efb1bdc53" args="(rs_matrix3x3 *m, const rs_matrix3x3 *rhs)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixMultiply </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>rhs</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ab1973ad3efa0ab2d53f466dd9fb190bb"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="ab1973ad3efa0ab2d53f466dd9fb190bb" args="(rs_matrix2x2 *m, const rs_matrix2x2 *rhs)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixMultiply </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>rhs</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a47b6abbf32ffaf77bb13d96c3f05779f"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a47b6abbf32ffaf77bb13d96c3f05779f" args="(rs_matrix4x4 *m, float4 in)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> rsMatrixMultiply </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> </td> |
| <td class="paramname"><em>in</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Multiply a vector by a matrix.</p> |
| <p>Returns the post-multiplication of the vector by the matrix, ie. <em>m * in</em>.</p> |
| <p>When multiplying a <em>float3</em> to a <em><a class="el" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a></em>, the vector is expanded with (1).</p> |
| <p>When multiplying a <em>float2</em> to a <em><a class="el" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a></em>, the vector is expanded with (0, 1).</p> |
| <p>When multiplying a <em>float2</em> to a <em><a class="el" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a></em>, the vector is expanded with (0).</p> |
| <p>This function is available in API version 10-13. Starting with API 14, the function takes a const matrix as the first argument.</p> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a716bc2d29b80eb25388aba3ba8845aef"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a716bc2d29b80eb25388aba3ba8845aef" args="(rs_matrix3x3 *m, float3 in)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> rsMatrixMultiply </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> </td> |
| <td class="paramname"><em>in</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a4d9a8bb7c3f5d67b14fa349bdd531d13"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a4d9a8bb7c3f5d67b14fa349bdd531d13" args="(rs_matrix2x2 *m, float2 in)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> rsMatrixMultiply </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> </td> |
| <td class="paramname"><em>in</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ad5ed05ca4880397fb29615e3c6798de1"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixRotate" ref="ad5ed05ca4880397fb29615e3c6798de1" args="(rs_matrix4x4 *m, float rot, float x, float y, float z)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixRotate </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>rot</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>x</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>y</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>z</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Multiply the matrix <em>m</em> with a rotation matrix.</p> |
| <p>This function modifies a transformation matrix to first do a rotation. The axis of rotation is the <em>(x, y, z)</em> vector.</p> |
| <p>To apply this combined transformation to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to modify. </td></tr> |
| <tr><td class="paramname">rot</td><td>How much rotation to do, in degrees. </td></tr> |
| <tr><td class="paramname">x</td><td>The x component of the vector that is the axis of rotation. </td></tr> |
| <tr><td class="paramname">y</td><td>The y component of the vector that is the axis of rotation. </td></tr> |
| <tr><td class="paramname">z</td><td>The z component of the vector that is the axis of rotation. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a94cc6b22bd1a6c07a9a1c1d21afb392c"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixScale" ref="a94cc6b22bd1a6c07a9a1c1d21afb392c" args="(rs_matrix4x4 *m, float x, float y, float z)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixScale </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>x</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>y</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>z</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Multiply the matrix <em>m</em> with a scaling matrix.</p> |
| <p>This function modifies a transformation matrix to first do a scaling. When scaling, each component of a vector is multiplied by a number. This number can be negative.</p> |
| <p>To apply this combined transformation to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to modify. </td></tr> |
| <tr><td class="paramname">x</td><td>The multiple to scale the x components by. </td></tr> |
| <tr><td class="paramname">y</td><td>The multiple to scale the y components by. </td></tr> |
| <tr><td class="paramname">z</td><td>The multiple to scale the z components by. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="aca88832ed720e301780152c60884393e"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="aca88832ed720e301780152c60884393e" args="(rs_matrix4x4 *m, uint32_t col, uint32_t row, float v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">_RS_RUNTIME void rsMatrixSet </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>col</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>row</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Set an element of a matrix.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix that will be modified. </td></tr> |
| <tr><td class="paramname">col</td><td>The zero-based column of the element to be set. </td></tr> |
| <tr><td class="paramname">row</td><td>The zero-based row of the element to be set. </td></tr> |
| <tr><td class="paramname">v</td><td>The value to set.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="warning"><dt><b>Warning:</b></dt><dd>The order of the column and row parameters may be unexpected.</dd></dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>void </dd></dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a08a247cdf2e70e78310bf04f9ecd5144"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="a08a247cdf2e70e78310bf04f9ecd5144" args="(rs_matrix3x3 *m, uint32_t col, uint32_t row, float v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">_RS_RUNTIME void rsMatrixSet </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>col</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>row</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="af9707d7be5945bf55ed53683624176ff"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="af9707d7be5945bf55ed53683624176ff" args="(rs_matrix2x2 *m, uint32_t col, uint32_t row, float v)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">_RS_RUNTIME void rsMatrixSet </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>col</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> </td> |
| <td class="paramname"><em>row</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>v</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a4df5f9b5bb6044f3c3426f2f58b94405"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixTranslate" ref="a4df5f9b5bb6044f3c3426f2f58b94405" args="(rs_matrix4x4 *m, float x, float y, float z)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixTranslate </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>x</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>y</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>z</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Multiply the matrix <em>m</em> with a translation matrix.</p> |
| <p>This function modifies a transformation matrix to first do a translation. When translating, a number is added to each component of a vector.</p> |
| <p>To apply this combined transformation to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to modify. </td></tr> |
| <tr><td class="paramname">x</td><td>The number to add to each x component. </td></tr> |
| <tr><td class="paramname">y</td><td>The number to add to each y component. </td></tr> |
| <tr><td class="paramname">z</td><td>The number to add to each z component. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a88095c70f1550c760844b3e32e41a31a"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixTranspose" ref="a88095c70f1550c760844b3e32e41a31a" args="(rs_matrix4x4 *m)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixTranspose </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> * </td> |
| <td class="paramname"><em>m</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>Transpose the matrix m in place.</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">m</td><td>The matrix to transpose. </td></tr> |
| </table> |
| </dd> |
| </dl> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ac52acb31a705f6c68af8bddea0e79969"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixTranspose" ref="ac52acb31a705f6c68af8bddea0e79969" args="(rs_matrix3x3 *m)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixTranspose </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> * </td> |
| <td class="paramname"><em>m</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a49164dd4d4e85b212196028b1fd89dc1"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixTranspose" ref="a49164dd4d4e85b212196028b1fd89dc1" args="(rs_matrix2x2 *m)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">void rsMatrixTranspose </td> |
| <td>(</td> |
| <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> * </td> |
| <td class="paramname"><em>m</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p> |
| |
| </div> |
| </div> |
| </div> |
| |
| </body> |
| </html> |