mirror of
https://github.com/TheAlgorithms/C
synced 2025-01-06 01:52:00 +03:00
259 lines
22 KiB
HTML
259 lines
22 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://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.20"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>Algorithms_in_C: geometry/vectors_3d.c File Reference</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="../../navtree.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="../../resize.js"></script>
|
|
<script type="text/javascript" src="../../navtreedata.js"></script>
|
|
<script type="text/javascript" src="../../navtree.js"></script>
|
|
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="../../search/searchdata.js"></script>
|
|
<script type="text/javascript" src="../../search/search.js"></script>
|
|
<script type="text/x-mathjax-config">
|
|
MathJax.Hub.Config({
|
|
extensions: ["tex2jax.js", "TeX/AMSmath.js", "TeX/AMSsymbols.js"],
|
|
jax: ["input/TeX","output/HTML-CSS"],
|
|
});
|
|
</script>
|
|
<script type="text/javascript" async="async" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.7/MathJax.js?config=TeX-MML-AM_CHTML/MathJax.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="projectalign" style="padding-left: 0.5em;">
|
|
<div id="projectname">Algorithms_in_C
|
|
 <span id="projectnumber">1.0.0</span>
|
|
</div>
|
|
<div id="projectbrief">Set of algorithms implemented in C.</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.8.20 -->
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
|
|
/* @license-end */
|
|
</script>
|
|
<script type="text/javascript" src="../../menudata.js"></script>
|
|
<script type="text/javascript" src="../../menu.js"></script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
$(function() {
|
|
initMenu('../../',true,false,'search.php','Search');
|
|
$(document).ready(function() { init_search(); });
|
|
});
|
|
/* @license-end */</script>
|
|
<div id="main-nav"></div>
|
|
</div><!-- top -->
|
|
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
|
<div id="nav-tree">
|
|
<div id="nav-tree-contents">
|
|
<div id="nav-sync" class="sync"></div>
|
|
</div>
|
|
</div>
|
|
<div id="splitbar" style="-moz-user-select:none;"
|
|
class="ui-resizable-handle">
|
|
</div>
|
|
</div>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
$(document).ready(function(){initNavTree('d5/db8/vectors__3d_8c.html','../../'); initResizable(); });
|
|
/* @license-end */
|
|
</script>
|
|
<div id="doc-content">
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
</div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<iframe src="javascript:void(0)" frameborder="0"
|
|
name="MSearchResults" id="MSearchResults">
|
|
</iframe>
|
|
</div>
|
|
|
|
<div class="header">
|
|
<div class="summary">
|
|
<a href="#func-members">Functions</a> </div>
|
|
<div class="headertitle">
|
|
<div class="title">vectors_3d.c File Reference</div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
|
|
<p>Functions related to 3D vector operations.
|
|
<a href="#details">More...</a></p>
|
|
<div class="textblock"><code>#include <stdio.h></code><br />
|
|
<code>#include <math.h></code><br />
|
|
<code>#include <assert.h></code><br />
|
|
<code>#include "<a class="el" href="../../d0/dc7/geometry__datatypes_8h_source.html">geometry_datatypes.h</a>"</code><br />
|
|
</div><div class="textblock"><div class="dynheader">
|
|
Include dependency graph for vectors_3d.c:</div>
|
|
<div class="dyncontent">
|
|
<div class="center"><iframe scrolling="no" frameborder="0" src="../../d7/daf/vectors__3d_8c__incl.svg" width="430" height="112"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
|
|
</div>
|
|
</div>
|
|
</div><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
|
|
Functions</h2></td></tr>
|
|
<tr class="memitem:ga97da356cb7d5da73a0ac9bad09a435cc"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d7b/group__vec__3d.html#ga97da356cb7d5da73a0ac9bad09a435cc">vector_sub</a> (const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *a, const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *b)</td></tr>
|
|
<tr class="memdesc:ga97da356cb7d5da73a0ac9bad09a435cc"><td class="mdescLeft"> </td><td class="mdescRight">Subtract one vector from another. <a href="../../de/d7b/group__vec__3d.html#ga97da356cb7d5da73a0ac9bad09a435cc">More...</a><br /></td></tr>
|
|
<tr class="separator:ga97da356cb7d5da73a0ac9bad09a435cc"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:gaa6b5ac18429ffb0131dc8593d31c25a4"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d7b/group__vec__3d.html#gaa6b5ac18429ffb0131dc8593d31c25a4">vector_add</a> (const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *a, const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *b)</td></tr>
|
|
<tr class="memdesc:gaa6b5ac18429ffb0131dc8593d31c25a4"><td class="mdescLeft"> </td><td class="mdescRight">Add one vector to another. <a href="../../de/d7b/group__vec__3d.html#gaa6b5ac18429ffb0131dc8593d31c25a4">More...</a><br /></td></tr>
|
|
<tr class="separator:gaa6b5ac18429ffb0131dc8593d31c25a4"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ga243e74d542d0d4d14fa3ae0bc2170d84"><td class="memItemLeft" align="right" valign="top">float </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d7b/group__vec__3d.html#ga243e74d542d0d4d14fa3ae0bc2170d84">dot_prod</a> (const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *a, const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *b)</td></tr>
|
|
<tr class="memdesc:ga243e74d542d0d4d14fa3ae0bc2170d84"><td class="mdescLeft"> </td><td class="mdescRight">Obtain the dot product of two 3D vectors. <a href="../../de/d7b/group__vec__3d.html#ga243e74d542d0d4d14fa3ae0bc2170d84">More...</a><br /></td></tr>
|
|
<tr class="separator:ga243e74d542d0d4d14fa3ae0bc2170d84"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:gae4a49e6bdf13df949e8b23c7925bb5f5"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d7b/group__vec__3d.html#gae4a49e6bdf13df949e8b23c7925bb5f5">vector_prod</a> (const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *a, const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *b)</td></tr>
|
|
<tr class="memdesc:gae4a49e6bdf13df949e8b23c7925bb5f5"><td class="mdescLeft"> </td><td class="mdescRight">Compute the vector product of two 3d vectors. <a href="../../de/d7b/group__vec__3d.html#gae4a49e6bdf13df949e8b23c7925bb5f5">More...</a><br /></td></tr>
|
|
<tr class="separator:gae4a49e6bdf13df949e8b23c7925bb5f5"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ga4fd194972bea4884e0b33cf4a166d14e"><td class="memItemLeft" align="right" valign="top">const char * </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d7b/group__vec__3d.html#ga4fd194972bea4884e0b33cf4a166d14e">print_vector</a> (const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *a, const char *name)</td></tr>
|
|
<tr class="memdesc:ga4fd194972bea4884e0b33cf4a166d14e"><td class="mdescLeft"> </td><td class="mdescRight">Print formatted vector on stdout. <a href="../../de/d7b/group__vec__3d.html#ga4fd194972bea4884e0b33cf4a166d14e">More...</a><br /></td></tr>
|
|
<tr class="separator:ga4fd194972bea4884e0b33cf4a166d14e"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ga94805165d037d111d7d7c0df99e3a5de"><td class="memItemLeft" align="right" valign="top">float </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d7b/group__vec__3d.html#ga94805165d037d111d7d7c0df99e3a5de">vector_norm</a> (const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *a)</td></tr>
|
|
<tr class="memdesc:ga94805165d037d111d7d7c0df99e3a5de"><td class="mdescLeft"> </td><td class="mdescRight">Compute the norm a vector. <a href="../../de/d7b/group__vec__3d.html#ga94805165d037d111d7d7c0df99e3a5de">More...</a><br /></td></tr>
|
|
<tr class="separator:ga94805165d037d111d7d7c0df99e3a5de"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ga3cdfd8378a0b115563ea6c561bb46b7e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d7b/group__vec__3d.html#ga3cdfd8378a0b115563ea6c561bb46b7e">unit_vec</a> (const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *a)</td></tr>
|
|
<tr class="memdesc:ga3cdfd8378a0b115563ea6c561bb46b7e"><td class="mdescLeft"> </td><td class="mdescRight">Obtain unit vector in the same direction as given vector. <a href="../../de/d7b/group__vec__3d.html#ga3cdfd8378a0b115563ea6c561bb46b7e">More...</a><br /></td></tr>
|
|
<tr class="separator:ga3cdfd8378a0b115563ea6c561bb46b7e"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ga5082b0720c2cc51ae84bf19bd76dc849"><td class="memItemLeft" align="right" valign="top"><a class="el" href="../../dd/d7a/group__matrix.html#ga9f844010cb96591fa94c9d533a500ab7">mat_3x3</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d7b/group__vec__3d.html#ga5082b0720c2cc51ae84bf19bd76dc849">get_cross_matrix</a> (const <a class="el" href="../../de/d7b/group__vec__3d.html#gaf9ee870d4922e488bdd3e7262485c270">vec_3d</a> *a)</td></tr>
|
|
<tr class="memdesc:ga5082b0720c2cc51ae84bf19bd76dc849"><td class="mdescLeft"> </td><td class="mdescRight">The cross product of vectors can be represented as a matrix multiplication operation. <a href="../../de/d7b/group__vec__3d.html#ga5082b0720c2cc51ae84bf19bd76dc849">More...</a><br /></td></tr>
|
|
<tr class="separator:ga5082b0720c2cc51ae84bf19bd76dc849"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:aa8dca7b867074164d5f45b0f3851269d"><td class="memItemLeft" align="right" valign="top">static void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d5/db8/vectors__3d_8c.html#aa8dca7b867074164d5f45b0f3851269d">test</a> ()</td></tr>
|
|
<tr class="memdesc:aa8dca7b867074164d5f45b0f3851269d"><td class="mdescLeft"> </td><td class="mdescRight">Testing function. <a href="../../d5/db8/vectors__3d_8c.html#aa8dca7b867074164d5f45b0f3851269d">More...</a><br /></td></tr>
|
|
<tr class="separator:aa8dca7b867074164d5f45b0f3851269d"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a840291bc02cba5474a4cb46a9b9566fe"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="../../d5/db8/vectors__3d_8c.html#a840291bc02cba5474a4cb46a9b9566fe">main</a> (void)</td></tr>
|
|
<tr class="memdesc:a840291bc02cba5474a4cb46a9b9566fe"><td class="mdescLeft"> </td><td class="mdescRight">Main function. <a href="../../d5/db8/vectors__3d_8c.html#a840291bc02cba5474a4cb46a9b9566fe">More...</a><br /></td></tr>
|
|
<tr class="separator:a840291bc02cba5474a4cb46a9b9566fe"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table>
|
|
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
|
<div class="textblock"><p>Functions related to 3D vector operations. </p>
|
|
<dl class="section author"><dt>Author</dt><dd>Krishna Vedala </dd></dl>
|
|
</div><h2 class="groupheader">Function Documentation</h2>
|
|
<a id="a840291bc02cba5474a4cb46a9b9566fe"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#a840291bc02cba5474a4cb46a9b9566fe">◆ </a></span>main()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">int main </td>
|
|
<td>(</td>
|
|
<td class="paramtype">void </td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Main function. </p>
|
|
<dl class="section return"><dt>Returns</dt><dd>0 on exit </dd></dl>
|
|
<div class="fragment"><div class="line"><a name="l00234"></a><span class="lineno"> 234</span> {</div>
|
|
<div class="line"><a name="l00235"></a><span class="lineno"> 235</span>  <a class="code" href="../../d5/db8/vectors__3d_8c.html#aa8dca7b867074164d5f45b0f3851269d">test</a>();</div>
|
|
<div class="line"><a name="l00236"></a><span class="lineno"> 236</span>  </div>
|
|
<div class="line"><a name="l00237"></a><span class="lineno"> 237</span>  <span class="keywordflow">return</span> 0;</div>
|
|
<div class="line"><a name="l00238"></a><span class="lineno"> 238</span> }</div>
|
|
</div><!-- fragment --><div class="dynheader">
|
|
Here is the call graph for this function:</div>
|
|
<div class="dyncontent">
|
|
<div class="center"><iframe scrolling="no" frameborder="0" src="../../d5/db8/vectors__3d_8c_a840291bc02cba5474a4cb46a9b9566fe_cgraph.svg" width="416" height="114"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="aa8dca7b867074164d5f45b0f3851269d"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#aa8dca7b867074164d5f45b0f3851269d">◆ </a></span>test()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">static void test </td>
|
|
<td>(</td>
|
|
<td class="paramtype">void </td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">static</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Testing function. </p>
|
|
<dl class="section return"><dt>Returns</dt><dd><code>void</code> </dd></dl>
|
|
<div class="fragment"><div class="line"><a name="l00201"></a><span class="lineno"> 201</span> {</div>
|
|
<div class="line"><a name="l00202"></a><span class="lineno"> 202</span>  <a class="code" href="../../d5/db4/structvec__3d__.html">vec_3d</a> a = {1., 2., 3.};</div>
|
|
<div class="line"><a name="l00203"></a><span class="lineno"> 203</span>  <a class="code" href="../../d5/db4/structvec__3d__.html">vec_3d</a> b = {1., 1., 1.};</div>
|
|
<div class="line"><a name="l00204"></a><span class="lineno"> 204</span>  <span class="keywordtype">float</span> d;</div>
|
|
<div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  </div>
|
|
<div class="line"><a name="l00206"></a><span class="lineno"> 206</span>  <span class="comment">// printf("%s", print_vector(&a, "a"));</span></div>
|
|
<div class="line"><a name="l00207"></a><span class="lineno"> 207</span>  <span class="comment">// printf("%s", print_vector(&b, "b"));</span></div>
|
|
<div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  </div>
|
|
<div class="line"><a name="l00209"></a><span class="lineno"> 209</span>  d = <a class="code" href="../../de/d7b/group__vec__3d.html#ga94805165d037d111d7d7c0df99e3a5de">vector_norm</a>(&a);</div>
|
|
<div class="line"><a name="l00210"></a><span class="lineno"> 210</span>  <span class="comment">// printf("|a| = %.4g\n", d);</span></div>
|
|
<div class="line"><a name="l00211"></a><span class="lineno"> 211</span>  assert(fabsf(d - 3.742f) < 0.01);</div>
|
|
<div class="line"><a name="l00212"></a><span class="lineno"> 212</span>  d = <a class="code" href="../../de/d7b/group__vec__3d.html#ga94805165d037d111d7d7c0df99e3a5de">vector_norm</a>(&b);</div>
|
|
<div class="line"><a name="l00213"></a><span class="lineno"> 213</span>  <span class="comment">// printf("|b| = %.4g\n", d);</span></div>
|
|
<div class="line"><a name="l00214"></a><span class="lineno"> 214</span>  assert(fabsf(d - 1.732f) < 0.01);</div>
|
|
<div class="line"><a name="l00215"></a><span class="lineno"> 215</span>  </div>
|
|
<div class="line"><a name="l00216"></a><span class="lineno"> 216</span>  d = <a class="code" href="../../de/d7b/group__vec__3d.html#ga243e74d542d0d4d14fa3ae0bc2170d84">dot_prod</a>(&a, &b);</div>
|
|
<div class="line"><a name="l00217"></a><span class="lineno"> 217</span>  <span class="comment">// printf("Dot product: %f\n", d);</span></div>
|
|
<div class="line"><a name="l00218"></a><span class="lineno"> 218</span>  assert(fabsf(d - 6.f) < 0.01);</div>
|
|
<div class="line"><a name="l00219"></a><span class="lineno"> 219</span>  </div>
|
|
<div class="line"><a name="l00220"></a><span class="lineno"> 220</span>  <a class="code" href="../../d5/db4/structvec__3d__.html">vec_3d</a> c = <a class="code" href="../../de/d7b/group__vec__3d.html#gae4a49e6bdf13df949e8b23c7925bb5f5">vector_prod</a>(&a, &b);</div>
|
|
<div class="line"><a name="l00221"></a><span class="lineno"> 221</span>  <span class="comment">// printf("Vector product ");</span></div>
|
|
<div class="line"><a name="l00222"></a><span class="lineno"> 222</span>  <span class="comment">// printf("%s", print_vector(&c, "c"));</span></div>
|
|
<div class="line"><a name="l00223"></a><span class="lineno"> 223</span>  assert(fabsf(c.x - (-1.f)) < 0.01);</div>
|
|
<div class="line"><a name="l00224"></a><span class="lineno"> 224</span>  assert(fabsf(c.y - (2.f)) < 0.01);</div>
|
|
<div class="line"><a name="l00225"></a><span class="lineno"> 225</span>  assert(fabsf(c.z - (-1.f)) < 0.01);</div>
|
|
<div class="line"><a name="l00226"></a><span class="lineno"> 226</span> }</div>
|
|
</div><!-- fragment --><div class="dynheader">
|
|
Here is the call graph for this function:</div>
|
|
<div class="dyncontent">
|
|
<div class="center"><iframe scrolling="no" frameborder="0" src="../../d5/db8/vectors__3d_8c_aa8dca7b867074164d5f45b0f3851269d_cgraph.svg" width="318" height="114"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
</div><!-- contents -->
|
|
</div><!-- doc-content -->
|
|
<div class="ttc" id="agroup__vec__3d_html_ga94805165d037d111d7d7c0df99e3a5de"><div class="ttname"><a href="../../de/d7b/group__vec__3d.html#ga94805165d037d111d7d7c0df99e3a5de">vector_norm</a></div><div class="ttdeci">float vector_norm(const vec_3d *a)</div><div class="ttdoc">Compute the norm a vector.</div><div class="ttdef"><b>Definition:</b> vectors_3d.c:138</div></div>
|
|
<div class="ttc" id="astructvec__3d___html"><div class="ttname"><a href="../../d5/db4/structvec__3d__.html">vec_3d_</a></div><div class="ttdoc">3D vector type</div><div class="ttdef"><b>Definition:</b> geometry_datatypes.h:22</div></div>
|
|
<div class="ttc" id="avectors__3d_8c_html_aa8dca7b867074164d5f45b0f3851269d"><div class="ttname"><a href="../../d5/db8/vectors__3d_8c.html#aa8dca7b867074164d5f45b0f3851269d">test</a></div><div class="ttdeci">static void test()</div><div class="ttdoc">Testing function.</div><div class="ttdef"><b>Definition:</b> vectors_3d.c:200</div></div>
|
|
<div class="ttc" id="agroup__vec__3d_html_gae4a49e6bdf13df949e8b23c7925bb5f5"><div class="ttname"><a href="../../de/d7b/group__vec__3d.html#gae4a49e6bdf13df949e8b23c7925bb5f5">vector_prod</a></div><div class="ttdeci">vec_3d vector_prod(const vec_3d *a, const vec_3d *b)</div><div class="ttdoc">Compute the vector product of two 3d vectors.</div><div class="ttdef"><b>Definition:</b> vectors_3d.c:105</div></div>
|
|
<div class="ttc" id="agroup__vec__3d_html_ga243e74d542d0d4d14fa3ae0bc2170d84"><div class="ttname"><a href="../../de/d7b/group__vec__3d.html#ga243e74d542d0d4d14fa3ae0bc2170d84">dot_prod</a></div><div class="ttdeci">float dot_prod(const vec_3d *a, const vec_3d *b)</div><div class="ttdoc">Obtain the dot product of two 3D vectors.</div><div class="ttdef"><b>Definition:</b> vectors_3d.c:76</div></div>
|
|
<!-- start footer part -->
|
|
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
|
<ul>
|
|
<li class="navelem"><a class="el" href="../../dir_e3380d2178455503f266746fb14246a5.html">geometry</a></li><li class="navelem"><a class="el" href="../../d5/db8/vectors__3d_8c.html">vectors_3d.c</a></li>
|
|
<li class="footer">Generated by <a href="http://www.doxygen.org/index.html"><img class="footer" src="../../doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20 </li>
|
|
</ul>
|
|
</div>
|
|
</body>
|
|
</html>
|