diff options
author | neodarz <neodarz@neodarz.net> | 2018-08-11 20:21:34 +0200 |
---|---|---|
committer | neodarz <neodarz@neodarz.net> | 2018-08-11 20:21:34 +0200 |
commit | 0ea5fc66924303d1bf73ba283a383e2aadee02f2 (patch) | |
tree | 2568e71a7ccc44ec23b8bb3f0ff97fb6bf2ed709 /docs/doxygen/nel/a03466.html | |
download | nevrax-website-self-hostable-0ea5fc66924303d1bf73ba283a383e2aadee02f2.tar.xz nevrax-website-self-hostable-0ea5fc66924303d1bf73ba283a383e2aadee02f2.zip |
Initial commit
Diffstat (limited to '')
-rw-r--r-- | docs/doxygen/nel/a03466.html | 1038 |
1 files changed, 1038 insertions, 0 deletions
diff --git a/docs/doxygen/nel/a03466.html b/docs/doxygen/nel/a03466.html new file mode 100644 index 00000000..913571e0 --- /dev/null +++ b/docs/doxygen/nel/a03466.html @@ -0,0 +1,1038 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> +<title>NeL: NLPACS::CSurfaceQuadTree class Reference</title> +<link href="doxygen.css" rel="stylesheet" type="text/css"> +</head><body> +<!-- Generated by Doxygen 1.3.6 --> +<div class="qindex"> <form class="search" action="search.php" method="get"> +<a class="qindex" href="main.html">Main Page</a> | <a class="qindex" href="namespaces.html">Namespace List</a> | <a class="qindex" href="hierarchy.html">Class Hierarchy</a> | <a class="qindex" href="classes.html">Alphabetical List</a> | <a class="qindex" href="annotated.html">Data Structures</a> | <a class="qindex" href="files.html">File List</a> | <a class="qindex" href="namespacemembers.html">Namespace Members</a> | <a class="qindex" href="functions.html">Data Fields</a> | <a class="qindex" href="globals.html">Globals</a> | <a class="qindex" href="pages.html">Related Pages</a> | <span class="search"><u>S</u>earch for <input class="search" type="text" name="query" value="" size="20" accesskey="s"/></span></form></div> +<h1>NLPACS::CSurfaceQuadTree Class Reference</h1><code>#include <<a class="el" href="a06478.html">surface_quad.h</a>></code> +<p> +<table border=0 cellpadding=0 cellspacing=0> +<tr><td></td></tr> +<tr><td colspan=2><br><h2>Public Member Functions</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea0">addVertex</a> (const <a class="el" href="a03128.html">NLMISC::CVector</a> &<a class="el" href="a04223.html#a576">v</a>)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea1">check</a> () const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea2">clear</a> ()</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea3">compile</a> ()</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top> </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea4">CSurfaceQuadTree</a> (const <a class="el" href="a03466.html">CSurfaceQuadTree</a> &quad)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top> </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea5">CSurfaceQuadTree</a> ()</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>const <a class="el" href="a02156.html">NLMISC::CAABBox</a> & </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea6">getBBox</a> () const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>float </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea7">getInterpZ</a> (const <a class="el" href="a03128.html">NLMISC::CVector</a> &<a class="el" href="a04223.html#a576">v</a>) const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>const <a class="el" href="a03288.html">CQuadLeaf</a> * </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea8">getLeaf</a> (const <a class="el" href="a03128.html">NLMISC::CVector</a> &<a class="el" href="a04223.html#a576">v</a>) const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a7">uint8</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea9">getMaxLevel</a> () const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>float </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea10">getMaxThickness</a> () const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>const <a class="el" href="a03267.html">IQuadNode</a> * </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea11">getRoot</a> () const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea12">init</a> (float maxThickness, <a class="el" href="a04558.html#a15">uint</a> maxLevel, const <a class="el" href="a03128.html">NLMISC::CVector</a> &center, float halfSize=80.0f)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a03466.html">CSurfaceQuadTree</a> & </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea13">operator=</a> (const <a class="el" href="a03466.html">CSurfaceQuadTree</a> &quad)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea14">serial</a> (<a class="el" href="a02270.html">NLMISC::IStream</a> &f)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea15">translate</a> (const <a class="el" href="a03128.html">NLMISC::CVector</a> &translation)</td></tr> + +<tr><td colspan=2><br><h2>Protected Attributes</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a02156.html">NLMISC::CAABBox</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a></td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a7">uint8</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep1">_MaxLevel</a></td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>float </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep2">_MaxThickness</a></td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a03267.html">IQuadNode</a> * </td><td class="memItemRight" valign=bottom><a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a></td></tr> + +</table> +<hr><h2>Constructor & Destructor Documentation</h2> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea5" doxytag="NLPACS::CSurfaceQuadTree::CSurfaceQuadTree" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> NLPACS::CSurfaceQuadTree::CSurfaceQuadTree </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00037">37</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +References <a class="el" href="a06478.html#l00160">_MaxLevel</a>, <a class="el" href="a05385.html#l00066">NLMISC::CAABBox::setCenter()</a>, and <a class="el" href="a05385.html#l00069">NLMISC::CAABBox::setSize()</a>. +<p> +<div class="fragment"><pre>00038 { +00039 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = NULL; +00040 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep2">_MaxThickness</a> = FLT_MAX; +00041 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep1">_MaxLevel</a> = 1; +00042 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxz1902_1">setCenter</a>(CVector::Null); +00043 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxz1902_4">setSize</a>(CVector::Null); +00044 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea4" doxytag="NLPACS::CSurfaceQuadTree::CSurfaceQuadTree" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> NLPACS::CSurfaceQuadTree::CSurfaceQuadTree </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const <a class="el" href="a03466.html">CSurfaceQuadTree</a> & </td> + <td class="mdname1" valign="top" nowrap> <em>quad</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00046">46</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +<div class="fragment"><pre>00047 { +00048 *<span class="keyword">this</span> = quad; +00049 } +</pre></div> </td> + </tr> +</table> +<hr><h2>Member Function Documentation</h2> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea0" doxytag="NLPACS::CSurfaceQuadTree::addVertex" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLPACS::CSurfaceQuadTree::addVertex </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const <a class="el" href="a03128.html">NLMISC::CVector</a> & </td> + <td class="mdname1" valign="top" nowrap> <em>v</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00096">96</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +References <a class="el" href="a06478.html#l00048">NLPACS::IQuadNode::_HalfSize</a>, <a class="el" href="a06478.html#l00044">NLPACS::IQuadNode::_MaxHeight</a>, <a class="el" href="a06478.html#l00160">_MaxLevel</a>, <a class="el" href="a06478.html#l00046">NLPACS::IQuadNode::_MaxThickness</a>, <a class="el" href="a06478.html#l00044">NLPACS::IQuadNode::_MinHeight</a>, <a class="el" href="a06478.html#l00048">NLPACS::IQuadNode::_XCenter</a>, <a class="el" href="a06478.html#l00048">NLPACS::IQuadNode::_YCenter</a>, <a class="el" href="a06478.html#l00057">NLPACS::IQuadNode::addVertex()</a>, <a class="el" href="a05385.html#l00090">NLMISC::CAABBox::getCenter()</a>, <a class="el" href="a05385.html#l00091">NLMISC::CAABBox::getHalfSize()</a>, <a class="el" href="a05384.html#l00081">NLMISC::CAABBox::include()</a>, <a class="el" href="a05646.html#l00237">v</a>, <a class="el" href="a06673.html#l00051">NLMISC::CVector::x</a>, and <a class="el" href="a06673.html#l00051">NLMISC::CVector::y</a>. +<p> +Referenced by <a class="el" href="a05522.html#l00331">NLPACS::computeSurfaceQuadTree()</a>. +<p> +<div class="fragment"><pre>00097 { +00098 <span class="keywordflow">if</span> (!<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxExtz1906_2">include</a>(v)) +00099 <span class="keywordflow">return</span>; +00100 +00101 <span class="keywordflow">if</span> (<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> == NULL) +00102 { +00103 <span class="keywordflow">if</span> (<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep1">_MaxLevel</a> == 1) +00104 { +00105 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = <span class="keyword">new</span> CQuadLeaf(_MaxLevel); +00106 } +00107 <span class="keywordflow">else</span> +00108 { +00109 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = <span class="keyword">new</span> CQuadBranch(_MaxLevel); +00110 } +00111 +00112 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->_MaxThickness = <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep2">_MaxThickness</a>; +00113 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->_HalfSize = <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxz1904_1">getHalfSize</a>().x; +00114 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->_MinHeight = FLT_MAX; +00115 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->_MaxHeight = -FLT_MAX; +00116 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->_XCenter = <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxz1904_0">getCenter</a>().x; +00117 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->_YCenter = <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxz1904_0">getCenter</a>().y; +00118 } +00119 +00120 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->addVertex(v); +00121 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea1" doxytag="NLPACS::CSurfaceQuadTree::check" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> bool NLPACS::CSurfaceQuadTree::check </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const</td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00297">297</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +References <a class="el" href="a06478.html#l00078">NLPACS::IQuadNode::check()</a>. +<p> +<div class="fragment"><pre>00298 { +00299 <span class="keywordflow">if</span> (<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> != NULL) +00300 <span class="keywordflow">return</span> <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->check(); +00301 <span class="keywordflow">return</span> <span class="keyword">true</span>; +00302 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea2" doxytag="NLPACS::CSurfaceQuadTree::clear" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLPACS::CSurfaceQuadTree::clear </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00080">80</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +Referenced by <a class="el" href="a05522.html#l00331">NLPACS::computeSurfaceQuadTree()</a>, and <a class="el" href="a06477.html#l00086">init()</a>. +<p> +<div class="fragment"><pre>00081 { +00082 <span class="keyword">delete</span> <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>; +00083 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = NULL; +00084 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea3" doxytag="NLPACS::CSurfaceQuadTree::compile" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLPACS::CSurfaceQuadTree::compile </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00123">123</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +References <a class="el" href="a06478.html#l00054">NLPACS::IQuadNode::getMaxHeight()</a>, <a class="el" href="a06478.html#l00053">NLPACS::IQuadNode::getMinHeight()</a>, and <a class="el" href="a03267.html#NLPACS_1_1IQuadNodea7">NLPACS::IQuadNode::isLeaf()</a>. +<p> +Referenced by <a class="el" href="a05522.html#l00331">NLPACS::computeSurfaceQuadTree()</a>. +<p> +<div class="fragment"><pre>00124 { +00125 <span class="keywordflow">if</span> (<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> != NULL && +00126 !<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->isLeaf() && +00127 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->getMaxHeight()-<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->getMinHeight() <= <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep2">_MaxThickness</a>) +00128 { +00129 CQuadLeaf *leaf = <span class="keyword">new</span> CQuadLeaf(); +00130 *((IQuadNode *)leaf) = *<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>; +00131 <span class="keyword">delete</span> <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>; +00132 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = leaf; +00133 } +00134 <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> != NULL && +00135 !<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->isLeaf()) +00136 { +00137 ((CQuadBranch *)<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>)->reduceChildren(); +00138 } +00139 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea6" doxytag="NLPACS::CSurfaceQuadTree::getBBox" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> const <a class="el" href="a02156.html">NLMISC::CAABBox</a>& NLPACS::CSurfaceQuadTree::getBBox </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const<code> [inline]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06478.html#l00172">172</a> of file <a class="el" href="a06478.html">surface_quad.h</a>. +<p> +<div class="fragment"><pre>00172 { <span class="keywordflow">return</span> <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>; } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea7" doxytag="NLPACS::CSurfaceQuadTree::getInterpZ" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> float NLPACS::CSurfaceQuadTree::getInterpZ </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const <a class="el" href="a03128.html">NLMISC::CVector</a> & </td> + <td class="mdname1" valign="top" nowrap> <em>v</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const</td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00384">384</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +References <a class="el" href="a06478.html#l00048">NLPACS::IQuadNode::_XCenter</a>, <a class="el" href="a06478.html#l00048">NLPACS::IQuadNode::_YCenter</a>, <a class="el" href="a06478.html#l00062">NLPACS::IQuadNode::getBBox()</a>, <a class="el" href="a06478.html#l00093">NLPACS::CQuadLeaf::getChild()</a>, <a class="el" href="a03267.html#NLPACS_1_1IQuadNodea3">NLPACS::IQuadNode::getChild()</a>, <a class="el" href="a05384.html#l00081">NLMISC::CAABBox::include()</a>, <a class="el" href="a06478.html#l00092">NLPACS::CQuadLeaf::isLeaf()</a>, <a class="el" href="a03267.html#NLPACS_1_1IQuadNodea7">NLPACS::IQuadNode::isLeaf()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a05587.html#l00107">NLMISC::sqr()</a>, <a class="el" href="a05981.html#l00105">uint</a>, <a class="el" href="a05646.html#l00237">v</a>, <a class="el" href="a06673.html#l00051">NLMISC::CVector::x</a>, and <a class="el" href="a06673.html#l00051">NLMISC::CVector::y</a>. +<p> +<div class="fragment"><pre>00385 { +00386 <span class="comment">// first get final leaf for position</span> +00387 CVector pos = CVector(<a class="code" href="a04223.html#a576">v</a>.x, <a class="code" href="a04223.html#a576">v</a>.y, 0.0f); +00388 <span class="keywordflow">if</span> (<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> == NULL || !<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxExtz1906_2">include</a>(pos)) +00389 <span class="keywordflow">return</span> <a class="code" href="a04223.html#a576">v</a>.z; <span class="comment">// return unmodified z</span> +00390 +00391 <span class="keyword">const</span> IQuadNode *node = <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>; +00392 vector<uint> children; +00393 vector<const IQuadNode*> nodes; +00394 +00395 <span class="keywordflow">while</span> (node != NULL && !node->isLeaf()) +00396 { +00397 nodes.push_back(node); +00398 +00399 <a class="code" href="a04199.html#a6">nlassert</a>(node->getBBox().include(pos)); +00400 <a class="code" href="a04558.html#a15">uint</a> child; +00401 +00402 <span class="keywordflow">if</span> (pos.x > node->_XCenter) +00403 child = ((pos.y > node->_YCenter) ? 2 : 1); +00404 <span class="keywordflow">else</span> +00405 child = ((pos.y > node->_YCenter) ? 3 : 0); +00406 +00407 children.push_back(child); +00408 +00409 node = node->getChild(child); +00410 } +00411 +00412 <span class="keywordflow">if</span> (node == NULL) +00413 <span class="keywordflow">return</span> <a class="code" href="a04223.html#a576">v</a>.z; <span class="comment">// return unmodified z</span> +00414 +00415 nodes.push_back(node); +00416 +00417 vector<const CQuadLeaf*> leaves; +00418 vector<const IQuadNode*> explore; +00419 +00420 leaves.push_back((<span class="keyword">const</span> CQuadLeaf*)node); +00421 +00422 <span class="comment">// for each side of the leaf, find neighbor leaves</span> +00423 <a class="code" href="a04558.html#a15">uint</a> side; +00424 <span class="keywordflow">for</span> (side=0; side<4; ++side) +00425 { +00426 <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="a04558.html#a14">sint</a> ct[4][4] = { {-1, 1, 3,-1}, {-1,-1, 2, 0}, { 1,-1,-1, 3}, { 0, 2,-1,-1} }; <span class="comment">// child table</span> +00427 <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="a04558.html#a14">sint</a> nt[4][4] = { { 3, 1, 3, 1}, { 2, 0, 2, 0}, { 1, 3, 1, 3}, { 0, 2, 0, 2} }; <span class="comment">// neighbor table</span> +00428 +00429 <a class="code" href="a04558.html#a14">sint</a> nlev = nodes.size()-1; +00430 <a class="code" href="a04558.html#a14">sint</a> child = -1; +00431 +00432 <span class="keywordflow">while</span> (nlev > 0) +00433 { +00434 child = ct[children[nlev-1]][side]; +00435 +00436 <span class="keywordflow">if</span> (child >= 0) +00437 <span class="keywordflow">break</span>; +00438 +00439 --nlev; +00440 } +00441 +00442 <span class="comment">// neighbor not found in root, leave</span> +00443 <span class="keywordflow">if</span> (nlev == 0) +00444 <span class="keywordflow">continue</span>; +00445 +00446 <span class="comment">// get father</span> +00447 node = nodes[nlev-1]; +00448 +00449 <span class="keywordflow">while</span> (nlev < (<a class="code" href="a04558.html#a14">sint</a>)nodes.size() && node!=NULL && !node->isLeaf()) +00450 { +00451 child = nt[children[nlev-1]][side]; +00452 node = node->getChild(child); +00453 +00454 ++nlev; +00455 } +00456 +00457 <span class="keywordflow">if</span> (node == NULL) +00458 <span class="keywordflow">continue</span>; +00459 +00460 <span class="keywordflow">if</span> (node->isLeaf()) +00461 { +00462 leaves.push_back((<span class="keyword">const</span> CQuadLeaf*)node); +00463 } +00464 <span class="keywordflow">else</span> +00465 { +00466 explore.push_back(node); +00467 +00468 <span class="keywordflow">while</span> (!explore.empty()) +00469 { +00470 node = explore.back(); +00471 explore.pop_back(); +00472 +00473 <span class="keywordflow">if</span> (node == NULL) +00474 <span class="keywordflow">continue</span>; +00475 +00476 <span class="keywordflow">if</span> (node->isLeaf()) +00477 leaves.push_back((<span class="keyword">const</span> CQuadLeaf*)node); +00478 <span class="keywordflow">else</span> +00479 { +00480 explore.push_back(node->getChild((side+2)&3)); +00481 explore.push_back(node->getChild((side+3)&3)); +00482 } +00483 } +00484 } +00485 } +00486 +00487 <a class="code" href="a04558.html#a15">uint</a> i; +00488 <span class="keywordtype">float</span> di, wi; +00489 <span class="keywordtype">float</span> sum = 0.0; +00490 <span class="keywordtype">float</span> interpZ = 0.0; +00491 +00492 <span class="keywordflow">for</span> (i=0; i<leaves.size(); ++i) +00493 { +00494 di = (<span class="keywordtype">float</span>)sqrt(<a class="code" href="a05378.html#a373">sqr</a>(<a class="code" href="a04223.html#a576">v</a>.x-leaves[i]->_XCenter)+<a class="code" href="a05378.html#a373">sqr</a>(<a class="code" href="a04223.html#a576">v</a>.y-leaves[i]->_YCenter))*(<span class="keywordtype">float</span>)pow(1.5, leaves[i]->_Level); +00495 wi = 1.0f/di; +00496 sum += wi; +00497 interpZ += (leaves[i]->getMinHeight()+leaves[i]->getMaxHeight())*0.5f*wi; +00498 } +00499 +00500 <span class="keywordflow">return</span> interpZ / sum; +00501 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea8" doxytag="NLPACS::CSurfaceQuadTree::getLeaf" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> const <a class="el" href="a03288.html">NLPACS::CQuadLeaf</a> * NLPACS::CSurfaceQuadTree::getLeaf </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const <a class="el" href="a03128.html">NLMISC::CVector</a> & </td> + <td class="mdname1" valign="top" nowrap> <em>v</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const</td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00304">304</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +References <a class="el" href="a06478.html#l00048">NLPACS::IQuadNode::_XCenter</a>, <a class="el" href="a06478.html#l00048">NLPACS::IQuadNode::_YCenter</a>, <a class="el" href="a06478.html#l00062">NLPACS::IQuadNode::getBBox()</a>, <a class="el" href="a03267.html#NLPACS_1_1IQuadNodea3">NLPACS::IQuadNode::getChild()</a>, <a class="el" href="a05384.html#l00081">NLMISC::CAABBox::include()</a>, <a class="el" href="a03267.html#NLPACS_1_1IQuadNodea7">NLPACS::IQuadNode::isLeaf()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05981.html#l00105">uint</a>, <a class="el" href="a05646.html#l00237">v</a>, <a class="el" href="a06673.html#l00051">NLMISC::CVector::x</a>, and <a class="el" href="a06673.html#l00051">NLMISC::CVector::y</a>. +<p> +<div class="fragment"><pre>00305 { +00306 CVector pos = CVector(<a class="code" href="a04223.html#a576">v</a>.x, <a class="code" href="a04223.html#a576">v</a>.y, 0.0f); +00307 <span class="keywordflow">if</span> (<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> == NULL || !<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxExtz1906_2">include</a>(pos)) +00308 <span class="keywordflow">return</span> NULL; +00309 +00310 <span class="keyword">const</span> IQuadNode *node = <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>; +00311 +00312 <span class="keywordflow">while</span> (node != NULL && !node->isLeaf()) +00313 { +00314 <a class="code" href="a04199.html#a6">nlassert</a>(node->getBBox().include(pos)); +00315 <a class="code" href="a04558.html#a15">uint</a> child; +00316 +00317 <span class="keywordflow">if</span> (pos.x > node->_XCenter) +00318 child = ((pos.y > node->_YCenter) ? 2 : 1); +00319 <span class="keywordflow">else</span> +00320 child = ((pos.y > node->_YCenter) ? 3 : 0); +00321 +00322 node = node->getChild(child); +00323 } +00324 +00325 <span class="keywordflow">return</span> (<span class="keyword">const</span> CQuadLeaf *)node; +00326 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea9" doxytag="NLPACS::CSurfaceQuadTree::getMaxLevel" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a7">uint8</a> NLPACS::CSurfaceQuadTree::getMaxLevel </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const<code> [inline]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06478.html#l00171">171</a> of file <a class="el" href="a06478.html">surface_quad.h</a>. +<p> +References <a class="el" href="a06478.html#l00160">_MaxLevel</a>, and <a class="el" href="a05981.html#l00096">uint8</a>. +<p> +<div class="fragment"><pre>00171 { <span class="keywordflow">return</span> <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep1">_MaxLevel</a>; } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea10" doxytag="NLPACS::CSurfaceQuadTree::getMaxThickness" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> float NLPACS::CSurfaceQuadTree::getMaxThickness </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const<code> [inline]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06478.html#l00170">170</a> of file <a class="el" href="a06478.html">surface_quad.h</a>. +<p> +<div class="fragment"><pre>00170 { <span class="keywordflow">return</span> <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep2">_MaxThickness</a>; } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea11" doxytag="NLPACS::CSurfaceQuadTree::getRoot" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> const <a class="el" href="a03267.html">IQuadNode</a>* NLPACS::CSurfaceQuadTree::getRoot </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const<code> [inline]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06478.html#l00169">169</a> of file <a class="el" href="a06478.html">surface_quad.h</a>. +<p> +<div class="fragment"><pre>00169 { <span class="keywordflow">return</span> <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>; } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea12" doxytag="NLPACS::CSurfaceQuadTree::init" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLPACS::CSurfaceQuadTree::init </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">float </td> + <td class="mdname" nowrap> <em>maxThickness</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a15">uint</a> </td> + <td class="mdname" nowrap> <em>maxLevel</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>const <a class="el" href="a03128.html">NLMISC::CVector</a> & </td> + <td class="mdname" nowrap> <em>center</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>halfSize</em> = 80.0f</td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00086">86</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +References <a class="el" href="a06478.html#l00160">_MaxLevel</a>, <a class="el" href="a06477.html#l00080">clear()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05385.html#l00066">NLMISC::CAABBox::setCenter()</a>, <a class="el" href="a05385.html#l00067">NLMISC::CAABBox::setHalfSize()</a>, and <a class="el" href="a05981.html#l00105">uint</a>. +<p> +Referenced by <a class="el" href="a05522.html#l00331">NLPACS::computeSurfaceQuadTree()</a>. +<p> +<div class="fragment"><pre>00087 { +00088 <a class="code" href="a04199.html#a6">nlassert</a>(maxLevel > 0); +00089 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreea2">clear</a>(); +00090 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep2">_MaxThickness</a> = maxThickness; +00091 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep1">_MaxLevel</a> = maxLevel; +00092 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxz1902_1">setCenter</a>(center); +00093 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxz1902_2">setHalfSize</a>(CVector(halfSize, halfSize, 10000.0f)); +00094 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea13" doxytag="NLPACS::CSurfaceQuadTree::operator=" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> <a class="el" href="a03466.html">NLPACS::CSurfaceQuadTree</a> & NLPACS::CSurfaceQuadTree::operator= </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const <a class="el" href="a03466.html">CSurfaceQuadTree</a> & </td> + <td class="mdname1" valign="top" nowrap> <em>quad</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00051">51</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +References <a class="el" href="a06478.html#l00161">_BBox</a>, <a class="el" href="a06478.html#l00160">_MaxLevel</a>, <a class="el" href="a06478.html#l00159">_MaxThickness</a>, <a class="el" href="a06478.html#l00158">_Root</a>, and <a class="el" href="a03267.html#NLPACS_1_1IQuadNodea7">NLPACS::IQuadNode::isLeaf()</a>. +<p> +<div class="fragment"><pre>00052 { +00053 <span class="keywordflow">if</span> (&quad == <span class="keyword">this</span>) +00054 <span class="keywordflow">return</span> *<span class="keyword">this</span>; +00055 +00056 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep2">_MaxThickness</a> = quad._MaxThickness; +00057 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep1">_MaxLevel</a> = quad._MaxLevel; +00058 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a> = quad._BBox; +00059 +00060 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = NULL; +00061 <span class="keywordflow">if</span> (quad._Root != NULL) +00062 { +00063 <span class="keywordflow">if</span> (quad._Root->isLeaf()) +00064 { +00065 CQuadLeaf *newLeaf = <span class="keyword">new</span> CQuadLeaf(); +00066 *newLeaf = *((CQuadLeaf *)(quad._Root)); +00067 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = newLeaf; +00068 } +00069 <span class="keywordflow">else</span> +00070 { +00071 CQuadBranch *newBranch = <span class="keyword">new</span> CQuadBranch(); +00072 *newBranch = *((CQuadBranch *)(quad._Root)); +00073 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = newBranch; +00074 } +00075 } +00076 +00077 <span class="keywordflow">return</span> *<span class="keyword">this</span>; +00078 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea14" doxytag="NLPACS::CSurfaceQuadTree::serial" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLPACS::CSurfaceQuadTree::serial </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02270.html">NLMISC::IStream</a> & </td> + <td class="mdname1" valign="top" nowrap> <em>f</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06477.html#l00329">329</a> of file <a class="el" href="a06477.html">surface_quad.cpp</a>. +<p> +References <a class="el" href="a06478.html#l00160">_MaxLevel</a>, <a class="el" href="a03267.html#NLPACS_1_1IQuadNodea7">NLPACS::IQuadNode::isLeaf()</a>, <a class="el" href="a06463.html#l00064">NLMISC::IStream::isReading()</a>, <a class="el" href="a05622.html#l00154">nlerror</a>, <a class="el" href="a06478.html#l00080">NLPACS::IQuadNode::serial()</a>, <a class="el" href="a06477.html#l00246">NLPACS::CQuadBranch::serial()</a>, <a class="el" href="a06478.html#l00101">NLPACS::CQuadLeaf::serial()</a>, <a class="el" href="a06462.html#l00232">NLMISC::IStream::serial()</a>, <a class="el" href="a06461.html#l00266">NLMISC::IStream::serialVersion()</a>, and <a class="el" href="a05981.html#l00096">uint8</a>. +<p> +<div class="fragment"><pre>00330 { +00331 <span class="comment">/*</span> +00332 <span class="comment"> Version 0:</span> +00333 <span class="comment"> - base version.</span> +00334 <span class="comment"> */</span> +00335 (<span class="keywordtype">void</span>)f.<a class="code" href="a02270.html#NLMISC_1_1IStreamz2035_8">serialVersion</a>(0); +00336 +00337 <a class="code" href="a04558.html#a7">uint8</a> childType = 0; +00338 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(_MaxThickness); +00339 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(_MaxLevel); +00340 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(_BBox); +00341 <span class="keywordflow">if</span> (f.<a class="code" href="a02270.html#NLMISC_1_1IStreama0">isReading</a>()) +00342 { +00343 CQuadLeaf *leaf; +00344 CQuadBranch *branch; +00345 +00346 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(childType); +00347 <span class="keywordflow">switch</span> (childType) +00348 { +00349 <span class="keywordflow">case</span> CQuadBranch::NoChild: +00350 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = NULL; +00351 <span class="keywordflow">break</span>; +00352 <span class="keywordflow">case</span> CQuadBranch::LeafChild: +00353 leaf = <span class="keyword">new</span> CQuadLeaf(); +00354 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = leaf; +00355 leaf->serial(f); +00356 <span class="keywordflow">break</span>; +00357 <span class="keywordflow">case</span> CQuadBranch::BranchChild: +00358 branch = <span class="keyword">new</span> CQuadBranch(); +00359 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> = branch; +00360 branch->serial(f); +00361 <span class="keywordflow">break</span>; +00362 <span class="keywordflow">default</span>: +00363 <a class="code" href="a04199.html#a3">nlerror</a>(<span class="stringliteral">"While serializing (read) CQuadBranch: unknown child type"</span>); +00364 <span class="keywordflow">break</span>; +00365 } +00366 } +00367 <span class="keywordflow">else</span> +00368 { +00369 <span class="keywordflow">if</span> (<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> == NULL) +00370 { +00371 childType = CQuadBranch::NoChild; +00372 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(childType); +00373 } +00374 <span class="keywordflow">else</span> +00375 { +00376 childType = (<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->isLeaf()) ? CQuadBranch::LeafChild : CQuadBranch::BranchChild; +00377 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(childType); +00378 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->serial(f); +00379 } +00380 } +00381 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreea15" doxytag="NLPACS::CSurfaceQuadTree::translate" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLPACS::CSurfaceQuadTree::translate </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const <a class="el" href="a03128.html">NLMISC::CVector</a> & </td> + <td class="mdname1" valign="top" nowrap> <em>translation</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap><code> [inline]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06478.html#l00184">184</a> of file <a class="el" href="a06478.html">surface_quad.h</a>. +<p> +References <a class="el" href="a05385.html#l00090">NLMISC::CAABBox::getCenter()</a>, <a class="el" href="a05385.html#l00066">NLMISC::CAABBox::setCenter()</a>, and <a class="el" href="a06478.html#l00070">NLPACS::IQuadNode::translate()</a>. +<p> +Referenced by <a class="el" href="a06334.html#l00189">NLPACS::CRetrievableSurface::translate()</a>. +<p> +<div class="fragment"><pre>00185 { +00186 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxz1902_1">setCenter</a>(<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">_BBox</a>.<a class="code" href="a02156.html#NLMISC_1_1CAABBoxz1904_0">getCenter</a>()+translation); +00187 <span class="keywordflow">if</span> (<a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a> != NULL) +00188 <a class="code" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">_Root</a>->translate(translation); +00189 } +</pre></div> </td> + </tr> +</table> +<hr><h2>Field Documentation</h2> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreep0" doxytag="NLPACS::CSurfaceQuadTree::_BBox" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> <a class="el" href="a02156.html">NLMISC::CAABBox</a> <a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep0">NLPACS::CSurfaceQuadTree::_BBox</a><code> [protected]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06478.html#l00161">161</a> of file <a class="el" href="a06478.html">surface_quad.h</a>. +<p> +Referenced by <a class="el" href="a06477.html#l00051">operator=()</a>. </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreep1" doxytag="NLPACS::CSurfaceQuadTree::_MaxLevel" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a7">uint8</a> <a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep1">NLPACS::CSurfaceQuadTree::_MaxLevel</a><code> [protected]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06478.html#l00160">160</a> of file <a class="el" href="a06478.html">surface_quad.h</a>. +<p> +Referenced by <a class="el" href="a06477.html#l00096">addVertex()</a>, <a class="el" href="a06477.html#l00037">CSurfaceQuadTree()</a>, <a class="el" href="a06478.html#l00171">getMaxLevel()</a>, <a class="el" href="a06477.html#l00086">init()</a>, <a class="el" href="a06477.html#l00051">operator=()</a>, and <a class="el" href="a06477.html#l00329">serial()</a>. </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreep2" doxytag="NLPACS::CSurfaceQuadTree::_MaxThickness" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> float <a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep2">NLPACS::CSurfaceQuadTree::_MaxThickness</a><code> [protected]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06478.html#l00159">159</a> of file <a class="el" href="a06478.html">surface_quad.h</a>. +<p> +Referenced by <a class="el" href="a06477.html#l00051">operator=()</a>. </td> + </tr> +</table> +<a class="anchor" name="NLPACS_1_1CSurfaceQuadTreep3" doxytag="NLPACS::CSurfaceQuadTree::_Root" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> <a class="el" href="a03267.html">IQuadNode</a>* <a class="el" href="a03466.html#NLPACS_1_1CSurfaceQuadTreep3">NLPACS::CSurfaceQuadTree::_Root</a><code> [protected]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06478.html#l00158">158</a> of file <a class="el" href="a06478.html">surface_quad.h</a>. +<p> +Referenced by <a class="el" href="a06477.html#l00051">operator=()</a>. </td> + </tr> +</table> +<hr>The documentation for this class was generated from the following files:<ul> +<li><a class="el" href="a06478.html">surface_quad.h</a><li><a class="el" href="a06477.html">surface_quad.cpp</a></ul> +<hr size="1"><address style="align: right;"><small>Generated on Tue Mar 16 14:24:31 2004 for NeL by +<a href="http://www.doxygen.org/index.html"> +<img src="doxygen.png" alt="doxygen" align="middle" border=0 > +</a>1.3.6 </small></address> +</body> +</html> |