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/a03765.html | |
download | nevrax-website-self-hostable-0ea5fc66924303d1bf73ba283a383e2aadee02f2.tar.xz nevrax-website-self-hostable-0ea5fc66924303d1bf73ba283a383e2aadee02f2.zip |
Initial commit
Diffstat (limited to 'docs/doxygen/nel/a03765.html')
-rw-r--r-- | docs/doxygen/nel/a03765.html | 424 |
1 files changed, 424 insertions, 0 deletions
diff --git a/docs/doxygen/nel/a03765.html b/docs/doxygen/nel/a03765.html new file mode 100644 index 00000000..2f5c2617 --- /dev/null +++ b/docs/doxygen/nel/a03765.html @@ -0,0 +1,424 @@ +<!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: NL3D::CZoneTgtSmoother 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>NL3D::CZoneTgtSmoother Class Reference</h1><code>#include <<a class="el" href="a06783.html">zone_tgt_smoother.h</a>></code> +<p> +<hr><a name="_details"></a><h2>Detailed Description</h2> +A class used to make Vertices coplanar IN or/and across zones. <dl compact><dt><b>Author:</b></dt><dd>Lionel Berenguier <p> +Nevrax France </dd></dl> +<dl compact><dt><b>Date:</b></dt><dd>2000 </dd></dl> + +<p> + +<p> +Definition at line <a class="el" href="a06783.html#l00048">48</a> of file <a class="el" href="a06783.html">zone_tgt_smoother.h</a>.<table border=0 cellpadding=0 cellspacing=0> +<tr><td></td></tr> +<tr><td colspan=2><br><h2>Public Member Functions</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top> </td><td class="memItemRight" valign=bottom><a class="el" href="a03765.html#NL3D_1_1CZoneTgtSmoothera0">CZoneTgtSmoother</a> ()</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Constructor. <a href="#NL3D_1_1CZoneTgtSmoothera0"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a03765.html#NL3D_1_1CZoneTgtSmoothera1">makeVerticesCoplanar</a> (std::vector< <a class="el" href="a03738.html">CZoneInfo</a> > &zones)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Doit method. zones are modified. zones[0] is the center zones. Other are border zones. <a href="#NL3D_1_1CZoneTgtSmoothera1"></a><br><br></td></tr> +<tr><td colspan=2><br><h2>Private Types</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>typedef TVertexMap::iterator </td><td class="memItemRight" valign=bottom><a class="el" href="a03765.html#NL3D_1_1CZoneTgtSmoothery0">ItVertexMap</a></td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>typedef std::map< <a class="el" href="a04558.html#a14">sint</a>, <a class="el" href="a03768.html">CVertexInfo</a> > </td><td class="memItemRight" valign=bottom><a class="el" href="a03765.html#NL3D_1_1CZoneTgtSmoothery1">TVertexMap</a></td></tr> + +<tr><td colspan=2><br><h2>Private Attributes</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a03765.html#NL3D_1_1CZoneTgtSmoothery1">TVertexMap</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a03765.html#NL3D_1_1CZoneTgtSmootherr0">VertexMap</a></td></tr> + +</table> +<hr><h2>Member Typedef Documentation</h2> +<a class="anchor" name="NL3D_1_1CZoneTgtSmoothery0" doxytag="NL3D::CZoneTgtSmoother::ItVertexMap" ></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"> typedef TVertexMap::iterator <a class="el" href="a03765.html#NL3D_1_1CZoneTgtSmoothery0">NL3D::CZoneTgtSmoother::ItVertexMap</a><code> [private]</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="a06783.html#l00109">109</a> of file <a class="el" href="a06783.html">zone_tgt_smoother.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CZoneTgtSmoothery1" doxytag="NL3D::CZoneTgtSmoother::TVertexMap" ></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"> typedef std::map<<a class="el" href="a04558.html#a14">sint</a>, <a class="el" href="a03768.html">CVertexInfo</a>> <a class="el" href="a03765.html#NL3D_1_1CZoneTgtSmoothery1">NL3D::CZoneTgtSmoother::TVertexMap</a><code> [private]</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="a06783.html#l00108">108</a> of file <a class="el" href="a06783.html">zone_tgt_smoother.h</a>. </td> + </tr> +</table> +<hr><h2>Constructor & Destructor Documentation</h2> +<a class="anchor" name="NL3D_1_1CZoneTgtSmoothera0" doxytag="NL3D::CZoneTgtSmoother::CZoneTgtSmoother" ></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"> NL3D::CZoneTgtSmoother::CZoneTgtSmoother </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </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> +Constructor. +<p> + +<p> +Definition at line <a class="el" href="a06783.html#l00053">53</a> of file <a class="el" href="a06783.html">zone_tgt_smoother.h</a>. +<p> +<div class="fragment"><pre>00053 {} +</pre></div> </td> + </tr> +</table> +<hr><h2>Member Function Documentation</h2> +<a class="anchor" name="NL3D_1_1CZoneTgtSmoothera1" doxytag="NL3D::CZoneTgtSmoother::makeVerticesCoplanar" ></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 NL3D::CZoneTgtSmoother::makeVerticesCoplanar </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">std::vector< <a class="el" href="a03738.html">CZoneInfo</a> > & </td> + <td class="mdname1" valign="top" nowrap> <em>zones</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> +Doit method. zones are modified. zones[0] is the center zones. Other are border zones. +<p> + +<p> +Definition at line <a class="el" href="a06782.html#l00039">39</a> of file <a class="el" href="a06782.html">zone_tgt_smoother.cpp</a>. +<p> +References <a class="el" href="a06760.html#l00126">NL3D::CPatchInfo::BaseVertices</a>, <a class="el" href="a06760.html#l00236">NL3D::CPatchInfo::BindEdges</a>, <a class="el" href="a06760.html#l00068">NL3D::CBorderVertex::CurrentVertex</a>, <a class="el" href="a06783.html#l00078">NL3D::CZoneTgtSmoother::CTangentId::EdgeId</a>, <a class="el" href="a06760.html#l00192">NL3D::CPatchInfo::getSmoothFlag()</a>, <a class="el" href="a06783.html#l00069">NL3D::CZoneTgtSmoother::CPatchId::IdVert</a>, <a class="el" href="a05479.html#l00081">NL3D::CBezierPatch::Interiors</a>, <a class="el" href="a06760.html#l00072">NL3D::CBorderVertex::NeighborVertex</a>, <a class="el" href="a06760.html#l00070">NL3D::CBorderVertex::NeighborZoneId</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05622.html#l00111">nlinfo</a>, <a class="el" href="a06682.html#l00115">NLMISC::CVector::norm()</a>, <a class="el" href="a06783.html#l00100">NL3D::CZoneTgtSmoother::CVertexInfo::OnBorder</a>, <a class="el" href="a06760.html#l00120">NL3D::CPatchInfo::Patch</a>, <a class="el" href="a06783.html#l00067">NL3D::CZoneTgtSmoother::CPatchId::Patch</a>, <a class="el" href="a06783.html#l00077">NL3D::CZoneTgtSmoother::CTangentId::PatchId</a>, <a class="el" href="a06783.html#l00065">NL3D::CZoneTgtSmoother::CPatchId::PatchId</a>, <a class="el" href="a06783.html#l00080">NL3D::CZoneTgtSmoother::CTangentId::Patchs</a>, <a class="el" href="a06783.html#l00099">NL3D::CZoneTgtSmoother::CVertexInfo::Patchs</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a06783.html#l00082">NL3D::CZoneTgtSmoother::CTangentId::Tangent</a>, <a class="el" href="a05479.html#l00079">NL3D::CBezierPatch::Tangents</a>, <a class="el" href="a06783.html#l00076">NL3D::CZoneTgtSmoother::CTangentId::ZoneId</a>, and <a class="el" href="a06783.html#l00064">NL3D::CZoneTgtSmoother::CPatchId::ZoneId</a>. +<p> +<div class="fragment"><pre>00040 { +00041 <a class="code" href="a04558.html#a14">sint</a> i,j, numZone; +00042 <a class="code" href="a04558.html#a14">sint</a> centerZoneId; +00043 +00044 <a class="code" href="a04199.html#a6">nlassert</a>(zones.size()>=1); +00045 centerZoneId= zones[0].ZoneId; +00046 +00047 <span class="comment">// 0. CenterZone.</span> +00048 <span class="comment">//===============</span> +00049 <span class="comment">// First, make connectivity patch/vertex</span> +00050 <span class="keywordflow">for</span>(i=0;i<(<a class="code" href="a04558.html#a14">sint</a>)zones[0].Patchs.size();i++) +00051 { +00052 CPatchInfo &pa= zones[0].Patchs[i]; +00053 +00054 <span class="keywordflow">for</span>(j=0;j<4;j++) +00055 { +00056 <a class="code" href="a04558.html#a14">sint</a> vtx= pa.BaseVertices[j]; +00057 CPatchId pid; +00058 pid.ZoneId= centerZoneId; +00059 pid.PatchId= i; +00060 pid.Patch= &pa; +00061 pid.IdVert= j; +00062 <a class="code" href="a03765.html#NL3D_1_1CZoneTgtSmootherr0">VertexMap</a>[vtx].Patchs.push_back(pid); +00063 } +00064 } +00065 <span class="comment">// Second, what vertices of this zone are one border?</span> +00066 <span class="keywordflow">for</span>(i=0;i<(<a class="code" href="a04558.html#a14">sint</a>)zones[0].BorderVertices.size();i++) +00067 { +00068 CBorderVertex &bv= zones[0].BorderVertices[i]; +00069 <a class="code" href="a04558.html#a14">sint</a> vtx= bv.CurrentVertex; +00070 <a class="code" href="a03765.html#NL3D_1_1CZoneTgtSmootherr0">VertexMap</a>[vtx].OnBorder= <span class="keyword">true</span>; +00071 } +00072 +00073 <span class="comment">// 1. Neighbor zones.</span> +00074 <span class="comment">//===================</span> +00075 map<sint, sint> tempMap; +00076 <span class="keywordflow">for</span>(numZone= 1; numZone<(<a class="code" href="a04558.html#a14">sint</a>)zones.size(); numZone++) +00077 { +00078 <a class="code" href="a04558.html#a14">sint</a> adjZoneId= zones[numZone].ZoneId; +00079 +00080 tempMap.clear(); +00081 <span class="comment">// Tests which vertices points on the center zone.</span> +00082 <span class="keywordflow">for</span>(i=0;i<(<a class="code" href="a04558.html#a14">sint</a>)zones[numZone].BorderVertices.size();i++) +00083 { +00084 CBorderVertex &bv= zones[numZone].BorderVertices[i]; +00085 +00086 <span class="keywordflow">if</span>(bv.NeighborZoneId== centerZoneId) +00087 { +00088 tempMap[bv.CurrentVertex]= bv.NeighborVertex; +00089 } +00090 } +00091 <span class="comment">// Tests patchs which points on center zone.</span> +00092 <span class="keywordflow">for</span>(i=0;i<(<a class="code" href="a04558.html#a14">sint</a>)zones[numZone].Patchs.size();i++) +00093 { +00094 CPatchInfo &pa= zones[numZone].Patchs[i]; +00095 +00096 <span class="keywordflow">for</span>(j=0;j<4;j++) +00097 { +00098 <a class="code" href="a04558.html#a14">sint</a> vtx= pa.BaseVertices[j]; +00099 <span class="keywordflow">if</span>(tempMap.find(vtx)!=tempMap.end()) +00100 { +00101 CPatchId pid; +00102 pid.ZoneId= adjZoneId; +00103 pid.PatchId= i; +00104 pid.Patch= &pa; +00105 pid.IdVert= j; +00106 <span class="comment">// Fill the vertex of the center zone.</span> +00107 <a class="code" href="a03765.html#NL3D_1_1CZoneTgtSmootherr0">VertexMap</a>[tempMap[vtx]].Patchs.push_back(pid); +00108 } +00109 } +00110 } +00111 +00112 } +00113 +00114 <span class="comment">// 2. Process each vertex.</span> +00115 <span class="comment">//========================</span> +00116 <a class="code" href="a03765.html#NL3D_1_1CZoneTgtSmoothery0">ItVertexMap</a> itVert; +00117 <span class="keywordflow">for</span>(itVert= <a class="code" href="a03765.html#NL3D_1_1CZoneTgtSmootherr0">VertexMap</a>.begin(); itVert!=<a class="code" href="a03765.html#NL3D_1_1CZoneTgtSmootherr0">VertexMap</a>.end(); itVert++) +00118 { +00119 CVertexInfo &vert= itVert->second; +00120 +00121 <span class="comment">// a. verify if coplanar is possible.</span> +00122 <span class="comment">//===================================</span> +00123 +00124 <span class="comment">// \todo yoyo: later: do it too on non border vertices if wanted (with a normal threshold...).</span> +00125 <span class="keywordflow">if</span>(!vert.OnBorder) +00126 <span class="keywordflow">continue</span>; +00127 <span class="comment">// \todo yoyo: later: formula with 3, 5 ... patchs around the vertex.</span> +00128 <span class="keywordflow">if</span>(vert.Patchs.size()!=4) +00129 <span class="keywordflow">continue</span>; +00130 +00131 <span class="comment">// Test if there is no bind 1/x on this patch, around this vertex.</span> +00132 <span class="comment">// \todo yoyo: later: binds should works...</span> +00133 std::list<CPatchId>::iterator itPatch; +00134 <span class="keywordtype">bool</span> bindFound= <span class="keyword">false</span>; +00135 <span class="keywordflow">for</span>(itPatch= vert.Patchs.begin(); itPatch!= vert.Patchs.end(); itPatch++) +00136 { +00137 <span class="comment">// Tests the two edges around the vertex (before: e0, and after: e1).</span> +00138 <a class="code" href="a04558.html#a14">sint</a> e0= (itPatch->IdVert+4-1)%4; +00139 <a class="code" href="a04558.html#a14">sint</a> e1= itPatch->IdVert; +00140 +00141 <span class="keywordflow">if</span>(itPatch->Patch->BindEdges[e0].NPatchs!= 1 || itPatch->Patch->BindEdges[e1].NPatchs!= 1) +00142 { +00143 bindFound= <span class="keyword">true</span>; +00144 <span class="keywordflow">break</span>; +00145 } +00146 } +00147 <span class="keywordflow">if</span>(bindFound) +00148 <span class="keywordflow">continue</span>; +00149 +00150 +00151 +00152 <span class="comment">// b. maps patchs on tangents.</span> +00153 <span class="comment">//=========================</span> +00154 vector<CTangentId> tangents; +00155 <span class="keywordflow">for</span>(itPatch= vert.Patchs.begin(); itPatch!= vert.Patchs.end(); itPatch++) +00156 { +00157 CPatchInfo &pa= *(itPatch->Patch); +00158 <span class="comment">// The edges, before and after the veterx.</span> +00159 <a class="code" href="a04558.html#a14">sint</a> edgeNum[2]= {(itPatch->IdVert+4-1)%4, itPatch->IdVert }; +00160 <span class="comment">// The tangents, before and after the veterx.</span> +00161 <a class="code" href="a04558.html#a14">sint</a> tgtNum[2]= {(itPatch->IdVert*2+8-1)%8, itPatch->IdVert*2 }; +00162 +00163 <span class="comment">// For the 2 edges around this vertex.</span> +00164 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a14">sint</a> ed= 0; ed<2;ed++) +00165 { +00166 <a class="code" href="a04558.html#a14">sint</a> patchId, zoneId, edgeId; +00167 <a class="code" href="a04558.html#a14">sint</a> tgt; +00168 +00169 <span class="comment">// get neighbor edge id.</span> +00170 zoneId= pa.BindEdges[ edgeNum[ed] ].ZoneId; +00171 patchId= pa.BindEdges[ edgeNum[ed] ].Next[0]; +00172 edgeId= pa.BindEdges[ edgeNum[ed] ].Edge[0]; +00173 <span class="comment">// Search if tangent already inserted, mapped to this "neighbor edge".</span> +00174 <span class="keywordflow">for</span>(tgt= 0; tgt<(<a class="code" href="a04558.html#a14">sint</a>)tangents.size();tgt++) +00175 { +00176 <span class="keywordflow">if</span>(tangents[tgt].ZoneId==zoneId && tangents[tgt].PatchId==patchId && tangents[tgt].EdgeId==edgeId) +00177 <span class="keywordflow">break</span>; +00178 } +00179 <span class="comment">// If not found, add the tangent, and map ME to it.</span> +00180 <span class="keywordflow">if</span>(tgt==(<a class="code" href="a04558.html#a14">sint</a>)tangents.size()) +00181 { +00182 CTangentId tangent; +00183 <span class="comment">// Set OUR edge Id.</span> +00184 tangent.ZoneId= itPatch->ZoneId; +00185 tangent.PatchId= itPatch->PatchId; +00186 tangent.EdgeId= edgeNum[ed]; +00187 <span class="comment">// Get the tangent, before or after the vertex.</span> +00188 tangent.Tangent= pa.Patch.Tangents[ tgtNum[ed] ]; +00189 <span class="comment">// Which patchs this edge share. (0 is those which insert this tgt)</span> +00190 tangent.Patchs[0]= &pa; +00191 tangents.push_back(tangent); +00192 } +00193 <span class="keywordflow">else</span> +00194 { +00195 <span class="comment">// Which patchs this edge share. (0 is those which access this tgt)</span> +00196 tangents[tgt].Patchs[1]= &pa; +00197 } +00198 <span class="comment">// Map the patch to this tangent.</span> +00199 itPatch->Tangents[ed]= tgt; +00200 +00201 } +00202 } +00203 +00204 <span class="comment">// There should be 4 tangents.</span> +00205 <span class="keywordflow">if</span> (tangents.size()!=4) +00206 { +00207 <a class="code" href="a04199.html#a1">nlinfo</a> (<span class="stringliteral">"ERROR: vertex %d should have 4 tangents. It got %d. (MAXINDICES +1!!)"</span>, itVert->first, tangents.size()); +00208 <span class="keywordflow">continue</span>; +00209 } +00210 +00211 +00212 <span class="comment">// c. get the vertex.</span> +00213 <span class="comment">//===================</span> +00214 CVector vertexValue; +00215 itPatch= vert.Patchs.begin(); +00216 vertexValue= itPatch->Patch->Patch.Vertices[itPatch->IdVert]; +00217 +00218 +00219 <span class="comment">// d. project the tangents.</span> +00220 <span class="comment">//=========================</span> +00221 <span class="comment">// better coplanar than Max... (with orthogonal angles: use p0/p1).</span> +00222 <span class="keywordflow">for</span>(i=0;i<(<a class="code" href="a04558.html#a14">sint</a>)tangents.size();i++) +00223 { +00224 <span class="comment">// For following tangents, search the opposite.</span> +00225 <span class="comment">// Begin at i+1 so we are sure to do this only one time.</span> +00226 <span class="keywordflow">for</span>(j=i+1;j<(<a class="code" href="a04558.html#a14">sint</a>)tangents.size();j++) +00227 { +00228 <span class="keywordflow">if</span>(tangents[i].isOppositeOf(tangents[j])) +00229 { +00230 CVector &tgt0= tangents[i].Tangent; +00231 CVector &tgt1= tangents[j].Tangent; +00232 <span class="comment">// Colinear the tangents. Must keep the length of vectors.</span> +00233 <span class="keywordtype">float</span> l0= (tgt0-vertexValue).norm(); +00234 <span class="keywordtype">float</span> l1= (tgt1-vertexValue).norm(); +00235 <span class="comment">// Average the tangents. Normalize them before, to keep much as possible the orientation.</span> +00236 CVector d0= (vertexValue-tgt0).normed(); +00237 CVector d1= (tgt1-vertexValue).normed(); +00238 CVector dir= (d0+d1).normed(); +00239 +00240 <span class="comment">// Copy to tangents.</span> +00241 tgt0= vertexValue-dir*l0; +00242 tgt1= vertexValue+dir*l1; +00243 } +00244 } +00245 } +00246 +00247 +00248 <span class="comment">// e. assign tangents to patchs, rebuild interior.</span> +00249 <span class="comment">//==============================</span> +00250 <span class="keywordflow">for</span>(itPatch= vert.Patchs.begin(); itPatch!= vert.Patchs.end(); itPatch++) +00251 { +00252 CPatchInfo &pa= *(itPatch->Patch); +00253 <span class="comment">// The tangents, before and after the vertex.</span> +00254 <a class="code" href="a04558.html#a14">sint</a> tgtNum[2]= {(itPatch->IdVert*2+8-1)%8, itPatch->IdVert*2 }; +00255 <a class="code" href="a04558.html#a14">sint</a> t0= tgtNum[0]; +00256 <a class="code" href="a04558.html#a14">sint</a> t1= tgtNum[1]; +00257 <a class="code" href="a04558.html#a14">sint</a> smoothEdge0= pa.getSmoothFlag (t0/2); +00258 <a class="code" href="a04558.html#a14">sint</a> smoothEdge1= pa.getSmoothFlag (t1/2); +00259 +00260 <span class="comment">// Smooth this edge ?</span> +00261 <span class="keywordflow">if</span> (smoothEdge0) +00262 pa.Patch.Tangents[t0]= tangents[itPatch->Tangents[0]].Tangent; +00263 <span class="keywordflow">if</span> (smoothEdge1) +00264 pa.Patch.Tangents[t1]= tangents[itPatch->Tangents[1]].Tangent; +00265 +00266 <span class="comment">// Setup the coplanared interior. just the sum of 2 vector tangents.</span> +00267 <span class="keywordflow">if</span> (smoothEdge0&&smoothEdge1) +00268 pa.Patch.Interiors[itPatch->IdVert]= pa.Patch.Tangents[t0] + pa.Patch.Tangents[t1] - vertexValue; +00269 } +00270 } +00271 } +</pre></div> </td> + </tr> +</table> +<hr><h2>Field Documentation</h2> +<a class="anchor" name="NL3D_1_1CZoneTgtSmootherr0" doxytag="NL3D::CZoneTgtSmoother::VertexMap" ></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="a03765.html#NL3D_1_1CZoneTgtSmoothery1">TVertexMap</a> <a class="el" href="a03765.html#NL3D_1_1CZoneTgtSmootherr0">NL3D::CZoneTgtSmoother::VertexMap</a><code> [private]</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="a06783.html#l00112">112</a> of file <a class="el" href="a06783.html">zone_tgt_smoother.h</a>. </td> + </tr> +</table> +<hr>The documentation for this class was generated from the following files:<ul> +<li><a class="el" href="a06783.html">zone_tgt_smoother.h</a><li><a class="el" href="a06782.html">zone_tgt_smoother.cpp</a></ul> +<hr size="1"><address style="align: right;"><small>Generated on Tue Mar 16 08:36:40 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> |