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/a02901.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/a02901.html | 5416 |
1 files changed, 5416 insertions, 0 deletions
diff --git a/docs/doxygen/nel/a02901.html b/docs/doxygen/nel/a02901.html new file mode 100644 index 00000000..bc24e750 --- /dev/null +++ b/docs/doxygen/nel/a02901.html @@ -0,0 +1,5416 @@ +<!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::CMeshMRMSkinnedGeom 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::CMeshMRMSkinnedGeom Class Reference</h1><code>#include <<a class="el" href="a06012.html">mesh_mrm_skinned.h</a>></code> +<p> +<p>Inheritance diagram for NL3D::CMeshMRMSkinnedGeom: +<p><center><img src="a02901.png" usemap="#NL3D::CMeshMRMSkinnedGeom_map" border="0" alt=""></center> +<map name="NL3D::CMeshMRMSkinnedGeom_map"> +<area href="a02879.html" alt="NL3D::IMeshGeom" shape="rect" coords="0,112,197,136"> +<area href="a02867.html" alt="NLMISC::IStreamable" shape="rect" coords="0,56,197,80"> +<area href="a02540.html" alt="NLMISC::IClassable" shape="rect" coords="0,0,197,24"> +</map> +<hr><a name="_details"></a><h2>Detailed Description</h2> +An MRM mesh geometry, with no materials information.<p> +To build a <a class="el" href="a02901.html">CMeshMRMSkinnedGeom</a>, you should:<ul> +<li>build a <a class="el" href="a02864.html">CMesh::CMeshBuild</a> meshBuild (see <a class="el" href="a02857.html">CMesh</a>)</li><li>call MeshMRMGeom.build(MeshBuild);</li></ul> +<p> +NB: internally, <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeoma1">build()</a> use <a class="el" href="a02951.html">CMRMBuilder</a>, a builder of MRM.<p> +<dl compact><dt><b>Author:</b></dt><dd>Lionel Berenguier <p> +Nevrax France </dd></dl> +<dl compact><dt><b>Date:</b></dt><dd>2001 </dd></dl> + +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00090">90</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>.<table border=0 cellpadding=0 cellspacing=0> +<tr><td></td></tr> +<tr><td colspan=2><br><h2>RawSkin optimisation.</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_0">NumCacheVertexNormal1</a> = <a class="el" href="a05363.html#a134">NL_BlockByteL1</a> / sizeof(<a class="el" href="a03313.html">CRawVertexNormalSkinned1</a>)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_1">NumCacheVertexNormal2</a> = <a class="el" href="a05363.html#a134">NL_BlockByteL1</a> / sizeof(<a class="el" href="a03314.html">CRawVertexNormalSkinned2</a>)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_2">NumCacheVertexNormal3</a> = <a class="el" href="a05363.html#a134">NL_BlockByteL1</a> / sizeof(<a class="el" href="a03315.html">CRawVertexNormalSkinned3</a>)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_3">NumCacheVertexNormal4</a> = <a class="el" href="a05363.html#a134">NL_BlockByteL1</a> / sizeof(<a class="el" href="a03316.html">CRawVertexNormalSkinned4</a>)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_4">NumCacheVertexShadow</a> = <a class="el" href="a05363.html#a134">NL_BlockByteL1</a> / sizeof(<a class="el" href="a02907.html">CMeshMRMSkinnedGeom::CShadowVertex</a>)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_5">applyArrayRawSkinNormal1</a> (<a class="el" href="a03313.html">CRawVertexNormalSkinned1</a> *<a class="el" href="a04223.html#a652">src</a>, <a class="el" href="a04558.html#a7">uint8</a> *destVertexPtr, <a class="el" href="a02852.html">CMatrix3x4</a> *boneMat3x4, <a class="el" href="a04558.html#a15">uint</a> nInf)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_6">applyArrayRawSkinNormal2</a> (<a class="el" href="a03314.html">CRawVertexNormalSkinned2</a> *<a class="el" href="a04223.html#a652">src</a>, <a class="el" href="a04558.html#a7">uint8</a> *destVertexPtr, <a class="el" href="a02852.html">CMatrix3x4</a> *boneMat3x4, <a class="el" href="a04558.html#a15">uint</a> nInf)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_7">applyArrayRawSkinNormal3</a> (<a class="el" href="a03315.html">CRawVertexNormalSkinned3</a> *<a class="el" href="a04223.html#a652">src</a>, <a class="el" href="a04558.html#a7">uint8</a> *destVertexPtr, <a class="el" href="a02852.html">CMatrix3x4</a> *boneMat3x4, <a class="el" href="a04558.html#a15">uint</a> nInf)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_8">applyArrayRawSkinNormal4</a> (<a class="el" href="a03316.html">CRawVertexNormalSkinned4</a> *<a class="el" href="a04223.html#a652">src</a>, <a class="el" href="a04558.html#a7">uint8</a> *destVertexPtr, <a class="el" href="a02852.html">CMatrix3x4</a> *boneMat3x4, <a class="el" href="a04558.html#a15">uint</a> nInf)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_9">dirtMeshDataId</a> ()</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Increment the refCount, so instances RawSkins are no longer valid. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz522_9"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_10">updateRawSkinNormal</a> (bool enabled, <a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> *mi, <a class="el" href="a04558.html#a14">sint</a> curLodId)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">compute RawSkin info in the MRMInstance according to current skin setup. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz522_10"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_11">_MeshDataId</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Each time the mesh is loaded/built, this increment. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz522_11"></a><br><br></td></tr> +<tr><td colspan=2><br><h2>ShadowMap Skin rendering</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_0">applyArrayShadowSkin</a> (<a class="el" href="a02907.html">CShadowVertex</a> *<a class="el" href="a04223.html#a652">src</a>, <a class="el" href="a03128.html">CVector</a> *dst, <a class="el" href="a03399.html">CSkeletonModel</a> *skeleton, <a class="el" href="a04558.html#a15">uint</a> numVerts)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>std::vector< <a class="el" href="a04558.html#a11">uint32</a> > </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_1">_ShadowSkinTriangles</a></td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>std::vector< <a class="el" href="a02907.html">CShadowVertex</a> > </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">_ShadowSkinVertices</a></td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_3">_SupportShadowSkinGrouping</a></td></tr> + +<tr><td colspan=2><br><h2>Hard VB</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz518_0">fillAGPSkinPartWithVBHardPtr</a> (<a class="el" href="a02902.html">CLod</a> &lod, <a class="el" href="a04558.html#a7">uint8</a> *vertexDst)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz518_1">_PreciseClipping</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">NB: HERE FOR PACKING ONLY. For clipping. Estimate if we must do a Precise clipping (ie with bboxes). <a href="#NL3D_1_1CMeshMRMSkinnedGeomz518_1"></a><br><br></td></tr> +<tr><td colspan=2><br><h2>Public Types</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>enum </td><td class="memItemRight" valign=bottom><a class="el" href="a02879.html#NL3D_1_1IMeshGeomw5">TRenderFlag</a> { <br> + <a class="el" href="a02879.html#NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw2">RenderOpaqueMaterial</a> = 1, +<a class="el" href="a02879.html#NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw4">RenderTransparentMaterial</a> = 2, +<a class="el" href="a02879.html#NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw3">RenderPassOpaque</a> = 4, +<a class="el" href="a02879.html#NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw1">RenderGlobalAlpha</a> = 8, +<br> + <a class="el" href="a02879.html#NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw0">RenderGADisableZWrite</a> = 16 +<br> + }</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Render Flags, used in render. <a href="#NL3D_1_1IMeshGeomw5">More...</a><br><br></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeoma0">applyMaterialRemap</a> (const std::vector< <a class="el" href="a04558.html#a14">sint</a> > &remap)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">change materials Ids (called from <a class="el" href="a02857.html#NL3D_1_1CMesha11">CMesh::optimizeMaterialUsage()</a>) <a href="#NL3D_1_1CMeshMRMSkinnedGeoma0"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeoma1">build</a> (<a class="el" href="a02864.html">CMesh::CMeshBuild</a> &m, <a class="el" href="a04558.html#a15">uint</a> numMaxMaterial, const <a class="el" href="a02967.html">CMRMParameters</a> &<a class="el" href="a04223.html#a565">params</a>=<a class="el" href="a02967.html">CMRMParameters</a>())</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeoma2">changeMRMDistanceSetup</a> (float distanceFinest, float distanceMiddle, float distanceCoarsest)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeoma3">CMeshMRMSkinnedGeom</a> ()</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Constructor. <a href="#NL3D_1_1CMeshMRMSkinnedGeoma3"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual std::string </td><td class="memItemRight" valign=bottom><a class="el" href="a02540.html#NL3D_1_1ITrackKeyFramer_3_01CKeyVector_01_4a6">getClassName</a> ()=0</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>const <a class="el" href="a02959.html">CMRMLevelDetail</a> & </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeoma5">getLevelDetail</a> () const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">get the MRM level detail information <a href="#NL3D_1_1CMeshMRMSkinnedGeoma5"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeoma6">hasMeshVertexProgram</a> () const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">True if this mesh has a vertexProgram. <a href="#NL3D_1_1CMeshMRMSkinnedGeoma6"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeoma7">~CMeshMRMSkinnedGeom</a> ()</td></tr> + +<tr><td colspan="2"><div class="groupHeader">Mesh Block Render Interface</div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_7">isActiveInstanceNeedVBFill</a> () const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_8">isMeshInVBHeap</a> () const </td></tr> + +<tr><td colspan="2"><div class="groupHeader">Mesh Block Render Interface</div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_8">isMeshInVBHeap</a> () const </td></tr> + +<tr><td colspan="2"><div class="groupHeader">Mesh Block Render Implementation</div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz509_0">activeInstance</a> (<a class="el" href="a02887.html">CMeshGeomRenderContext</a> &rdrCtx, <a class="el" href="a02873.html">CMeshBaseInstance</a> *inst, float polygonCount, void *vbDst)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz509_1">beginMesh</a> (<a class="el" href="a02887.html">CMeshGeomRenderContext</a> &rdrCtx)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz509_2">endMesh</a> (<a class="el" href="a02887.html">CMeshGeomRenderContext</a> &rdrCtx)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual <a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz509_3">getNumRdrPassesForInstance</a> (<a class="el" href="a02873.html">CMeshBaseInstance</a> *inst) const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual <a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz509_4">getNumRdrPassesForMesh</a> () const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz509_5">renderPass</a> (<a class="el" href="a02887.html">CMeshGeomRenderContext</a> &rdrCtx, <a class="el" href="a02873.html">CMeshBaseInstance</a> *inst, float polygonCount, <a class="el" href="a04558.html#a15">uint</a> rdrPass)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz509_6">sortPerMaterial</a> () const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz509_7">supportMeshBlockRendering</a> () const </td></tr> + +<tr><td colspan="2"><div class="groupHeader">From IMeshGeom</div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_0">clip</a> (const std::vector< <a class="el" href="a03082.html">CPlane</a> > &pyramid, const <a class="el" href="a02851.html">CMatrix</a> &worldMatrix)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">clip this mesh in a driver. true if visible. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz503_0"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual float </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_1">getNumTriangles</a> (float distance)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">get an approximation of the number of triangles this instance will render for a fixed distance. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz503_1"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_2">initInstance</a> (<a class="el" href="a02873.html">CMeshBaseInstance</a> *mbi)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Init instance info. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz503_2"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_3">NLMISC_DECLARE_CLASS</a> (<a class="el" href="a02901.html">CMeshMRMSkinnedGeom</a>)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">clip this mesh in a driver. true if visible. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz503_3"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_4">profileSceneRender</a> (<a class="el" href="a03325.html">CRenderTrav</a> *rdrTrav, <a class="el" href="a02537.html">CTransformShape</a> *trans, float polygonCount, <a class="el" href="a04558.html#a11">uint32</a> rdrFlags)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Scene profile. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz503_4"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_5">render</a> (<a class="el" href="a02434.html">IDriver</a> *drv, <a class="el" href="a02537.html">CTransformShape</a> *trans, float polygonCount, <a class="el" href="a04558.html#a11">uint32</a> rdrFlags, float globalAlpha)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight"><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_5">render()</a> this mesh in a driver, given an instance and his materials. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz503_5"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_6">renderSkin</a> (<a class="el" href="a02537.html">CTransformShape</a> *trans, float alphaMRM)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight"><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_5">render()</a> this mesh as a skin <a href="#NL3D_1_1CMeshMRMSkinnedGeomz503_6"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_7">serial</a> (<a class="el" href="a02270.html">NLMISC::IStream</a> &f)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">serial this meshGeom. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz503_7"></a><br><br></td></tr> +<tr><td colspan="2"><div class="groupHeader">Skinning Behavior</div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz507_0">computeBonesId</a> (<a class="el" href="a03399.html">CSkeletonModel</a> *skeleton)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Compute skinning id. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz507_0"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>const std::vector< <a class="el" href="a02291.html">NLMISC::CBSphere</a> > & </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz507_1">getSkinBoneSphere</a> () const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">see <a class="el" href="a02316.html#NL3D_1_1CWaveMakerModelz1032_0">CTransform::getSkinBoneSphere()</a> doc for the meaning of this value. computeBonesId must has been called before. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz507_1"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>const std::vector< <a class="el" href="a04558.html#a10">sint32</a> > & </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz507_2">getSkinBoneUsage</a> () const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">return array of bones used by the skin. computeBonesId must has been called before. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz507_2"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz507_3">updateSkeletonUsage</a> (<a class="el" href="a03399.html">CSkeletonModel</a> *sm, bool increment)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">update Skeleton Usage. increment or decrement. computeBonesId must has been called before. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz507_3"></a><br><br></td></tr> +<tr><td colspan="2"><div class="groupHeader">Mesh Block Render Interface</div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void </td><td class="memItemRight" valign=bottom><a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_2">computeMeshVBHeap</a> (void *dst, <a class="el" href="a04558.html#a15">uint</a> indexStart)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_6">getVBHeapInfo</a> (<a class="el" href="a04558.html#a15">uint</a> &vertexFormat, <a class="el" href="a04558.html#a15">uint</a> &numVertices)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_7">isActiveInstanceNeedVBFill</a> () const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_8">isMeshInVBHeap</a> () const </td></tr> + +<tr><td colspan="2"><div class="groupHeader">Geometry accessors</div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>const std::vector< std::string > & </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_0">getBonesName</a> () const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">get the bone names of the meshMRM. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz505_0"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>const <a class="el" href="a02157.html">NLMISC::CAABBoxExt</a> & </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_1">getBoundingBox</a> () const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">get the extended axis aligned bounding box of the mesh <a href="#NL3D_1_1CMeshMRMSkinnedGeomz505_1"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>const std::vector< <a class="el" href="a02971.html">CMRMWedgeGeom</a> > & </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_2">getGeomorphs</a> (<a class="el" href="a04558.html#a15">uint</a> lodId) const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Advanced. get the geomorphs for a special lod. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz505_2"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_3">getNbLod</a> () const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_4">getNbRdrPass</a> (<a class="el" href="a04558.html#a15">uint</a> lodId) const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a11">uint32</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_5">getRdrPassMaterial</a> (<a class="el" href="a04558.html#a15">uint</a> lodId, <a class="el" href="a04558.html#a15">uint</a> renderingPassIndex) const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_6">getRdrPassPrimitiveBlock</a> (<a class="el" href="a04558.html#a15">uint</a> lodId, <a class="el" href="a04558.html#a15">uint</a> renderingPassIndex, <a class="el" href="a03105.html">CPrimitiveBlock</a> &block) const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_7">getSkinWeights</a> (std::vector< <a class="el" href="a02865.html">CMesh::CSkinWeight</a> > &skinWeights) const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">get the skin weight buffer <a href="#NL3D_1_1CMeshMRMSkinnedGeomz505_7"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_8">getVertexBuffer</a> (<a class="el" href="a03692.html">CVertexBuffer</a> &output) const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">get the vertex buffer used by the mrm mesh. NB: this VB store all Vertices used by All LODs. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz505_8"></a><br><br></td></tr> +<tr><td colspan="2"><div class="groupHeader">ShadowMap Skin rendering</div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz513_0">getNumShadowSkinVertices</a> () const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Get the num of shadow skin vertices. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz513_0"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a14">sint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz513_1">renderShadowSkinGeom</a> (<a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> *mi, <a class="el" href="a04558.html#a15">uint</a> remainingVertices, <a class="el" href="a04558.html#a7">uint8</a> *vbDest)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Get the num of shadow skin vertices. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz513_1"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz513_2">renderShadowSkinPrimitives</a> (<a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> *mi, <a class="el" href="a02839.html">CMaterial</a> &castMat, <a class="el" href="a02434.html">IDriver</a> *drv, <a class="el" href="a04558.html#a15">uint</a> baseVertex)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Get the num of shadow skin vertices. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz513_2"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz513_3">setShadowMesh</a> (const std::vector< <a class="el" href="a02907.html">CShadowVertex</a> > &shadowVertices, const std::vector< <a class="el" href="a04558.html#a11">uint32</a> > &triangles)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Setup the ShadowMesh. <a href="#NL3D_1_1CMeshMRMSkinnedGeomz513_3"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz513_4">supportShadowSkinGrouping</a> () const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Render the ShadowSkin (SkinGroup like). <a href="#NL3D_1_1CMeshMRMSkinnedGeomz513_4"></a><br><br></td></tr> +<tr><td colspan="2"><div class="groupHeader">Special SkinGrouping Rendering</div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a14">sint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz511_0">renderSkinGroupGeom</a> (<a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> *mi, float alphaMRM, <a class="el" href="a04558.html#a15">uint</a> remainingVertices, <a class="el" href="a04558.html#a7">uint8</a> *vbDest)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz511_1">renderSkinGroupPrimitives</a> (<a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> *mi, <a class="el" href="a04558.html#a15">uint</a> baseVertex, std::vector< <a class="el" href="a03407.html">CSkinSpecularRdrPass</a> > &specularRdrPasses, <a class="el" href="a04558.html#a15">uint</a> skinIndex)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz511_2">renderSkinGroupSpecularRdrPass</a> (<a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> *mi, <a class="el" href="a04558.html#a15">uint</a> rdrPassId)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz511_3">supportSkinGrouping</a> () const </td></tr> + +<tr><td colspan=2><br><h2>Private 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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd0">applyGeomorph</a> (std::vector< <a class="el" href="a02971.html">CMRMWedgeGeom</a> > &geoms, float alphaLod)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Apply the geomorph to the _VBuffer, or the VBhard, if exist/used. <a href="#NL3D_1_1CMeshMRMSkinnedGeomd0"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd1">applyGeomorphPosNormalUV0</a> (std::vector< <a class="el" href="a02971.html">CMRMWedgeGeom</a> > &geoms, <a class="el" href="a04558.html#a7">uint8</a> *vertexPtr, <a class="el" href="a04558.html#a7">uint8</a> *vertexDestPtr, <a class="el" href="a04558.html#a10">sint32</a> vertexSize, float a, float a1)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Faster, but common geomorph apply. <a href="#NL3D_1_1CMeshMRMSkinnedGeomd1"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd2">applyGeomorphPosNormalUV0Int</a> (std::vector< <a class="el" href="a02971.html">CMRMWedgeGeom</a> > &geoms, <a class="el" href="a04558.html#a7">uint8</a> *vertexPtr, <a class="el" href="a04558.html#a7">uint8</a> *vertexDestPtr, <a class="el" href="a04558.html#a10">sint32</a> vertexSize, <a class="el" href="a04558.html#a14">sint</a> a, <a class="el" href="a04558.html#a14">sint</a> a1)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Faster, but common geomorph apply. <a href="#NL3D_1_1CMeshMRMSkinnedGeomd2"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd3">applyGeomorphWithVBHardPtr</a> (std::vector< <a class="el" href="a02971.html">CMRMWedgeGeom</a> > &geoms, float alphaLod)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Apply the geomorph to the VBhard ptr, if not NULL. <a href="#NL3D_1_1CMeshMRMSkinnedGeomd3"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd4">applyRawSkinWithNormal</a> (<a class="el" href="a02902.html">CLod</a> &lod, <a class="el" href="a03306.html">CRawSkinnedNormalCache</a> &rawSkinLod, const <a class="el" href="a03399.html">CSkeletonModel</a> *skeleton, <a class="el" href="a04558.html#a7">uint8</a> *vbHard, float alphaLod)</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a14">sint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd5">chooseLod</a> (float alphaMRM, float &alphaLod)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">choose the lod according to the alphaMRM [0,1] given. <a href="#NL3D_1_1CMeshMRMSkinnedGeomd5"></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd6">compileRunTime</a> ()</td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd7">updateShiftedTriangleCache</a> (<a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> *mi, <a class="el" href="a04558.html#a14">sint</a> curLodId, <a class="el" href="a04558.html#a15">uint</a> baseVertex)</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="a02157.html">NLMISC::CAABBoxExt</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr0">_BBox</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">For clipping. this is the BB of all vertices of all Lods. <a href="#NL3D_1_1CMeshMRMSkinnedGeomr0"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr1">_BoneIdComputed</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">This boolean is true if the bones id have been passed in the skeleton. <a href="#NL3D_1_1CMeshMRMSkinnedGeomr1"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr2">_BoneIdExtended</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">true if the _BonesIdExt have been computed (for bone Usage). <a href="#NL3D_1_1CMeshMRMSkinnedGeomr2"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>std::vector< <a class="el" href="a04558.html#a10">sint32</a> > </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">This array give the index in the skeleton of the local bones used. computed at first computeBoneId(). <a href="#NL3D_1_1CMeshMRMSkinnedGeomr3"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>std::vector< <a class="el" href="a04558.html#a10">sint32</a> > </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr4">_BonesIdExt</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Same as _BonesId but with parent of bones added. (used for bone usage). <a href="#NL3D_1_1CMeshMRMSkinnedGeomr4"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>std::vector< std::string > </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr5">_BonesName</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">This array give the name of the local bones. <a href="#NL3D_1_1CMeshMRMSkinnedGeomr5"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>std::vector< <a class="el" href="a02291.html">NLMISC::CBSphere</a> > </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr6">_BonesSphere</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">see <a class="el" href="a02316.html#NL3D_1_1CWaveMakerModelz1032_0">CTransform::getSkinBoneSphere()</a> doc for the meaning of this value <a href="#NL3D_1_1CMeshMRMSkinnedGeomr6"></a><br><br></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr7">_LastLodComputed</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Last lod rendered. used with renderSkinGroup*() only. <a href="#NL3D_1_1CMeshMRMSkinnedGeomr7"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>std::vector< <a class="el" href="a02902.html">CLod</a> > </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">List of Lods. <a href="#NL3D_1_1CMeshMRMSkinnedGeomr8"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a02904.html">CPackedVertexBuffer</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a></td></tr> + +<tr><td colspan="2"><div class="groupHeader"></div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a02959.html">CMRMLevelDetail</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a></td></tr> + +<tr><td colspan=2><br><h2>Friends</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>class </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomn0">CMRMBuilder</a></td></tr> + +<tr><td colspan="2"><div class="groupHeader">Structures for building a MRM mesh.</div></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>class </td><td class="memItemRight" valign=bottom><a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz515_0">CLod</a></td></tr> + +</table> +<hr><h2>Member Enumeration Documentation</h2> +<a class="anchor" name="NL3D_1_1IMeshGeomw5" doxytag="NL3D::CMeshMRMSkinnedGeom::TRenderFlag" ></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"> enum <a class="el" href="a02879.html#NL3D_1_1IMeshGeomw5">NL3D::IMeshGeom::TRenderFlag</a><code> [inherited]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Render Flags, used in render. +<p> +<dl compact><dt><b>Enumeration values: </b></dt><dd> +<table border=0 cellspacing=2 cellpadding=0> +<tr><td valign=top><em><a class="anchor" name="NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw2" doxytag="RenderOpaqueMaterial" ></a>RenderOpaqueMaterial</em> </td><td> +</td></tr> +<tr><td valign=top><em><a class="anchor" name="NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw4" doxytag="RenderTransparentMaterial" ></a>RenderTransparentMaterial</em> </td><td> +</td></tr> +<tr><td valign=top><em><a class="anchor" name="NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw3" doxytag="RenderPassOpaque" ></a>RenderPassOpaque</em> </td><td> +</td></tr> +<tr><td valign=top><em><a class="anchor" name="NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw1" doxytag="RenderGlobalAlpha" ></a>RenderGlobalAlpha</em> </td><td> +</td></tr> +<tr><td valign=top><em><a class="anchor" name="NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw0" doxytag="RenderGADisableZWrite" ></a>RenderGADisableZWrite</em> </td><td> +</td></tr> +</table> +</dl> + +<p> +Definition at line <a class="el" href="a06000.html#l00082">82</a> of file <a class="el" href="a06000.html">mesh_geom.h</a>. +<p> +<div class="fragment"><pre>00083 { +00084 <a class="code" href="a02879.html#NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw2">RenderOpaqueMaterial</a>= 1, <span class="comment">// set when the mesh geom must render opaque material</span> +00085 <a class="code" href="a02879.html#NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw4">RenderTransparentMaterial</a>= 2, <span class="comment">// set when the mesh geom must render transparent material</span> +00086 <a class="code" href="a02879.html#NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw3">RenderPassOpaque</a>=4, <span class="comment">// set when the current traversal rdrPass is the opaque pass</span> +00087 <a class="code" href="a02879.html#NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw1">RenderGlobalAlpha</a>= 8, <span class="comment">// set when the caller wants to draw material with global alpha</span> +00088 <a class="code" href="a02879.html#NL3D_1_1IMeshGeomw5NL3D_1_1IMeshGeomw0">RenderGADisableZWrite</a>= 16, <span class="comment">// only when globalAlpha is used. set if must disable ZWrite</span> +00089 }; +</pre></div> </td> + </tr> +</table> +<hr><h2>Constructor & Destructor Documentation</h2> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeoma3" doxytag="NL3D::CMeshMRMSkinnedGeom::CMeshMRMSkinnedGeom" ></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::CMeshMRMSkinnedGeom::CMeshMRMSkinnedGeom </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> +Constructor. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l00171">171</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +<div class="fragment"><pre>00172 { +00173 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr1">_BoneIdComputed</a> = <span class="keyword">false</span>; +00174 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr2">_BoneIdExtended</a> = <span class="keyword">false</span>; +00175 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz518_1">_PreciseClipping</a>= <span class="keyword">false</span>; +00176 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_11">_MeshDataId</a>= 0; +00177 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_3">_SupportShadowSkinGrouping</a>= <span class="keyword">false</span>; +00178 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeoma7" doxytag="NL3D::CMeshMRMSkinnedGeom::~CMeshMRMSkinnedGeom" ></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::CMeshMRMSkinnedGeom::~<a class="el" href="a02901.html">CMeshMRMSkinnedGeom</a> </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="a06011.html#l00182">182</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +<div class="fragment"><pre>00183 { +00184 } +</pre></div> </td> + </tr> +</table> +<hr><h2>Member Function Documentation</h2> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz509_0" doxytag="NL3D::CMeshMRMSkinnedGeom::activeInstance" ></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"> virtual void NL3D::CMeshMRMSkinnedGeom::activeInstance </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02887.html">CMeshGeomRenderContext</a> & </td> + <td class="mdname" nowrap> <em>rdrCtx</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02873.html">CMeshBaseInstance</a> * </td> + <td class="mdname" nowrap> <em>inst</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>polygonCount</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>void * </td> + <td class="mdname" nowrap> <em>vbDst</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [inline, virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +The framework call this method any time a change of instance occurs. +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_0">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06012.html#l00233">233</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +<div class="fragment"><pre>00233 {}; +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_5" doxytag="NL3D::CMeshMRMSkinnedGeom::applyArrayRawSkinNormal1" ></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::CMeshMRMSkinnedGeom::applyArrayRawSkinNormal1 </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a03313.html">CRawVertexNormalSkinned1</a> * </td> + <td class="mdname" nowrap> <em>src</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>destVertexPtr</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02852.html">CMatrix3x4</a> * </td> + <td class="mdname" nowrap> <em>boneMat3x4</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>nInf</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</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="a06011.html#l02390">2390</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_6" doxytag="NL3D::CMeshMRMSkinnedGeom::applyArrayRawSkinNormal2" ></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::CMeshMRMSkinnedGeom::applyArrayRawSkinNormal2 </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a03314.html">CRawVertexNormalSkinned2</a> * </td> + <td class="mdname" nowrap> <em>src</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>destVertexPtr</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02852.html">CMatrix3x4</a> * </td> + <td class="mdname" nowrap> <em>boneMat3x4</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>nInf</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</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="a06011.html#l02569">2569</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_7" doxytag="NL3D::CMeshMRMSkinnedGeom::applyArrayRawSkinNormal3" ></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::CMeshMRMSkinnedGeom::applyArrayRawSkinNormal3 </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a03315.html">CRawVertexNormalSkinned3</a> * </td> + <td class="mdname" nowrap> <em>src</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>destVertexPtr</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02852.html">CMatrix3x4</a> * </td> + <td class="mdname" nowrap> <em>boneMat3x4</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>nInf</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</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="a06011.html#l02872">2872</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_8" doxytag="NL3D::CMeshMRMSkinnedGeom::applyArrayRawSkinNormal4" ></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::CMeshMRMSkinnedGeom::applyArrayRawSkinNormal4 </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a03316.html">CRawVertexNormalSkinned4</a> * </td> + <td class="mdname" nowrap> <em>src</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>destVertexPtr</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02852.html">CMatrix3x4</a> * </td> + <td class="mdname" nowrap> <em>boneMat3x4</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>nInf</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</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="a06011.html#l03266">3266</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz520_0" doxytag="NL3D::CMeshMRMSkinnedGeom::applyArrayShadowSkin" ></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::CMeshMRMSkinnedGeom::applyArrayShadowSkin </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02907.html">CShadowVertex</a> * </td> + <td class="mdname" nowrap> <em>src</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a03128.html">CVector</a> * </td> + <td class="mdname" nowrap> <em>dst</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a03399.html">CSkeletonModel</a> * </td> + <td class="mdname" nowrap> <em>skeleton</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>numVerts</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</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="a06011.html#l02283">2283</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06009.html#l00179">NL3D::computeBoneMatrixes3x4()</a>, <a class="el" href="a06012.html#l00362">NL3D::CMeshMRMSkinnedGeom::CLod::MatrixInfluences</a>, <a class="el" href="a05484.html#l00038">min</a>, <a class="el" href="a05646.html#l01124">src</a>, and <a class="el" href="a05981.html#l00105">uint</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01843">renderShadowSkinGeom()</a>. +<p> +<div class="fragment"><pre>02284 { +02285 <span class="comment">// For all matrix this Mesh use. (the shadow geometry cannot use other Matrix than the mesh use).</span> +02286 <span class="comment">// NB: take the best lod since the lower lods cannot use other Matrix than the higher one.</span> +02287 <span class="keyword">static</span> vector<CMatrix3x4> boneMat3x4; +02288 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz515_0">CLod</a> &lod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[_Lods.size()-1]; +02289 <a class="code" href="a05363.html#a433">computeBoneMatrixes3x4</a>(boneMat3x4, lod.MatrixInfluences, skeleton); +02290 +02291 <span class="comment">// Then do the skin</span> +02292 <span class="keywordflow">for</span>(;numVerts>0;) +02293 { +02294 <span class="comment">// number of vertices to process for this block.</span> +02295 <a class="code" href="a04558.html#a15">uint</a> nBlockInf= <a class="code" href="a04061.html#a0">min</a>(NumCacheVertexShadow, numVerts); +02296 <span class="comment">// next block.</span> +02297 numVerts-= nBlockInf; +02298 +02299 <span class="comment">// cache the data in L1 cache.</span> +02300 CFastMem::precache(src, nBlockInf * <span class="keyword">sizeof</span>(CShadowVertex)); +02301 +02302 <span class="comment">// for all InfluencedVertices only.</span> +02303 <span class="keywordflow">for</span>(;nBlockInf>0;nBlockInf--, <a class="code" href="a04223.html#a652">src</a>++, dst++) +02304 { +02305 boneMat3x4[ <a class="code" href="a04223.html#a652">src</a>->MatrixId ].mulSetPoint( <a class="code" href="a04223.html#a652">src</a>->Vertex, *dst ); +02306 } +02307 } +02308 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomd0" doxytag="NL3D::CMeshMRMSkinnedGeom::applyGeomorph" ></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::CMeshMRMSkinnedGeom::applyGeomorph </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">std::vector< <a class="el" href="a02971.html">CMRMWedgeGeom</a> > & </td> + <td class="mdname" nowrap> <em>geoms</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>alphaLod</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Apply the geomorph to the _VBuffer, or the VBhard, if exist/used. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l00410">410</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06011.html#l00417">applyGeomorphWithVBHardPtr()</a>. +<p> +Referenced by <a class="el" href="a06011.html#l00568">render()</a>. +<p> +<div class="fragment"><pre>00411 { +00412 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd3">applyGeomorphWithVBHardPtr</a>(geoms, alphaLod); +00413 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomd1" doxytag="NL3D::CMeshMRMSkinnedGeom::applyGeomorphPosNormalUV0" ></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::CMeshMRMSkinnedGeom::applyGeomorphPosNormalUV0 </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">std::vector< <a class="el" href="a02971.html">CMRMWedgeGeom</a> > & </td> + <td class="mdname" nowrap> <em>geoms</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>vertexPtr</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>vertexDestPtr</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a10">sint32</a> </td> + <td class="mdname" nowrap> <em>vertexSize</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>a</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>a1</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Faster, but common geomorph apply. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l00438">438</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06062.html#l00185">NL3D::CMRMWedgeGeom::End</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05981.html#l00099">sint32</a>, <a class="el" href="a06062.html#l00183">NL3D::CMRMWedgeGeom::Start</a>, <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a05981.html#l00096">uint8</a>. +<p> +<div class="fragment"><pre>00439 { +00440 <a class="code" href="a04199.html#a6">nlassert</a>(vertexSize==32); +00441 +00442 +00443 <span class="comment">// For all geomorphs.</span> +00444 <a class="code" href="a04558.html#a15">uint</a> nGeoms= geoms.size(); +00445 CMRMWedgeGeom *ptrGeom= &(geoms[0]); +00446 <a class="code" href="a04558.html#a7">uint8</a> *destPtr= vertexDestPtr; +00447 <span class="keywordflow">for</span>(; nGeoms>0; nGeoms--, ptrGeom++, destPtr+= vertexSize ) +00448 { +00449 <span class="comment">// Consider the Pos/Normal/UV as an array of 8 float to interpolate.</span> +00450 <span class="keywordtype">float</span> *start= (<span class="keywordtype">float</span>*)(vertexPtr + (ptrGeom->Start<<5)); +00451 <span class="keywordtype">float</span> *end= (<span class="keywordtype">float</span>*)(vertexPtr + (ptrGeom->End<<5)); +00452 <span class="keywordtype">float</span> *dst= (<span class="keywordtype">float</span>*)(destPtr); +00453 +00454 <span class="comment">// unrolled</span> +00455 dst[0]= start[0] * a + end[0]* a1; +00456 dst[1]= start[1] * a + end[1]* a1; +00457 dst[2]= start[2] * a + end[2]* a1; +00458 dst[3]= start[3] * a + end[3]* a1; +00459 dst[4]= start[4] * a + end[4]* a1; +00460 dst[5]= start[5] * a + end[5]* a1; +00461 dst[6]= start[6] * a + end[6]* a1; +00462 dst[7]= start[7] * a + end[7]* a1; +00463 } +00464 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomd2" doxytag="NL3D::CMeshMRMSkinnedGeom::applyGeomorphPosNormalUV0Int" ></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::CMeshMRMSkinnedGeom::applyGeomorphPosNormalUV0Int </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">std::vector< <a class="el" href="a02971.html">CMRMWedgeGeom</a> > & </td> + <td class="mdname" nowrap> <em>geoms</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>vertexPtr</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>vertexDestPtr</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a10">sint32</a> </td> + <td class="mdname" nowrap> <em>vertexSize</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a14">sint</a> </td> + <td class="mdname" nowrap> <em>a</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a14">sint</a> </td> + <td class="mdname" nowrap> <em>a1</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Faster, but common geomorph apply. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l00468">468</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06062.html#l00185">NL3D::CMRMWedgeGeom::End</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a05981.html#l00097">sint16</a>, <a class="el" href="a05981.html#l00099">sint32</a>, <a class="el" href="a06062.html#l00183">NL3D::CMRMWedgeGeom::Start</a>, <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a05981.html#l00096">uint8</a>. +<p> +Referenced by <a class="el" href="a06011.html#l00417">applyGeomorphWithVBHardPtr()</a>. +<p> +<div class="fragment"><pre>00469 { +00470 <span class="comment">// For all geomorphs.</span> +00471 <a class="code" href="a04558.html#a15">uint</a> nGeoms= geoms.size(); +00472 CMRMWedgeGeom *ptrGeom= &(geoms[0]); +00473 <a class="code" href="a04558.html#a7">uint8</a> *destPtr= vertexDestPtr; +00474 <span class="keywordflow">for</span>(; nGeoms>0; nGeoms--, ptrGeom++, destPtr+= vertexSize ) +00475 { +00476 <span class="comment">// Consider the Pos/Normal/UV as an array of 8 float to interpolate.</span> +00477 <a class="code" href="a04558.html#a8">sint16</a> *start= (<a class="code" href="a04558.html#a8">sint16</a>*)(vertexPtr + (ptrGeom->Start*vertexSize)); +00478 <a class="code" href="a04558.html#a8">sint16</a> *end= (<a class="code" href="a04558.html#a8">sint16</a>*)(vertexPtr + (ptrGeom->End*vertexSize)); +00479 <a class="code" href="a04558.html#a8">sint16</a> *dst= (<a class="code" href="a04558.html#a8">sint16</a>*)(destPtr); +00480 +00481 <span class="comment">/* Hulud</span> +00482 <span class="comment"> * This is slow but, we don't care because this method is called for debug purpose only (watch skin without skinning)</span> +00483 <span class="comment"> */</span> +00484 +00485 <span class="comment">// unrolled</span> +00486 dst[0]= (<a class="code" href="a04558.html#a8">sint16</a>)(((<a class="code" href="a04558.html#a14">sint</a>)(start[0]) * a + (<a class="code" href="a04558.html#a14">sint</a>)(end[0]) * a1)>>8); +00487 dst[1]= (<a class="code" href="a04558.html#a8">sint16</a>)(((<a class="code" href="a04558.html#a14">sint</a>)(start[1]) * a + (<a class="code" href="a04558.html#a14">sint</a>)(end[1]) * a1)>>8); +00488 dst[2]= (<a class="code" href="a04558.html#a8">sint16</a>)(((<a class="code" href="a04558.html#a14">sint</a>)(start[2]) * a + (<a class="code" href="a04558.html#a14">sint</a>)(end[2]) * a1)>>8); +00489 dst[3]= (<a class="code" href="a04558.html#a8">sint16</a>)(((<a class="code" href="a04558.html#a14">sint</a>)(start[3]) * a + (<a class="code" href="a04558.html#a14">sint</a>)(end[3]) * a1)>>8); +00490 dst[4]= (<a class="code" href="a04558.html#a8">sint16</a>)(((<a class="code" href="a04558.html#a14">sint</a>)(start[4]) * a + (<a class="code" href="a04558.html#a14">sint</a>)(end[4]) * a1)>>8); +00491 dst[5]= (<a class="code" href="a04558.html#a8">sint16</a>)(((<a class="code" href="a04558.html#a14">sint</a>)(start[5]) * a + (<a class="code" href="a04558.html#a14">sint</a>)(end[5]) * a1)>>8); +00492 dst[6]= (<a class="code" href="a04558.html#a8">sint16</a>)(((<a class="code" href="a04558.html#a14">sint</a>)(start[6]) * a + (<a class="code" href="a04558.html#a14">sint</a>)(end[6]) * a1)>>8); +00493 dst[7]= (<a class="code" href="a04558.html#a8">sint16</a>)(((<a class="code" href="a04558.html#a14">sint</a>)(start[7]) * a + (<a class="code" href="a04558.html#a14">sint</a>)(end[7]) * a1)>>8); +00494 } +00495 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomd3" doxytag="NL3D::CMeshMRMSkinnedGeom::applyGeomorphWithVBHardPtr" ></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::CMeshMRMSkinnedGeom::applyGeomorphWithVBHardPtr </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">std::vector< <a class="el" href="a02971.html">CMRMWedgeGeom</a> > & </td> + <td class="mdname" nowrap> <em>geoms</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>alphaLod</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Apply the geomorph to the VBhard ptr, if not NULL. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l00417">417</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06011.html#l00468">applyGeomorphPosNormalUV0Int()</a>, <a class="el" href="a05587.html#l00115">NLMISC::clamp()</a>, <a class="el" href="a06012.html#l00487">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getPackedVertices()</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a05981.html#l00099">sint32</a>, <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a05981.html#l00096">uint8</a>. +<p> +Referenced by <a class="el" href="a06011.html#l00410">applyGeomorph()</a>. +<p> +<div class="fragment"><pre>00418 { +00419 <span class="comment">// no geomorphs? quit.</span> +00420 <span class="keywordflow">if</span>(geoms.size()==0) +00421 <span class="keywordflow">return</span>; +00422 +00423 <a class="code" href="a05378.html#a374">clamp</a>(alphaLod, 0.f, 1.f); +00424 <a class="code" href="a04558.html#a14">sint</a> a= (<a class="code" href="a04558.html#a15">uint</a>)floor((256.f*alphaLod)+0.5f); +00425 <a class="code" href="a04558.html#a14">sint</a> a1= 256 - a; +00426 +00427 +00428 <span class="comment">// info from VBuffer.</span> +00429 <a class="code" href="a04558.html#a7">uint8</a> *vertexPtr= (<a class="code" href="a04558.html#a7">uint8</a>*)<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera5">getPackedVertices</a>(); +00430 <a class="code" href="a04558.html#a10">sint32</a> vertexSize= <span class="keyword">sizeof</span>(CPackedVertexBuffer::CPackedVertex); +00431 +00432 <span class="comment">// use a faster method</span> +00433 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd2">applyGeomorphPosNormalUV0Int</a>(geoms, vertexPtr, vertexPtr, vertexSize, a, a1); +00434 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeoma0" doxytag="NL3D::CMeshMRMSkinnedGeom::applyMaterialRemap" ></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::CMeshMRMSkinnedGeom::applyMaterialRemap </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::vector< <a class="el" href="a04558.html#a14">sint</a> > & </td> + <td class="mdname1" valign="top" nowrap> <em>remap</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> +change materials Ids (called from <a class="el" href="a02857.html#NL3D_1_1CMesha11">CMesh::optimizeMaterialUsage()</a>) +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l00395">395</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06012.html#l00165">getNbLod()</a>, <a class="el" href="a06012.html#l00171">getNbRdrPass()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a05981.html#l00100">uint32</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01415">NL3D::CMeshMRMSkinned::optimizeMaterialUsage()</a>. +<p> +<div class="fragment"><pre>00396 { +00397 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> lod=0;lod<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_3">getNbLod</a>();lod++) +00398 { +00399 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> rp=0;rp<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_4">getNbRdrPass</a>(lod);rp++) +00400 { +00401 <span class="comment">// remap</span> +00402 <a class="code" href="a04558.html#a11">uint32</a> &matId= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[lod].RdrPass[rp].MaterialId; +00403 <a class="code" href="a04199.html#a6">nlassert</a>(remap[matId]>=0); +00404 matId= remap[matId]; +00405 } +00406 } +00407 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomd4" doxytag="NL3D::CMeshMRMSkinnedGeom::applyRawSkinWithNormal" ></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::CMeshMRMSkinnedGeom::applyRawSkinWithNormal </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02902.html">CLod</a> & </td> + <td class="mdname" nowrap> <em>lod</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a03306.html">CRawSkinnedNormalCache</a> & </td> + <td class="mdname" nowrap> <em>rawSkinLod</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>const <a class="el" href="a03399.html">CSkeletonModel</a> * </td> + <td class="mdname" nowrap> <em>skeleton</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>vbHard</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>alphaLod</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +The same as apply skin, but with normal modified. Normal is not normalized. 4 versions from slower to faster. +<p> +Definition at line <a class="el" href="a06011.html#l03320">3320</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +Referenced by <a class="el" href="a06011.html#l00726">renderSkinGroupGeom()</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz509_1" doxytag="NL3D::CMeshMRMSkinnedGeom::beginMesh" ></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"> virtual void NL3D::CMeshMRMSkinnedGeom::beginMesh </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02887.html">CMeshGeomRenderContext</a> & </td> + <td class="mdname1" valign="top" nowrap> <em>rdrCtx</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap><code> [inline, virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +The framework call this method when he will render instances of this meshGeom soon. +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_1">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06012.html#l00232">232</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +<div class="fragment"><pre>00232 {}; +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeoma1" doxytag="NL3D::CMeshMRMSkinnedGeom::build" ></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::CMeshMRMSkinnedGeom::build </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02864.html">CMesh::CMeshBuild</a> & </td> + <td class="mdname" nowrap> <em>m</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>numMaxMaterial</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>const <a class="el" href="a02967.html">CMRMParameters</a> & </td> + <td class="mdname" nowrap> <em>params</em> = <a class="el" href="a02967.html">CMRMParameters</a>()</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> +Build a mesh, replacing old. this is much slower than <a class="el" href="a02878.html#NL3D_1_1CMeshGeoma1">CMeshGeom::build()</a>, because it computes the MRM. <dl compact><dt><b>Parameters:</b></dt><dd> + <table border="0" cellspacing="2" cellpadding="0"> + <tr><td valign=top><em>params</em> </td><td>parameters of the MRM build process.</td></tr> + </table> +</dl> + +<p> +Definition at line <a class="el" href="a06011.html#l00206">206</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06012.html#l00403">NL3D::CMeshMRMSkinnedGeom::CMeshBuildMRM::BlendShapes</a>, <a class="el" href="a05990.html#l00190">NL3D::CMesh::CMeshBuild::BonesNames</a>, <a class="el" href="a06011.html#l02018">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::build()</a>, <a class="el" href="a06012.html#l00475">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::clear()</a>, <a class="el" href="a06059.html#l00037">NL3D::CMRMLevelDetail::compileDistanceSetup()</a>, <a class="el" href="a06055.html#l02991">NL3D::CMRMBuilder::compileMRM()</a>, <a class="el" href="a06011.html#l01273">compileRunTime()</a>, <a class="el" href="a06011.html#l01560">dirtMeshDataId()</a>, <a class="el" href="a06012.html#l00412">NL3D::CMeshMRMSkinnedGeom::CMeshBuildMRM::DistanceCoarsest</a>, <a class="el" href="a06060.html#l00065">NL3D::CMRMLevelDetail::DistanceCoarsest</a>, <a class="el" href="a06012.html#l00408">NL3D::CMeshMRMSkinnedGeom::CMeshBuildMRM::DistanceFinest</a>, <a class="el" href="a06060.html#l00061">NL3D::CMRMLevelDetail::DistanceFinest</a>, <a class="el" href="a06012.html#l00410">NL3D::CMeshMRMSkinnedGeom::CMeshBuildMRM::DistanceMiddle</a>, <a class="el" href="a06060.html#l00063">NL3D::CMRMLevelDetail::DistanceMiddle</a>, <a class="el" href="a05990.html#l00193">NL3D::CMesh::CMeshBuild::Faces</a>, <a class="el" href="a06012.html#l00323">NL3D::CMeshMRMSkinnedGeom::CRdrPass::getNumTriangle()</a>, <a class="el" href="a06012.html#l00505">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getNumVertices()</a>, <a class="el" href="a06012.html#l00487">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getPackedVertices()</a>, <a class="el" href="a06012.html#l00400">NL3D::CMeshMRMSkinnedGeom::CMeshBuildMRM::Lods</a>, <a class="el" href="a05989.html#l00058">NL3D::makeBBox()</a>, <a class="el" href="a06012.html#l00432">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::Matrices</a>, <a class="el" href="a05646.html#l00243">matrix</a>, <a class="el" href="a06060.html#l00058">NL3D::CMRMLevelDetail::MaxFaceUsed</a>, <a class="el" href="a06060.html#l00056">NL3D::CMRMLevelDetail::MinFaceUsed</a>, <a class="el" href="a06012.html#l00073">NL3D_MESH_MRM_SKINNED_MAX_MATRIX</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05646.html#l00223">params</a>, <a class="el" href="a06012.html#l00355">NL3D::CMeshMRMSkinnedGeom::CLod::RdrPass</a>, <a class="el" href="a05385.html#l00181">NLMISC::CAABBoxExt::setCenter()</a>, <a class="el" href="a05385.html#l00183">NLMISC::CAABBoxExt::setSize()</a>, <a class="el" href="a06012.html#l00391">NL3D::CMeshMRMSkinnedGeom::CMeshBuildMRM::Skinned</a>, <a class="el" href="a06012.html#l00394">NL3D::CMeshMRMSkinnedGeom::CMeshBuildMRM::SkinWeights</a>, <a class="el" href="a05981.html#l00105">uint</a>, <a class="el" href="a06012.html#l00397">NL3D::CMeshMRMSkinnedGeom::CMeshBuildMRM::VBuffer</a>, <a class="el" href="a05990.html#l00184">NL3D::CMesh::CMeshBuild::Vertices</a>, and <a class="el" href="a06012.html#l00433">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::Weights</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01392">NL3D::CMeshMRMSkinned::build()</a>. +<p> +<div class="fragment"><pre>00208 { +00209 <span class="comment">// Empty geometry?</span> +00210 <span class="keywordflow">if</span>(m.Vertices.size()==0 || m.Faces.size()==0) +00211 { +00212 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera1">clear</a>(); +00213 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>.clear(); +00214 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr0">_BBox</a>.<a class="code" href="a02157.html#NLMISC_1_1CAABBoxExtz1910_1">setCenter</a>(CVector::Null); +00215 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr0">_BBox</a>.<a class="code" href="a02157.html#NLMISC_1_1CAABBoxExtz1910_4">setSize</a>(CVector::Null); +00216 <span class="keywordflow">return</span>; +00217 } +00218 <a class="code" href="a04199.html#a6">nlassert</a>(numMaxMaterial>0); +00219 +00220 +00222 <span class="comment">//======================</span> +00223 <span class="comment">// NB: this is equivalent as building BBox from MRM VBuffer, because CMRMBuilder create new vertices </span> +00224 <span class="comment">// which are just interpolation of original vertices.</span> +00225 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr0">_BBox</a>= <a class="code" href="a05363.html#a431">makeBBox</a>(m.Vertices); +00226 +00227 +00229 <span class="comment">//================================================</span> +00230 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomn0">CMRMBuilder</a> mrmBuilder; +00231 CMeshBuildMRM meshBuildMRM; +00232 std::vector<CMesh::CMeshBuild*> bsList; +00233 +00234 mrmBuilder.compileMRM(m, bsList, params, meshBuildMRM, numMaxMaterial); +00235 <a class="code" href="a04199.html#a6">nlassert</a> (meshBuildMRM.Skinned); +00236 +00237 <span class="comment">// Then build the packed vertex buffer</span> +00238 <span class="comment">//================================================</span> +00239 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera0">build</a> (meshBuildMRM.VBuffer, meshBuildMRM.SkinWeights); +00240 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>= meshBuildMRM.Lods; +00241 +00242 <span class="comment">// Compute degradation control.</span> +00243 <span class="comment">//================================================</span> +00244 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceFinest= meshBuildMRM.DistanceFinest; +00245 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceMiddle= meshBuildMRM.DistanceMiddle; +00246 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceCoarsest= meshBuildMRM.DistanceCoarsest; +00247 <a class="code" href="a04199.html#a6">nlassert</a>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceFinest>=0); +00248 <a class="code" href="a04199.html#a6">nlassert</a>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceMiddle > <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceFinest); +00249 <a class="code" href="a04199.html#a6">nlassert</a>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceCoarsest > <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceMiddle); +00250 <span class="comment">// Compute OODistDelta and DistancePow</span> +00251 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.compileDistanceSetup(); +00252 +00253 +00254 <span class="comment">// For load balancing.</span> +00255 <span class="comment">//================================================</span> +00256 <span class="comment">// compute Max Face Used</span> +00257 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.MaxFaceUsed= 0; +00258 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.MinFaceUsed= 0; +00259 <span class="comment">// Count of primitive block</span> +00260 <span class="keywordflow">if</span>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>.size()>0) +00261 { +00262 <a class="code" href="a04558.html#a15">uint</a> pb; +00263 <span class="comment">// Compute MinFaces.</span> +00264 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz515_0">CLod</a> &firstLod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[0]; +00265 <span class="keywordflow">for</span> (pb=0; pb<firstLod.RdrPass.size(); pb++) +00266 { +00267 CRdrPass &pass= firstLod.RdrPass[pb]; +00268 <span class="comment">// Sum tri</span> +00269 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.MinFaceUsed+= pass.getNumTriangle (); +00270 } +00271 <span class="comment">// Compute MaxFaces.</span> +00272 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz515_0">CLod</a> &lastLod= _Lods[_Lods.size()-1]; +00273 <span class="keywordflow">for</span> (pb=0; pb<lastLod.RdrPass.size(); pb++) +00274 { +00275 CRdrPass &pass= lastLod.RdrPass[pb]; +00276 <span class="comment">// Sum tri</span> +00277 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.MaxFaceUsed+= pass.getNumTriangle (); +00278 } +00279 } +00280 +00281 +00282 <span class="comment">// For skinning.</span> +00283 <span class="comment">//================================================</span> +00284 +00285 <span class="comment">// Inform that the mesh data has changed</span> +00286 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_9">dirtMeshDataId</a>(); +00287 +00288 +00289 <span class="comment">// For AGP SKinning optim, and for Render optim</span> +00290 <span class="comment">//================================================</span> +00291 <a class="code" href="a04558.html#a15">uint</a> i; +00292 <span class="keywordflow">for</span>(i=0;i<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>.size();i++) +00293 { +00294 <span class="comment">// sort triangles for better cache use.</span> +00295 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[i].optimizeTriangleOrder(); +00296 } +00297 +00298 <span class="comment">// No Blend Shapes</span> +00299 <span class="comment">//================================================ </span> +00300 <a class="code" href="a04199.html#a6">nlassert</a> (meshBuildMRM.BlendShapes.size() == 0); +00301 +00302 <span class="comment">// Compact bone id and build a bone id names</span> +00303 <span class="comment">//================================================ </span> +00304 +00305 <span class="comment">// Remap</span> +00306 std::map<uint, uint> remap; +00307 +00308 <span class="comment">// Current bone</span> +00309 <a class="code" href="a04558.html#a15">uint</a> currentBone = 0; +00310 +00311 <span class="comment">// Reserve memory</span> +00312 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr5">_BonesName</a>.reserve (m.BonesNames.size()); +00313 +00314 <span class="comment">// For each vertices</span> +00315 <a class="code" href="a04558.html#a15">uint</a> vert; +00316 CPackedVertexBuffer::CPackedVertex *vertices = <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera5">getPackedVertices</a>(); +00317 <span class="keywordflow">for</span> (vert=0; vert<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera3">getNumVertices</a>(); vert++) +00318 { +00319 <span class="comment">// Found one ?</span> +00320 <span class="keywordtype">bool</span> found=<span class="keyword">false</span>; +00321 +00322 <span class="comment">// For each weight</span> +00323 <a class="code" href="a04558.html#a15">uint</a> weight; +00324 <span class="keywordflow">for</span> (weight=0; weight<<a class="code" href="a04589.html#a4">NL3D_MESH_MRM_SKINNED_MAX_MATRIX</a>; weight++) +00325 { +00326 <span class="comment">// Active ?</span> +00327 <span class="keywordflow">if</span> ((vertices[vert].Weights[weight]>0)||(weight==0)) +00328 { +00329 <span class="comment">// Look for it</span> +00330 std::map<uint, uint>::iterator ite = remap.find (vertices[vert].Matrices[weight]); +00331 +00332 <span class="comment">// Find ?</span> +00333 <span class="keywordflow">if</span> (ite == remap.end()) +00334 { +00335 <span class="comment">// Insert it</span> +00336 remap.insert (std::map<uint, uint>::value_type (vertices[vert].Matrices[weight], currentBone)); +00337 +00338 <span class="comment">// Check the id</span> +00339 <a class="code" href="a04199.html#a6">nlassert</a> (vertices[vert].Matrices[weight]<m.BonesNames.size()); +00340 +00341 <span class="comment">// Set the bone name</span> +00342 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr5">_BonesName</a>.push_back (m.BonesNames[vertices[vert].Matrices[weight]]); +00343 +00344 <span class="comment">// Set the local bone id</span> +00345 vertices[vert].Matrices[weight] = currentBone++; +00346 } +00347 <span class="keywordflow">else</span> +00348 { +00349 <span class="comment">// Set the local bone id</span> +00350 vertices[vert].Matrices[weight] = ite->second; +00351 } +00352 +00353 <span class="comment">// Found one</span> +00354 found = <span class="keyword">true</span>; +00355 } +00356 } +00357 +00358 <span class="comment">// Found one ?</span> +00359 <a class="code" href="a04199.html#a6">nlassert</a> (found); +00360 } +00361 +00362 <span class="comment">// Remap the vertex influence by lods</span> +00363 <a class="code" href="a04558.html#a15">uint</a> lod; +00364 <span class="keywordflow">for</span> (lod=0; lod<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>.size(); lod++) +00365 { +00366 <span class="comment">// For each matrix used</span> +00367 <a class="code" href="a04558.html#a15">uint</a> <a class="code" href="a04223.html#a578">matrix</a>; +00368 <span class="keywordflow">for</span> (<a class="code" href="a04223.html#a578">matrix</a>=0; <a class="code" href="a04223.html#a578">matrix</a><<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[lod].MatrixInfluences.size(); <a class="code" href="a04223.html#a578">matrix</a>++) +00369 { +00370 <span class="comment">// Remap</span> +00371 std::map<uint, uint>::iterator ite = remap.find (_Lods[lod].MatrixInfluences[matrix]); +00372 +00373 <span class="comment">// Not find ?</span> +00374 <span class="keywordflow">if</span> (ite == remap.end()) +00375 { +00376 <span class="comment">// Remove it</span> +00377 _Lods[lod].MatrixInfluences.erase (_Lods[lod].MatrixInfluences.begin()+<a class="code" href="a04223.html#a578">matrix</a>); +00378 <a class="code" href="a04223.html#a578">matrix</a>--; +00379 <span class="keywordflow">continue</span>; +00380 } +00381 +00382 <span class="comment">// Remap</span> +00383 _Lods[lod].MatrixInfluences[<a class="code" href="a04223.html#a578">matrix</a>] = ite->second; +00384 } +00385 } +00386 +00387 <span class="comment">// Misc.</span> +00388 <span class="comment">//===================</span> +00389 <span class="comment">// Some runtime not serialized compilation</span> +00390 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd6">compileRunTime</a>(); +00391 +00392 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeoma2" doxytag="NL3D::CMeshMRMSkinnedGeom::changeMRMDistanceSetup" ></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::CMeshMRMSkinnedGeom::changeMRMDistanceSetup </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">float </td> + <td class="mdname" nowrap> <em>distanceFinest</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>distanceMiddle</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>distanceCoarsest</em></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> +Change MRM Distance setup. NB: no-op if distanceFinest<0, distanceMiddle<=distanceFinest or if distanceCoarsest<=distanceMiddle. <dl compact><dt><b>Parameters:</b></dt><dd> + <table border="0" cellspacing="2" cellpadding="0"> + <tr><td valign=top><em>distanceFinest</em> </td><td>The MRM has its max faces when dist<=distanceFinest. </td></tr> + <tr><td valign=top><em>distanceMiddle</em> </td><td>The MRM has 50% of its faces at dist==distanceMiddle. </td></tr> + <tr><td valign=top><em>distanceCoarsest</em> </td><td>The MRM has faces/Divisor (ie near 0) when dist>=distanceCoarsest.</td></tr> + </table> +</dl> + +<p> +Definition at line <a class="el" href="a06011.html#l00188">188</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06059.html#l00037">NL3D::CMRMLevelDetail::compileDistanceSetup()</a>, <a class="el" href="a06060.html#l00065">NL3D::CMRMLevelDetail::DistanceCoarsest</a>, <a class="el" href="a06060.html#l00061">NL3D::CMRMLevelDetail::DistanceFinest</a>, and <a class="el" href="a06060.html#l00063">NL3D::CMRMLevelDetail::DistanceMiddle</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01526">NL3D::CMeshMRMSkinned::changeMRMDistanceSetup()</a>. +<p> +<div class="fragment"><pre>00189 { +00190 <span class="comment">// check input.</span> +00191 <span class="keywordflow">if</span>(distanceFinest<0) <span class="keywordflow">return</span>; +00192 <span class="keywordflow">if</span>(distanceMiddle<=distanceFinest) <span class="keywordflow">return</span>; +00193 <span class="keywordflow">if</span>(distanceCoarsest<=distanceMiddle) <span class="keywordflow">return</span>; +00194 +00195 <span class="comment">// Change.</span> +00196 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceFinest= distanceFinest; +00197 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceMiddle= distanceMiddle; +00198 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceCoarsest= distanceCoarsest; +00199 +00200 <span class="comment">// compile </span> +00201 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.compileDistanceSetup(); +00202 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomd5" doxytag="NL3D::CMeshMRMSkinnedGeom::chooseLod" ></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#a14">sint</a> NL3D::CMeshMRMSkinnedGeom::chooseLod </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">float </td> + <td class="mdname" nowrap> <em>alphaMRM</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float & </td> + <td class="mdname" nowrap> <em>alphaLod</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [inline, private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +choose the lod according to the alphaMRM [0,1] given. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l00547">547</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a05981.html#l00104">sint</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01288">profileSceneRender()</a>, <a class="el" href="a06011.html#l00568">render()</a>, and <a class="el" href="a06011.html#l00726">renderSkinGroupGeom()</a>. +<p> +<div class="fragment"><pre>00548 { +00549 <span class="comment">// Choose what Lod to draw.</span> +00550 alphaMRM*= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>.size()-1; +00551 <a class="code" href="a04558.html#a14">sint</a> numLod= (<a class="code" href="a04558.html#a14">sint</a>)ceil(alphaMRM); +00552 <span class="keywordflow">if</span>(numLod==0) +00553 { +00554 numLod= 0; +00555 alphaLod= 0; +00556 } +00557 <span class="keywordflow">else</span> +00558 { +00559 <span class="comment">// Lerp beetween lod i-1 and lod i.</span> +00560 alphaLod= alphaMRM-(numLod-1); +00561 } +00562 +00563 <span class="keywordflow">return</span> numLod; +00564 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz503_0" doxytag="NL3D::CMeshMRMSkinnedGeom::clip" ></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 NL3D::CMeshMRMSkinnedGeom::clip </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::vector< <a class="el" href="a03082.html">CPlane</a> > & </td> + <td class="mdname" nowrap> <em>pyramid</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>const <a class="el" href="a02851.html">CMatrix</a> & </td> + <td class="mdname" nowrap> <em>worldMatrix</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +clip this mesh in a driver. true if visible. +<p> + +<p> +Reimplemented from <a class="el" href="a02879.html#NL3D_1_1IMeshGeoma0">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06011.html#l00505">505</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a05504.html#l00088">NLMISC::CBSphere::applyTransform()</a>, <a class="el" href="a05505.html#l00048">NLMISC::CBSphere::Center</a>, <a class="el" href="a05384.html#l00319">NLMISC::CAABBoxExt::clipBack()</a>, <a class="el" href="a05385.html#l00199">NLMISC::CAABBoxExt::getCenter()</a>, <a class="el" href="a05385.html#l00204">NLMISC::CAABBoxExt::getRadius()</a>, <a class="el" href="a06172.html#l00068">NLMISC::CPlane::normalize()</a>, <a class="el" href="a05505.html#l00049">NLMISC::CBSphere::Radius</a>, and <a class="el" href="a05981.html#l00104">sint</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01461">NL3D::CMeshMRMSkinned::clip()</a>. +<p> +<div class="fragment"><pre>00506 { +00507 <span class="comment">// Speed Clip: clip just the sphere.</span> +00508 <a class="code" href="a02291.html">CBSphere</a> localSphere(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr0">_BBox</a>.<a class="code" href="a02157.html#NLMISC_1_1CAABBoxExtz1912_1">getCenter</a>(), <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr0">_BBox</a>.<a class="code" href="a02157.html#NLMISC_1_1CAABBoxExtz1912_5">getRadius</a>()); +00509 <a class="code" href="a02291.html">CBSphere</a> worldSphere; +00510 +00511 <span class="comment">// transform the sphere in WorldMatrix (with nearly good scale info).</span> +00512 localSphere.<a class="code" href="a02291.html#NLMISC_1_1CBSpherez1929_0">applyTransform</a>(worldMatrix, worldSphere); +00513 +00514 <span class="comment">// if out of only plane, entirely out.</span> +00515 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a14">sint</a> i=0;i<(<a class="code" href="a04558.html#a14">sint</a>)pyramid.size();i++) +00516 { +00517 <span class="comment">// We are sure that pyramid has normalized plane normals.</span> +00518 <span class="comment">// if SpherMax OUT return false.</span> +00519 <span class="keywordtype">float</span> d= pyramid[i]*worldSphere.<a class="code" href="a02291.html#NLMISC_1_1CBSphereo0">Center</a>; +00520 <span class="keywordflow">if</span>(d>worldSphere.<a class="code" href="a02291.html#NLMISC_1_1CBSphereo1">Radius</a>) +00521 <span class="keywordflow">return</span> <span class="keyword">false</span>; +00522 } +00523 +00524 <span class="comment">// test if must do a precise clip, according to mesh size.</span> +00525 <span class="keywordflow">if</span>( <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz518_1">_PreciseClipping</a> ) +00526 { +00527 CPlane localPlane; +00528 +00529 <span class="comment">// if out of only plane, entirely out.</span> +00530 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a14">sint</a> i=0;i<(<a class="code" href="a04558.html#a14">sint</a>)pyramid.size();i++) +00531 { +00532 <span class="comment">// Transform the pyramid in Object space.</span> +00533 localPlane= pyramid[i]*worldMatrix; +00534 <span class="comment">// localPlane must be normalized, because worldMatrix mya have a scale.</span> +00535 localPlane.normalize(); +00536 <span class="comment">// if the box is not partially inside the plane, quit</span> +00537 <span class="keywordflow">if</span>( !<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr0">_BBox</a>.<a class="code" href="a02157.html#NLMISC_1_1CAABBoxExtz1914_0">clipBack</a>(localPlane) ) +00538 <span class="keywordflow">return</span> <span class="keyword">false</span>; +00539 } +00540 } +00541 +00542 <span class="keywordflow">return</span> <span class="keyword">true</span>; +00543 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomd6" doxytag="NL3D::CMeshMRMSkinnedGeom::compileRunTime" ></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::CMeshMRMSkinnedGeom::compileRunTime </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> [private]</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="a06011.html#l01273">1273</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06012.html#l00505">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getNumVertices()</a>, <a class="el" href="a05385.html#l00204">NLMISC::CAABBoxExt::getRadius()</a>, <a class="el" href="a05990.html#l00066">NL3D_MESH_PRECISE_CLIP_THRESHOLD</a>, <a class="el" href="a06330.html#l00066">NL3D_MESH_SKIN_MANAGER_MAXVERTICES</a>, <a class="el" href="a06330.html#l00076">NL3D_SHADOW_MESH_SKIN_MANAGER_MAXVERTICES</a>, <a class="el" href="a06330.html#l00075">NL3D_SHADOW_MESH_SKIN_MANAGER_VERTEXFORMAT</a>, and <a class="el" href="a05622.html#l00290">nlassert</a>. +<p> +Referenced by <a class="el" href="a06011.html#l00206">build()</a>, and <a class="el" href="a06011.html#l00991">serial()</a>. +<p> +<div class="fragment"><pre>01274 { +01275 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz518_1">_PreciseClipping</a>= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr0">_BBox</a>.<a class="code" href="a02157.html#NLMISC_1_1CAABBoxExtz1912_5">getRadius</a>() >= <a class="code" href="a04567.html#a1">NL3D_MESH_PRECISE_CLIP_THRESHOLD</a>; +01276 +01277 <span class="comment">// The Mesh must follow those restrictions, to support group skinning</span> +01278 <a class="code" href="a04199.html#a6">nlassert</a> (<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera3">getNumVertices</a>() < <a class="code" href="a04907.html#a1">NL3D_MESH_SKIN_MANAGER_MAXVERTICES</a>); +01279 +01280 <span class="comment">// Support Shadow SkinGrouping if Shadow setuped, and if not too many vertices.</span> +01281 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_3">_SupportShadowSkinGrouping</a>= !<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">_ShadowSkinVertices</a>.empty() && +01282 <a class="code" href="a04907.html#a3">NL3D_SHADOW_MESH_SKIN_MANAGER_VERTEXFORMAT</a>==CVertexBuffer::PositionFlag && +01283 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">_ShadowSkinVertices</a>.size() <= <a class="code" href="a04907.html#a4">NL3D_SHADOW_MESH_SKIN_MANAGER_MAXVERTICES</a>; +01284 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz507_0" doxytag="NL3D::CMeshMRMSkinnedGeom::computeBonesId" ></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::CMeshMRMSkinnedGeom::computeBonesId </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a03399.html">CSkeletonModel</a> * </td> + <td class="mdname1" valign="top" nowrap> <em>skeleton</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> +Compute skinning id. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l01062">1062</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06394.html#l00098">NL3D::CSkeletonModel::Bones</a>, <a class="el" href="a06393.html#l00237">NL3D::CSkeletonModel::flagBoneAndParents()</a>, <a class="el" href="a06393.html#l00629">NL3D::CSkeletonModel::getBoneIdByName()</a>, <a class="el" href="a06012.html#l00505">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getNumVertices()</a>, <a class="el" href="a06012.html#l00487">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getPackedVertices()</a>, <a class="el" href="a06012.html#l00511">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getPos()</a>, <a class="el" href="a06012.html#l00432">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::Matrices</a>, <a class="el" href="a05646.html#l00243">matrix</a>, <a class="el" href="a05990.html#l00063">NL3D_MESH_SKINNING_MAX_MATRIX</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05622.html#l00135">nlwarning</a>, <a class="el" href="a05981.html#l00099">sint32</a>, <a class="el" href="a05981.html#l00105">uint</a>, <a class="el" href="a05981.html#l00100">uint32</a>, <a class="el" href="a05646.html#l00237">v</a>, and <a class="el" href="a06012.html#l00433">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::Weights</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01514">NL3D::CMeshMRMSkinned::computeBonesId()</a>. +<p> +<div class="fragment"><pre>01063 { +01064 <span class="comment">// Already computed ?</span> +01065 <span class="keywordflow">if</span> (!<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr1">_BoneIdComputed</a>) +01066 { +01067 <span class="comment">// Get a pointer on the skeleton</span> +01068 <a class="code" href="a04199.html#a6">nlassert</a> (skeleton); +01069 <span class="keywordflow">if</span> (skeleton) +01070 { +01071 <span class="comment">// Resize boneId to the good size.</span> +01072 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a>.resize(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr5">_BonesName</a>.size()); +01073 +01074 <span class="comment">// Remap bones id table</span> +01075 std::vector<uint> remap (<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr5">_BonesName</a>.size()); +01076 +01077 <span class="comment">// **** For each bones, compute remap</span> +01078 <a class="code" href="a04558.html#a15">uint</a> bone; +01079 <span class="keywordflow">for</span> (bone=0; bone<remap.size(); bone++) +01080 { +01081 <span class="comment">// Look for the bone</span> +01082 <a class="code" href="a04558.html#a10">sint32</a> boneId = skeleton->getBoneIdByName (_BonesName[bone]); +01083 +01084 <span class="comment">// Setup the _BoneId.</span> +01085 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a>[bone]= boneId; +01086 +01087 <span class="comment">// Bones found ?</span> +01088 <span class="keywordflow">if</span> (boneId != -1) +01089 { +01090 <span class="comment">// Set the bone id</span> +01091 remap[bone] = (<a class="code" href="a04558.html#a11">uint32</a>)boneId; +01092 } +01093 <span class="keywordflow">else</span> +01094 { +01095 <span class="comment">// Put id 0</span> +01096 remap[bone] = 0; +01097 +01098 <span class="comment">// Error</span> +01099 <a class="code" href="a04199.html#a2">nlwarning</a> (<span class="stringliteral">"Bone %s not found in the skeleton."</span>, _BonesName[bone].c_str()); +01100 } +01101 } +01102 +01103 <span class="comment">// **** Remap the vertices, and compute Bone Spheres.</span> +01104 +01105 <span class="comment">// Find the Geomorph space: to process only real vertices, not geomorphed ones.</span> +01106 <a class="code" href="a04558.html#a15">uint</a> nGeomSpace= 0; +01107 <a class="code" href="a04558.html#a15">uint</a> lod; +01108 <span class="keywordflow">for</span> (lod=0; lod<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>.size(); lod++) +01109 { +01110 nGeomSpace= max(nGeomSpace, (<a class="code" href="a04558.html#a15">uint</a>)_Lods[lod].Geomorphs.size()); +01111 } +01112 +01113 <span class="comment">// Prepare Sphere compute</span> +01114 <span class="keyword">static</span> std::vector<CAABBox> boneBBoxes; +01115 <span class="keyword">static</span> std::vector<bool> boneBBEmpty; +01116 boneBBoxes.clear(); +01117 boneBBEmpty.clear(); +01118 boneBBoxes.resize(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a>.size()); +01119 boneBBEmpty.resize(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a>.size(), <span class="keyword">true</span>); +01120 +01121 +01122 <span class="comment">// Remap the vertex, and compute the bone spheres. see CTransform::getSkinBoneSphere() doc.</span> +01123 <span class="comment">// for true vertices</span> +01124 <a class="code" href="a04558.html#a15">uint</a> vert; +01125 <span class="keyword">const</span> <a class="code" href="a04558.html#a15">uint</a> vertexCount = <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera3">getNumVertices</a>(); +01126 CPackedVertexBuffer::CPackedVertex *vertices = <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera5">getPackedVertices</a>(); +01127 <span class="keywordflow">for</span> (vert=nGeomSpace; vert<vertexCount; vert++) +01128 { +01129 <span class="comment">// get the vertex position.</span> +01130 CVector vertex; +01131 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera6">getPos</a> (vertex, vertices[vert]); +01132 +01133 <span class="comment">// For each weight</span> +01134 <a class="code" href="a04558.html#a15">uint</a> weight; +01135 <span class="keywordflow">for</span> (weight=0; weight<<a class="code" href="a04567.html#a0">NL3D_MESH_SKINNING_MAX_MATRIX</a>; weight++) +01136 { +01137 <span class="comment">// Active ?</span> +01138 <span class="keywordflow">if</span> ((vertices[vert].Weights[weight]>0)||(weight==0)) +01139 { +01140 <span class="comment">// Check id</span> +01141 <a class="code" href="a04558.html#a15">uint</a> srcId= vertices[vert].Matrices[weight]; +01142 <a class="code" href="a04199.html#a6">nlassert</a> (srcId < remap.size()); +01143 <span class="comment">// remap</span> +01144 vertices[vert].Matrices[weight] = remap[srcId]; +01145 +01146 <span class="comment">// if the boneId is valid (ie found)</span> +01147 <span class="keywordflow">if</span>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a>[srcId]>=0) +01148 { +01149 <span class="comment">// transform the vertex pos in BoneSpace</span> +01150 CVector p= skeleton->Bones[<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a>[srcId]].getBoneBase().InvBindPos * vertex; +01151 <span class="comment">// extend the bone bbox.</span> +01152 <span class="keywordflow">if</span>(boneBBEmpty[srcId]) +01153 { +01154 boneBBoxes[srcId].setCenter(p); +01155 boneBBEmpty[srcId]= <span class="keyword">false</span>; +01156 } +01157 <span class="keywordflow">else</span> +01158 { +01159 boneBBoxes[srcId].extend(p); +01160 } +01161 } +01162 } +01163 <span class="keywordflow">else</span> +01164 <span class="keywordflow">break</span>; +01165 } +01166 } +01167 +01168 <span class="comment">// Compile spheres</span> +01169 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr6">_BonesSphere</a>.resize(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a>.size()); +01170 <span class="keywordflow">for</span>(bone=0;bone<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr6">_BonesSphere</a>.size();bone++) +01171 { +01172 <span class="comment">// If the bone is empty, mark with -1 in the radius.</span> +01173 <span class="keywordflow">if</span>(boneBBEmpty[bone]) +01174 { +01175 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr6">_BonesSphere</a>[bone].Radius= -1; +01176 } +01177 <span class="keywordflow">else</span> +01178 { +01179 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr6">_BonesSphere</a>[bone].Center= boneBBoxes[bone].getCenter(); +01180 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr6">_BonesSphere</a>[bone].Radius= boneBBoxes[bone].getRadius(); +01181 } +01182 } +01183 +01184 <span class="comment">// **** Remap the vertex influence by lods</span> +01185 <span class="keywordflow">for</span> (lod=0; lod<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>.size(); lod++) +01186 { +01187 <span class="comment">// For each matrix used</span> +01188 <a class="code" href="a04558.html#a15">uint</a> <a class="code" href="a04223.html#a578">matrix</a>; +01189 <span class="keywordflow">for</span> (<a class="code" href="a04223.html#a578">matrix</a>=0; <a class="code" href="a04223.html#a578">matrix</a><<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[lod].MatrixInfluences.size(); <a class="code" href="a04223.html#a578">matrix</a>++) +01190 { +01191 <span class="comment">// Check</span> +01192 <a class="code" href="a04199.html#a6">nlassert</a> (_Lods[lod].MatrixInfluences[matrix]<remap.size()); +01193 +01194 <span class="comment">// Remap</span> +01195 _Lods[lod].MatrixInfluences[<a class="code" href="a04223.html#a578">matrix</a>] = remap[_Lods[lod].MatrixInfluences[<a class="code" href="a04223.html#a578">matrix</a>]]; +01196 } +01197 } +01198 +01199 <span class="comment">// **** Remap Shadow Vertices.</span> +01200 <span class="keywordflow">for</span>(vert=0;vert<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">_ShadowSkinVertices</a>.size();vert++) +01201 { +01202 CShadowVertex &<a class="code" href="a04223.html#a576">v</a>= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">_ShadowSkinVertices</a>[vert]; +01203 <span class="comment">// Check id</span> +01204 <a class="code" href="a04199.html#a6">nlassert</a> (<a class="code" href="a04223.html#a576">v</a>.MatrixId < remap.size()); +01205 <a class="code" href="a04223.html#a576">v</a>.MatrixId= remap[<a class="code" href="a04223.html#a576">v</a>.MatrixId]; +01206 } +01207 +01208 <span class="comment">// Computed</span> +01209 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr1">_BoneIdComputed</a> = <span class="keyword">true</span>; +01210 } +01211 } +01212 +01213 <span class="comment">// Already extended ?</span> +01214 <span class="keywordflow">if</span> (!<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr2">_BoneIdExtended</a>) +01215 { +01216 <a class="code" href="a04199.html#a6">nlassert</a> (skeleton); +01217 <span class="keywordflow">if</span> (skeleton) +01218 { +01219 <span class="comment">// the total bone Usage of the mesh.</span> +01220 vector<bool> boneUsage; +01221 boneUsage.resize(skeleton->Bones.size(), <span class="keyword">false</span>); +01222 +01223 <span class="comment">// for all Bones marked as valid.</span> +01224 <a class="code" href="a04558.html#a15">uint</a> i; +01225 <span class="keywordflow">for</span>(i=0; i<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a>.size(); i++) +01226 { +01227 <span class="comment">// if not a valid boneId, skip it.</span> +01228 <span class="keywordflow">if</span>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a>[i]<0) +01229 <span class="keywordflow">continue</span>; +01230 +01231 <span class="comment">// mark him and his father in boneUsage.</span> +01232 skeleton->flagBoneAndParents(_BonesId[i], boneUsage); +01233 } +01234 +01235 <span class="comment">// fill _BonesIdExt with bones of _BonesId and their parents.</span> +01236 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr4">_BonesIdExt</a>.clear(); +01237 <span class="keywordflow">for</span>(i=0; i<boneUsage.size();i++) +01238 { +01239 <span class="comment">// if the bone is used by the mesh, add it to BoneIdExt.</span> +01240 <span class="keywordflow">if</span>(boneUsage[i]) +01241 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr4">_BonesIdExt</a>.push_back(i); +01242 } +01243 +01244 } +01245 +01246 <span class="comment">// Extended</span> +01247 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr2">_BoneIdExtended</a>= <span class="keyword">true</span>; +01248 } +01249 +01250 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1IMeshGeomz457_2" doxytag="NL3D::CMeshMRMSkinnedGeom::computeMeshVBHeap" ></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"> virtual void NL3D::IMeshGeom::computeMeshVBHeap </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">void * </td> + <td class="mdname" nowrap> <em>dst</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>indexStart</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [inline, virtual, inherited]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +When the framework succes to allocate a VBHeap space, it call this method to fill this space and compute shifted Primitive block. <dl compact><dt><b>Parameters:</b></dt><dd> + <table border="0" cellspacing="2" cellpadding="0"> + <tr><td valign=top><em>the</em> </td><td>dest VertexBuffer. NB: start to fill at dst[0] </td></tr> + <tr><td valign=top><em>indexStart</em> </td><td>used to shift primitive block.</td></tr> + </table> +</dl> + +<p> +Reimplemented in <a class="el" href="a02878.html#NL3D_1_1CMeshGeomz417_2">NL3D::CMeshGeom</a>, and <a class="el" href="a02892.html#NL3D_1_1CMeshMRMGeomz475_2">NL3D::CMeshMRMGeom</a>. +<p> +Definition at line <a class="el" href="a06000.html#l00207">207</a> of file <a class="el" href="a06000.html">mesh_geom.h</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>. +<p> +Referenced by <a class="el" href="a05997.html#l00274">NL3D::CMeshBlockManager::allocateMeshVBHeap()</a>. +<p> +<div class="fragment"><pre>00207 {} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_9" doxytag="NL3D::CMeshMRMSkinnedGeom::dirtMeshDataId" ></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::CMeshMRMSkinnedGeom::dirtMeshDataId </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> [private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Increment the refCount, so instances RawSkins are no longer valid. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l01560">1560</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +Referenced by <a class="el" href="a06011.html#l00206">build()</a>, and <a class="el" href="a06011.html#l00991">serial()</a>. +<p> +<div class="fragment"><pre>01561 { +01562 <span class="comment">// see updateRawSkinNormal()</span> +01563 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_11">_MeshDataId</a>++; +01564 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz509_2" doxytag="NL3D::CMeshMRMSkinnedGeom::endMesh" ></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"> virtual void NL3D::CMeshMRMSkinnedGeom::endMesh </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02887.html">CMeshGeomRenderContext</a> & </td> + <td class="mdname1" valign="top" nowrap> <em>rdrCtx</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap><code> [inline, virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +The framework call this method when it has done with this meshGeom +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_3">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06012.html#l00235">235</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +<div class="fragment"><pre>00235 {}; +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz518_0" doxytag="NL3D::CMeshMRMSkinnedGeom::fillAGPSkinPartWithVBHardPtr" ></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::CMeshMRMSkinnedGeom::fillAGPSkinPartWithVBHardPtr </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02902.html">CLod</a> & </td> + <td class="mdname" nowrap> <em>lod</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>vertexDst</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz505_0" doxytag="NL3D::CMeshMRMSkinnedGeom::getBonesName" ></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 std::vector<std::string>& NL3D::CMeshMRMSkinnedGeom::getBonesName </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> +get the bone names of the meshMRM. +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00161">161</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +<div class="fragment"><pre>00161 {<span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr5">_BonesName</a>;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz505_1" doxytag="NL3D::CMeshMRMSkinnedGeom::getBoundingBox" ></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="a02157.html">NLMISC::CAABBoxExt</a>& NL3D::CMeshMRMSkinnedGeom::getBoundingBox </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, virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +get the extended axis aligned bounding box of the mesh +<p> + +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz455_0">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06012.html#l00148">148</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +Referenced by <a class="el" href="a06012.html#l00738">NL3D::CMeshMRMSkinned::getBoundingBox()</a>. +<p> +<div class="fragment"><pre>00149 { +00150 <span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr0">_BBox</a>; +00151 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1ITrackKeyFramer_3_01CKeyVector_01_4a6" doxytag="NL3D::CMeshMRMSkinnedGeom::getClassName" ></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"> virtual std::string NLMISC::IClassable::getClassName </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> [pure virtual, inherited]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Implemented in <a class="el" href="a02995.html#NLAIAGENT_1_1CNumericIndexz1699_0">NLAIAGENT::CNumericIndex</a>, <a class="el" href="a02145.html#NLAIAGENT_1_1VectorTypez1764_0">NLAIC::IPointerGestion</a>, <a class="el" href="a02650.html#NLAIC_1_1CIdentTypez1766_0">NLAIC::CIdentType</a>, and <a class="el" href="a02241.html#CAutomataDescz1896_0">CAutomataDesc</a>. +<p> +Referenced by <a class="el" href="a05549.html#l00091">NLMISC::CClassRegistry::checkObject()</a>, and <a class="el" href="a06525.html#l00039">NL3D::GetTextureSize()</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz505_2" doxytag="NL3D::CMeshMRMSkinnedGeom::getGeomorphs" ></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 std::vector<<a class="el" href="a02971.html">CMRMWedgeGeom</a>>& NL3D::CMeshMRMSkinnedGeom::getGeomorphs </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a15">uint</a> </td> + <td class="mdname1" valign="top" nowrap> <em>lodId</em> </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> +Advanced. get the geomorphs for a special lod. +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00195">195</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>. +<p> +<div class="fragment"><pre>00196 { +00197 <span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[lodId].Geomorphs; +00198 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeoma5" doxytag="NL3D::CMeshMRMSkinnedGeom::getLevelDetail" ></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="a02959.html">CMRMLevelDetail</a>& NL3D::CMeshMRMSkinnedGeom::getLevelDetail </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> +get the MRM level detail information +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00241">241</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00176">NL3D::CMeshMRMSkinnedInstance::getMRMLevelDetail()</a>. +<p> +<div class="fragment"><pre>00241 {<span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz505_3" doxytag="NL3D::CMeshMRMSkinnedGeom::getNbLod" ></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#a15">uint</a> NL3D::CMeshMRMSkinnedGeom::getNbLod </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> +get the number of LOD. +<p> +Definition at line <a class="el" href="a06012.html#l00165">165</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>. +<p> +Referenced by <a class="el" href="a06011.html#l00395">applyMaterialRemap()</a>, and <a class="el" href="a06012.html#l00749">NL3D::CMeshMRMSkinned::getNbLod()</a>. +<p> +<div class="fragment"><pre>00165 { <span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>.size() ; } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz505_4" doxytag="NL3D::CMeshMRMSkinnedGeom::getNbRdrPass" ></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#a15">uint</a> NL3D::CMeshMRMSkinnedGeom::getNbRdrPass </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a15">uint</a> </td> + <td class="mdname1" valign="top" nowrap> <em>lodId</em> </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> +get the number of rendering pass of a LOD. <dl compact><dt><b>Parameters:</b></dt><dd> + <table border="0" cellspacing="2" cellpadding="0"> + <tr><td valign=top><em>lodId</em> </td><td>the id of the LOD.</td></tr> + </table> +</dl> + +<p> +Definition at line <a class="el" href="a06012.html#l00171">171</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>. +<p> +Referenced by <a class="el" href="a06011.html#l00395">applyMaterialRemap()</a>, and <a class="el" href="a06012.html#l00755">NL3D::CMeshMRMSkinned::getNbRdrPass()</a>. +<p> +<div class="fragment"><pre>00171 { <span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[lodId].RdrPass.size() ; } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz509_3" doxytag="NL3D::CMeshMRMSkinnedGeom::getNumRdrPassesForInstance" ></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"> virtual <a class="el" href="a04558.html#a15">uint</a> NL3D::CMeshMRMSkinnedGeom::getNumRdrPassesForInstance </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02873.html">CMeshBaseInstance</a> * </td> + <td class="mdname1" valign="top" nowrap> <em>inst</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const<code> [inline, virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +return the number of renderPasses for this instance. Called after activateInstance() Used only if <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz509_6">sortPerMaterial()</a>) is false +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_4">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06012.html#l00231">231</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>. +<p> +<div class="fragment"><pre>00231 { <span class="keywordflow">return</span> 0; }; +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz509_4" doxytag="NL3D::CMeshMRMSkinnedGeom::getNumRdrPassesForMesh" ></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"> virtual <a class="el" href="a04558.html#a15">uint</a> NL3D::CMeshMRMSkinnedGeom::getNumRdrPassesForMesh </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, virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +return the number of renderPasses for this mesh. Used only if <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz509_6">sortPerMaterial()</a>) is true +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_5">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06012.html#l00230">230</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>. +<p> +<div class="fragment"><pre>00230 { <span class="keywordflow">return</span> 0; }; +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz513_0" doxytag="NL3D::CMeshMRMSkinnedGeom::getNumShadowSkinVertices" ></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#a15">uint</a> NL3D::CMeshMRMSkinnedGeom::getNumShadowSkinVertices </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> +Get the num of shadow skin vertices. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l01837">1837</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>. +<p> +<div class="fragment"><pre>01838 { +01839 <span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">_ShadowSkinVertices</a>.size(); +01840 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz503_1" doxytag="NL3D::CMeshMRMSkinnedGeom::getNumTriangles" ></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 NL3D::CMeshMRMSkinnedGeom::getNumTriangles </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">float </td> + <td class="mdname1" valign="top" nowrap> <em>distance</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap><code> [virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +get an approximation of the number of triangles this instance will render for a fixed distance. +<p> + +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz455_1">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06011.html#l01055">1055</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06060.html#l00082">NL3D::CMRMLevelDetail::getNumTriangles()</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01500">NL3D::CMeshMRMSkinned::getNumTriangles()</a>. +<p> +<div class="fragment"><pre>01056 { +01057 <span class="comment">// NB: this is an approximation, but this is continious.</span> +01058 <span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.getNumTriangles(distance); +01059 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz505_5" doxytag="NL3D::CMeshMRMSkinnedGeom::getRdrPassMaterial" ></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#a11">uint32</a> NL3D::CMeshMRMSkinnedGeom::getRdrPassMaterial </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a15">uint</a> </td> + <td class="mdname" nowrap> <em>lodId</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>renderingPassIndex</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"> const<code> [inline]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +get the material ID associated with a rendering pass of a LOD. <dl compact><dt><b>Parameters:</b></dt><dd> + <table border="0" cellspacing="2" cellpadding="0"> + <tr><td valign=top><em>lodId</em> </td><td>the id of the LOD. </td></tr> + <tr><td valign=top><em>renderingPassIndex</em> </td><td>the index of the rendering pass in the matrix block</td></tr> + </table> +</dl> + +<p> +Definition at line <a class="el" href="a06012.html#l00188">188</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a05981.html#l00100">uint32</a>. +<p> +Referenced by <a class="el" href="a06012.html#l00772">NL3D::CMeshMRMSkinned::getRdrPassMaterial()</a>. +<p> +<div class="fragment"><pre>00189 { +00190 <span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[lodId].RdrPass[renderingPassIndex].MaterialId ; +00191 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz505_6" doxytag="NL3D::CMeshMRMSkinnedGeom::getRdrPassPrimitiveBlock" ></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::CMeshMRMSkinnedGeom::getRdrPassPrimitiveBlock </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a15">uint</a> </td> + <td class="mdname" nowrap> <em>lodId</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>renderingPassIndex</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a03105.html">CPrimitiveBlock</a> & </td> + <td class="mdname" nowrap> <em>block</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"> const<code> [inline]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +get the primitive block associated with a rendering pass of a LOD. <dl compact><dt><b>Parameters:</b></dt><dd> + <table border="0" cellspacing="2" cellpadding="0"> + <tr><td valign=top><em>lodId</em> </td><td>the id of the LOD. </td></tr> + <tr><td valign=top><em>renderingPassIndex</em> </td><td>the index of the rendering pass</td></tr> + </table> +</dl> + +<p> +Definition at line <a class="el" href="a06012.html#l00178">178</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>. +<p> +Referenced by <a class="el" href="a06012.html#l00762">NL3D::CMeshMRMSkinned::getRdrPassPrimitiveBlock()</a>. +<p> +<div class="fragment"><pre>00179 { +00180 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[lodId].getRdrPassPrimitiveBlock(renderingPassIndex, block); +00181 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz507_1" doxytag="NL3D::CMeshMRMSkinnedGeom::getSkinBoneSphere" ></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 std::vector<<a class="el" href="a02291.html">NLMISC::CBSphere</a>>& NL3D::CMeshMRMSkinnedGeom::getSkinBoneSphere </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> +see <a class="el" href="a02316.html#NL3D_1_1CWaveMakerModelz1032_0">CTransform::getSkinBoneSphere()</a> doc for the meaning of this value. computeBonesId must has been called before. +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00216">216</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00137">NL3D::CMeshMRMSkinnedInstance::getSkinBoneSphere()</a>. +<p> +<div class="fragment"><pre>00216 {<span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr6">_BonesSphere</a>;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz507_2" doxytag="NL3D::CMeshMRMSkinnedGeom::getSkinBoneUsage" ></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 std::vector<<a class="el" href="a04558.html#a10">sint32</a>>& NL3D::CMeshMRMSkinnedGeom::getSkinBoneUsage </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> +return array of bones used by the skin. computeBonesId must has been called before. +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00213">213</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00123">NL3D::CMeshMRMSkinnedInstance::getSkinBoneUsage()</a>. +<p> +<div class="fragment"><pre>00213 {<span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">_BonesId</a>;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz505_7" doxytag="NL3D::CMeshMRMSkinnedGeom::getSkinWeights" ></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::CMeshMRMSkinnedGeom::getSkinWeights </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">std::vector< <a class="el" href="a02865.html">CMesh::CSkinWeight</a> > & </td> + <td class="mdname1" valign="top" nowrap> <em>skinWeights</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> +get the skin weight buffer +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l02107">2107</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06012.html#l00505">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getNumVertices()</a>, <a class="el" href="a06012.html#l00487">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getPackedVertices()</a>, <a class="el" href="a06012.html#l00456">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::getWeight()</a>, <a class="el" href="a06012.html#l00432">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::Matrices</a>, <a class="el" href="a06012.html#l00073">NL3D_MESH_MRM_SKINNED_MAX_MATRIX</a>, and <a class="el" href="a05981.html#l00105">uint</a>. +<p> +<div class="fragment"><pre>02108 { +02109 <span class="keyword">const</span> <a class="code" href="a04558.html#a15">uint</a> vertexCount = <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera3">getNumVertices</a>(); +02110 skinWeights.resize (vertexCount); +02111 <span class="keyword">const</span> CPackedVertexBuffer::CPackedVertex *vertices = <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera5">getPackedVertices</a>(); +02112 <a class="code" href="a04558.html#a15">uint</a> i; +02113 <span class="keywordflow">for</span> (i=0; i<vertexCount; i++) +02114 { +02115 <span class="keyword">const</span> CPackedVertexBuffer::CPackedVertex &vertex = vertices[i]; +02116 +02117 <a class="code" href="a04558.html#a15">uint</a> j; +02118 <span class="comment">// Matrices</span> +02119 <span class="keywordflow">for</span> (j=0; j<<a class="code" href="a04589.html#a4">NL3D_MESH_MRM_SKINNED_MAX_MATRIX</a>; j++) +02120 { +02121 skinWeights[i].MatrixId[j] = vertex.Matrices[j]; +02122 vertex.getWeight (skinWeights[i].Weights[j], j); +02123 } +02124 } +02125 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1IMeshGeomz457_6" doxytag="NL3D::CMeshMRMSkinnedGeom::getVBHeapInfo" ></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"> virtual bool NL3D::IMeshGeom::getVBHeapInfo </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a15">uint</a> & </td> + <td class="mdname" nowrap> <em>vertexFormat</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>numVertices</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [inline, virtual, inherited]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +The framework call this method to know if the mesh can fit in VBHeap. if yes, deriver must return mesh vertexFormat and num of vertices. +<p> +Reimplemented in <a class="el" href="a02878.html#NL3D_1_1CMeshGeomz417_6">NL3D::CMeshGeom</a>, and <a class="el" href="a02892.html#NL3D_1_1CMeshMRMGeomz475_6">NL3D::CMeshMRMGeom</a>. +<p> +Definition at line <a class="el" href="a06000.html#l00200">200</a> of file <a class="el" href="a06000.html">mesh_geom.h</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>. +<p> +Referenced by <a class="el" href="a05997.html#l00274">NL3D::CMeshBlockManager::allocateMeshVBHeap()</a>. +<p> +<div class="fragment"><pre>00200 {<span class="keywordflow">return</span> <span class="keyword">false</span>;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz505_8" doxytag="NL3D::CMeshMRMSkinnedGeom::getVertexBuffer" ></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::CMeshMRMSkinnedGeom::getVertexBuffer </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a03692.html">CVertexBuffer</a> & </td> + <td class="mdname1" valign="top" nowrap> <em>output</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> +get the vertex buffer used by the mrm mesh. NB: this VB store all Vertices used by All LODs. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l02088">2088</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06012.html#l00442">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::getNormal()</a>, <a class="el" href="a06710.html#l00449">NL3D::CVertexBuffer::getNormalCoordPointer()</a>, <a class="el" href="a06012.html#l00505">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getNumVertices()</a>, <a class="el" href="a06012.html#l00487">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getPackedVertices()</a>, <a class="el" href="a06012.html#l00511">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getPos()</a>, <a class="el" href="a06710.html#l00497">NL3D::CVertexBuffer::getTexCoordPointer()</a>, <a class="el" href="a06012.html#l00448">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::getU()</a>, <a class="el" href="a06012.html#l00452">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::getV()</a>, <a class="el" href="a06710.html#l00438">NL3D::CVertexBuffer::getVertexCoordPointer()</a>, <a class="el" href="a06710.html#l00409">NL3D::CVertexBuffer::setNumVertices()</a>, <a class="el" href="a06710.html#l00169">NL3D::CVertexBuffer::setVertexFormat()</a>, and <a class="el" href="a05981.html#l00105">uint</a>. +<p> +Referenced by <a class="el" href="a06012.html#l00744">NL3D::CMeshMRMSkinned::getVertexBuffer()</a>, and <a class="el" href="a06011.html#l00568">render()</a>. +<p> +<div class="fragment"><pre>02089 { +02090 output.setVertexFormat (CVertexBuffer::PositionFlag|CVertexBuffer::NormalFlag|CVertexBuffer::TexCoord0Flag); +02091 <span class="keyword">const</span> <a class="code" href="a04558.html#a15">uint</a> numVertices = <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera3">getNumVertices</a>(); +02092 output.setNumVertices (numVertices); +02093 <a class="code" href="a04558.html#a15">uint</a> i; +02094 <span class="keyword">const</span> CPackedVertexBuffer::CPackedVertex *vertex = <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera5">getPackedVertices</a>(); +02095 <span class="keywordflow">for</span> (i=0; i<numVertices; i++) +02096 { +02097 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera6">getPos</a>(*(CVector*)output.getVertexCoordPointer(i), vertex[i]); +02098 vertex[i].getNormal(*(CVector*)output.getNormalCoordPointer(i)); +02099 <span class="keywordtype">float</span> *texCoord = (<span class="keywordtype">float</span>*)output.getTexCoordPointer(i,0); +02100 vertex[i].getU(texCoord[0]); +02101 vertex[i].getV(texCoord[1]); +02102 } +02103 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeoma6" doxytag="NL3D::CMeshMRMSkinnedGeom::hasMeshVertexProgram" ></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"> virtual bool NL3D::CMeshMRMSkinnedGeom::hasMeshVertexProgram </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, virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +True if this mesh has a vertexProgram. +<p> + +<p> +Reimplemented from <a class="el" href="a02879.html#NL3D_1_1IMeshGeoma2">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06012.html#l00253">253</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00227">NL3D::CMeshMRMSkinnedInstance::initRenderFilterType()</a>. +<p> +<div class="fragment"><pre>00253 {<span class="keywordflow">return</span> <span class="keyword">false</span>;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz503_2" doxytag="NL3D::CMeshMRMSkinnedGeom::initInstance" ></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::CMeshMRMSkinnedGeom::initInstance </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02873.html">CMeshBaseInstance</a> * </td> + <td class="mdname1" valign="top" nowrap> <em>mbi</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap><code> [virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Init instance info. +<p> + +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeoma4">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06011.html#l00499">499</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01439">NL3D::CMeshMRMSkinned::createInstance()</a>. +<p> +<div class="fragment"><pre>00500 { +00501 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1IMeshGeomz457_7" doxytag="NL3D::CMeshMRMSkinnedGeom::isActiveInstanceNeedVBFill" ></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"> virtual bool NL3D::IMeshGeom::isActiveInstanceNeedVBFill </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, virtual, inherited]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Return true if the meshGeom has to Fill some Vertices at <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_0">activeInstance()</a> time if VBHeap enabled at this time, then vbDst in activeInstance(,,,vbDst) will contains the vb to write to. +<p> +Reimplemented in <a class="el" href="a02892.html#NL3D_1_1CMeshMRMGeomz475_7">NL3D::CMeshMRMGeom</a>. +<p> +Definition at line <a class="el" href="a06000.html#l00212">212</a> of file <a class="el" href="a06000.html">mesh_geom.h</a>. +<p> +Referenced by <a class="el" href="a05997.html#l00177">NL3D::CMeshBlockManager::render()</a>. +<p> +<div class="fragment"><pre>00212 {<span class="keywordflow">return</span> <span class="keyword">false</span>;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1IMeshGeomz457_8" doxytag="NL3D::CMeshMRMSkinnedGeom::isMeshInVBHeap" ></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 NL3D::IMeshGeom::isMeshInVBHeap </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, inherited]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Return true if the meshGeom has to Fill some Vertices at <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_0">activeInstance()</a> time if VBHeap enabled at this time, then vbDst in activeInstance(,,,vbDst) will contains the vb to write to. +<p> +Definition at line <a class="el" href="a06000.html#l00215">215</a> of file <a class="el" href="a06000.html">mesh_geom.h</a>. +<p> +References <a class="el" href="a06000.html#l00233">NL3D::IMeshGeom::_MeshVBHeapId</a>. +<p> +Referenced by <a class="el" href="a06005.html#l02600">NL3D::CMeshMRMGeom::profileSceneRender()</a>, and <a class="el" href="a05989.html#l01932">NL3D::CMeshGeom::profileSceneRender()</a>. +<p> +<div class="fragment"><pre>00215 {<span class="keywordflow">return</span> _MeshVBHeapId!=0;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz503_3" doxytag="NL3D::CMeshMRMSkinnedGeom::NLMISC_DECLARE_CLASS" ></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::CMeshMRMSkinnedGeom::NLMISC_DECLARE_CLASS </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02901.html">CMeshMRMSkinnedGeom</a> </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> +clip this mesh in a driver. true if visible. +<p> + </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz503_4" doxytag="NL3D::CMeshMRMSkinnedGeom::profileSceneRender" ></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::CMeshMRMSkinnedGeom::profileSceneRender </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a03325.html">CRenderTrav</a> * </td> + <td class="mdname" nowrap> <em>rdrTrav</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02537.html">CTransformShape</a> * </td> + <td class="mdname" nowrap> <em>trans</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>polygonCount</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a> </td> + <td class="mdname" nowrap> <em>rdrFlags</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Scene profile. +<p> + +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeoma5">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06011.html#l01288">1288</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06349.html#l00531">NL3D::CScene::BenchRes</a>, <a class="el" href="a06011.html#l00547">chooseLod()</a>, <a class="el" href="a06060.html#l00101">NL3D::CMRMLevelDetail::getLevelDetailFromPolyCount()</a>, <a class="el" href="a06012.html#l00323">NL3D::CMeshMRMSkinnedGeom::CRdrPass::getNumTriangle()</a>, <a class="el" href="a06349.html#l00533">NL3D::CScene::incrementProfileTriVBFormat()</a>, <a class="el" href="a06012.html#l00309">NL3D::CMeshMRMSkinnedGeom::CRdrPass::MaterialId</a>, <a class="el" href="a05994.html#l00075">NL3D::CMeshBaseInstance::Materials</a>, <a class="el" href="a06625.html#l00490">NL3D::UScene::CBenchResults::MeshMRMProfileTriVBFormat</a>, <a class="el" href="a06330.html#l00065">NL3D_MESH_SKIN_MANAGER_VERTEXFORMAT</a>, <a class="el" href="a06625.html#l00498">NL3D::UScene::CBenchResults::NumMeshMRMRdrNormal</a>, <a class="el" href="a06625.html#l00501">NL3D::UScene::CBenchResults::NumMeshMRMTriRdrNormal</a>, <a class="el" href="a06625.html#l00506">NL3D::UScene::CBenchResults::NumMeshMRMVBufferStd</a>, <a class="el" href="a06012.html#l00355">NL3D::CMeshMRMSkinnedGeom::CLod::RdrPass</a>, <a class="el" href="a06583.html#l00055">NL3D::CTraversal::Scene</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a05981.html#l00100">uint32</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01538">NL3D::CMeshMRMSkinned::profileSceneRender()</a>. +<p> +<div class="fragment"><pre>01289 { +01290 <span class="comment">// get the result of the Load Balancing.</span> +01291 <span class="keywordtype">float</span> alphaMRM= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.getLevelDetailFromPolyCount(polygonCount); +01292 +01293 <span class="comment">// choose the lod.</span> +01294 <span class="keywordtype">float</span> alphaLod; +01295 <a class="code" href="a04558.html#a14">sint</a> numLod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd5">chooseLod</a>(alphaMRM, alphaLod); +01296 +01297 <span class="comment">// Render the choosen Lod.</span> +01298 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz515_0">CLod</a> &lod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[numLod]; +01299 +01300 <span class="comment">// get the mesh instance.</span> +01301 CMeshBaseInstance *mi= safe_cast<CMeshBaseInstance*>(trans); +01302 +01303 <span class="comment">// Profile all pass.</span> +01304 <a class="code" href="a04558.html#a15">uint</a> triCount= 0; +01305 <span class="keywordflow">for</span> (<a class="code" href="a04558.html#a15">uint</a> i=0;i<lod.RdrPass.size();i++) +01306 { +01307 CRdrPass &rdrPass= lod.RdrPass[i]; +01308 <span class="comment">// Profile with the Materials of the MeshInstance.</span> +01309 <span class="keywordflow">if</span> ( ( (mi->Materials[rdrPass.MaterialId].getBlend() == <span class="keyword">false</span>) && (rdrFlags & IMeshGeom::RenderOpaqueMaterial) ) || +01310 ( (mi->Materials[rdrPass.MaterialId].getBlend() == <span class="keyword">true</span>) && (rdrFlags & IMeshGeom::RenderTransparentMaterial) ) ) +01311 { +01312 triCount+= rdrPass.getNumTriangle(); +01313 } +01314 } +01315 +01316 <span class="comment">// Profile</span> +01317 <span class="keywordflow">if</span>(triCount) +01318 { +01319 <span class="comment">// tri per VBFormat</span> +01320 rdrTrav->Scene->incrementProfileTriVBFormat(rdrTrav->Scene->BenchRes.MeshMRMProfileTriVBFormat, +01321 NL3D_MESH_SKIN_MANAGER_VERTEXFORMAT, triCount); +01322 +01323 rdrTrav->Scene->BenchRes.NumMeshMRMVBufferStd++; +01324 rdrTrav->Scene->BenchRes.NumMeshMRMRdrNormal++; +01325 rdrTrav->Scene->BenchRes.NumMeshMRMTriRdrNormal+= triCount; +01326 } +01327 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz503_5" doxytag="NL3D::CMeshMRMSkinnedGeom::render" ></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::CMeshMRMSkinnedGeom::render </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02434.html">IDriver</a> * </td> + <td class="mdname" nowrap> <em>drv</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02537.html">CTransformShape</a> * </td> + <td class="mdname" nowrap> <em>trans</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>polygonCount</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a> </td> + <td class="mdname" nowrap> <em>rdrFlags</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>globalAlpha</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +<a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_5">render()</a> this mesh in a driver, given an instance and his materials. +<p> + +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeoma6">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06011.html#l00568">568</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a02434.html#NL3D_1_1IDrivera2">NL3D::IDriver::activeVertexBuffer()</a>, <a class="el" href="a06011.html#l00410">applyGeomorph()</a>, <a class="el" href="a06011.html#l00547">chooseLod()</a>, <a class="el" href="a02434.html#NL3D_1_1IDrivera14">NL3D::IDriver::forceNormalize()</a>, <a class="el" href="a06012.html#l00353">NL3D::CMeshMRMSkinnedGeom::CLod::Geomorphs</a>, <a class="el" href="a06060.html#l00101">NL3D::CMRMLevelDetail::getLevelDetailFromPolyCount()</a>, <a class="el" href="a06569.html#l00105">NL3D::CTransform::getOwnerScene()</a>, <a class="el" href="a06011.html#l00114">NL3D::CMeshMRMSkinnedGeom::CLod::getRdrPassPrimitiveBlock()</a>, <a class="el" href="a06349.html#l00479">NL3D::CScene::getRenderTrav()</a>, <a class="el" href="a06569.html#l00205">NL3D::CTransform::getSkeletonModel()</a>, <a class="el" href="a06011.html#l02088">getVertexBuffer()</a>, <a class="el" href="a06569.html#l00299">NL3D::CTransform::getWorldMatrix()</a>, <a class="el" href="a05788.html#l00056">H_AUTO</a>, <a class="el" href="a02434.html#NL3D_1_1IDrivera46">NL3D::IDriver::isForceNormalize()</a>, <a class="el" href="a06569.html#l00423">NL3D::CTransform::isSkinned()</a>, <a class="el" href="a06012.html#l00309">NL3D::CMeshMRMSkinnedGeom::CRdrPass::MaterialId</a>, <a class="el" href="a05994.html#l00075">NL3D::CMeshBaseInstance::Materials</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05701.html#l00125">NLMISC::OptFastFloor()</a>, <a class="el" href="a05995.html#l00037">NL3D::CMeshBlender::prepareRenderForGlobalAlpha()</a>, <a class="el" href="a06012.html#l00355">NL3D::CMeshMRMSkinnedGeom::CLod::RdrPass</a>, <a class="el" href="a02434.html#NL3D_1_1IDrivera51">NL3D::IDriver::render()</a>, <a class="el" href="a05995.html#l00099">NL3D::CMeshBlender::restoreRender()</a>, <a class="el" href="a02434.html#NL3D_1_1IDrivera68">NL3D::IDriver::setupModelMatrix()</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a05981.html#l00105">uint</a>, <a class="el" href="a05981.html#l00100">uint32</a>, and <a class="el" href="a05981.html#l00096">uint8</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01468">NL3D::CMeshMRMSkinned::render()</a>. +<p> +<div class="fragment"><pre>00569 { +00570 <a class="code" href="a04199.html#a6">nlassert</a>(drv); +00571 <span class="keywordflow">if</span>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>.size()==0) +00572 <span class="keywordflow">return</span>; +00573 +00574 +00575 <span class="comment">// get the meshMRM instance.</span> +00576 CMeshBaseInstance *mi= safe_cast<CMeshBaseInstance*>(trans); +00577 <span class="comment">// get a ptr on scene</span> +00578 CScene *ownerScene= mi->getOwnerScene(); +00579 <span class="comment">// get a ptr on renderTrav</span> +00580 CRenderTrav *renderTrav= &ownerScene->getRenderTrav(); +00581 +00582 +00583 <span class="comment">// get the result of the Load Balancing.</span> +00584 <span class="keywordtype">float</span> alphaMRM= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.getLevelDetailFromPolyCount(polygonCount); +00585 +00586 <span class="comment">// choose the lod.</span> +00587 <span class="keywordtype">float</span> alphaLod; +00588 <a class="code" href="a04558.html#a14">sint</a> numLod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd5">chooseLod</a>(alphaMRM, alphaLod); +00589 +00590 +00591 <span class="comment">// Render the choosen Lod.</span> +00592 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz515_0">CLod</a> &lod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[numLod]; +00593 <span class="keywordflow">if</span>(lod.RdrPass.size()==0) +00594 <span class="keywordflow">return</span>; +00595 +00596 +00597 <span class="comment">// get the skeleton model to which I am binded (else NULL).</span> +00598 CSkeletonModel *skeleton; +00599 skeleton = mi->getSkeletonModel(); +00600 <span class="comment">// The mesh must not be skinned for render()</span> +00601 <a class="code" href="a04199.html#a6">nlassert</a>(!(mi->isSkinned() && skeleton)); +00602 +00603 +00604 <span class="comment">// Profiling</span> +00605 <span class="comment">//===========</span> +00606 <a class="code" href="a04365.html#a4">H_AUTO</a>( NL3D_MeshMRMGeom_RenderNormal ); +00607 +00608 <span class="comment">// Skinning.</span> +00609 <span class="comment">//===========</span> +00610 +00611 <span class="comment">// set the instance worldmatrix.</span> +00612 drv->setupModelMatrix(trans->getWorldMatrix()); +00613 +00614 +00615 <span class="comment">// Geomorph.</span> +00616 <span class="comment">//===========</span> +00617 <span class="comment">// Geomorph the choosen Lod (if not the coarser mesh).</span> +00618 <span class="keywordflow">if</span>(numLod>0) +00619 { +00620 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd0">applyGeomorph</a>(lod.Geomorphs, alphaLod); +00621 } +00622 +00623 +00624 <span class="comment">// force normalisation of normals..</span> +00625 <span class="keywordtype">bool</span> bkupNorm= drv->isForceNormalize(); +00626 drv->forceNormalize(<span class="keyword">true</span>); +00627 +00628 +00629 <span class="comment">// Setup meshVertexProgram</span> +00630 <span class="comment">//===========</span> +00631 +00632 <span class="comment">// Render the lod.</span> +00633 <span class="comment">//===========</span> +00634 <span class="comment">// active VB.</span> +00635 +00636 <span class="comment">/* Hulud</span> +00637 <span class="comment"> * This is slow but, we don't care because this method is called for debug purpose only (watch skin without skinning)</span> +00638 <span class="comment"> */</span> +00639 CVertexBuffer tmp; +00640 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz505_8">getVertexBuffer</a> (tmp); +00641 +00642 drv->activeVertexBuffer(tmp); +00643 +00644 +00645 <span class="comment">// Global alpha used ?</span> +00646 <a class="code" href="a04558.html#a11">uint32</a> globalAlphaUsed= rdrFlags & IMeshGeom::RenderGlobalAlpha; +00647 <a class="code" href="a04558.html#a7">uint8</a> globalAlphaInt=(<a class="code" href="a04558.html#a7">uint8</a>)<a class="code" href="a05378.html#a397">NLMISC::OptFastFloor</a>(globalAlpha*255); +00648 +00649 <span class="comment">// Render all pass.</span> +00650 <span class="keywordflow">if</span> (globalAlphaUsed) +00651 { +00652 <span class="keywordtype">bool</span> gaDisableZWrite= (rdrFlags & IMeshGeom::RenderGADisableZWrite)?<span class="keyword">true</span>:<span class="keyword">false</span>; +00653 +00654 <span class="comment">// for all passes</span> +00655 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> i=0;i<lod.RdrPass.size();i++) +00656 { +00657 CRdrPass &rdrPass= lod.RdrPass[i]; +00658 +00659 <span class="keywordflow">if</span> ( ( (mi->Materials[rdrPass.MaterialId].getBlend() == <span class="keyword">false</span>) && (rdrFlags & IMeshGeom::RenderOpaqueMaterial) ) || +00660 ( (mi->Materials[rdrPass.MaterialId].getBlend() == <span class="keyword">true</span>) && (rdrFlags & IMeshGeom::RenderTransparentMaterial) ) ) +00661 { +00662 <span class="comment">// CMaterial Ref</span> +00663 CMaterial &material=mi->Materials[rdrPass.MaterialId]; +00664 +00665 <span class="comment">// Use a MeshBlender to modify material and driver.</span> +00666 CMeshBlender blender; +00667 blender.prepareRenderForGlobalAlpha(material, drv, globalAlpha, globalAlphaInt, gaDisableZWrite); +00668 +00669 <span class="comment">/* Hulud</span> +00670 <span class="comment"> * This is slow but, we don't care because this method is called for debug purpose only (watch skin without skinning)</span> +00671 <span class="comment"> */</span> +00672 CPrimitiveBlock block; +00673 lod.getRdrPassPrimitiveBlock (i, block); +00674 +00675 <span class="comment">// Render</span> +00676 drv->render(block, material); +00677 +00678 <span class="comment">// Resetup material/driver</span> +00679 blender.restoreRender(material, drv, gaDisableZWrite); +00680 } +00681 } +00682 } +00683 <span class="keywordflow">else</span> +00684 { +00685 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> i=0;i<lod.RdrPass.size();i++) +00686 { +00687 CRdrPass &rdrPass= lod.RdrPass[i]; +00688 +00689 <span class="keywordflow">if</span> ( ( (mi->Materials[rdrPass.MaterialId].getBlend() == <span class="keyword">false</span>) && (rdrFlags & IMeshGeom::RenderOpaqueMaterial) ) || +00690 ( (mi->Materials[rdrPass.MaterialId].getBlend() == <span class="keyword">true</span>) && (rdrFlags & IMeshGeom::RenderTransparentMaterial) ) ) +00691 { +00692 <span class="comment">// CMaterial Ref</span> +00693 CMaterial &material=mi->Materials[rdrPass.MaterialId]; +00694 +00695 <span class="comment">/* Hulud</span> +00696 <span class="comment"> * This is slow but, we don't care because this method is called for debug purpose only (watch skin without skinning)</span> +00697 <span class="comment"> */</span> +00698 CPrimitiveBlock block; +00699 lod.getRdrPassPrimitiveBlock (i, block); +00700 +00701 <span class="comment">// Render with the Materials of the MeshInstance.</span> +00702 drv->render(block, material); +00703 } +00704 } +00705 } +00706 +00707 <span class="comment">// bkup force normalisation.</span> +00708 drv->forceNormalize(bkupNorm); +00709 +00710 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz509_5" doxytag="NL3D::CMeshMRMSkinnedGeom::renderPass" ></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"> virtual void NL3D::CMeshMRMSkinnedGeom::renderPass </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02887.html">CMeshGeomRenderContext</a> & </td> + <td class="mdname" nowrap> <em>rdrCtx</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02873.html">CMeshBaseInstance</a> * </td> + <td class="mdname" nowrap> <em>inst</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>polygonCount</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>rdrPass</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [inline, virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +The framework call this method to render the current renderPass, with the current instance NB: if the material is blended, DON'T render it!! +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_9">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06012.html#l00234">234</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +References <a class="el" href="a05981.html#l00105">uint</a>. +<p> +<div class="fragment"><pre>00234 {}; +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz513_1" doxytag="NL3D::CMeshMRMSkinnedGeom::renderShadowSkinGeom" ></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#a14">sint</a> NL3D::CMeshMRMSkinnedGeom::renderShadowSkinGeom </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> * </td> + <td class="mdname" nowrap> <em>mi</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>remainingVertices</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>vbDest</em></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> +Get the num of shadow skin vertices. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l01843">1843</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06011.html#l02283">applyArrayShadowSkin()</a>, <a class="el" href="a06569.html#l00205">NL3D::CTransform::getSkeletonModel()</a>, <a class="el" href="a05788.html#l00064">H_AUTO_USE</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a05981.html#l00096">uint8</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00255">NL3D::CMeshMRMSkinnedInstance::renderShadowSkinGeom()</a>. +<p> +<div class="fragment"><pre>01844 { +01845 <a class="code" href="a04558.html#a15">uint</a> numVerts= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">_ShadowSkinVertices</a>.size(); +01846 +01847 <span class="keywordflow">if</span>(numVerts==0) +01848 <span class="keywordflow">return</span> 0; +01849 +01850 <span class="comment">// If the Lod is too big to render in the VBufferHard</span> +01851 <span class="keywordflow">if</span>(numVerts>remainingVertices) +01852 <span class="comment">// return Failure</span> +01853 <span class="keywordflow">return</span> -1; +01854 +01855 <span class="comment">// get the skeleton model to which I am skinned</span> +01856 CSkeletonModel *skeleton; +01857 skeleton = mi->getSkeletonModel(); +01858 <span class="comment">// must be skinned for renderSkin()</span> +01859 <a class="code" href="a04199.html#a6">nlassert</a>(skeleton); +01860 +01861 +01862 <span class="comment">// Profiling</span> +01863 <span class="comment">//===========</span> +01864 <a class="code" href="a04365.html#a7">H_AUTO_USE</a>( NL3D_MeshMRMGeom_RenderShadow ); +01865 +01866 +01867 <span class="comment">// Skinning.</span> +01868 <span class="comment">//===========</span> +01869 +01870 <span class="comment">// skinning with normal, but no tangent space</span> +01871 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_0">applyArrayShadowSkin</a>(&_ShadowSkinVertices[0], (CVector*)vbDest, skeleton, numVerts); +01872 +01873 +01874 <span class="comment">// How many vertices are added to the VBuffer ???</span> +01875 <span class="keywordflow">return</span> numVerts; +01876 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz513_2" doxytag="NL3D::CMeshMRMSkinnedGeom::renderShadowSkinPrimitives" ></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::CMeshMRMSkinnedGeom::renderShadowSkinPrimitives </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> * </td> + <td class="mdname" nowrap> <em>mi</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02839.html">CMaterial</a> & </td> + <td class="mdname" nowrap> <em>castMat</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02434.html">IDriver</a> * </td> + <td class="mdname" nowrap> <em>drv</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>baseVertex</em></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> +Get the num of shadow skin vertices. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l01879">1879</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a05788.html#l00064">H_AUTO_USE</a>, <a class="el" href="a05484.html#l00038">min</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a02434.html#NL3D_1_1IDrivera56">NL3D::IDriver::renderTriangles()</a>, <a class="el" href="a05646.html#l01124">src</a>, <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a05981.html#l00100">uint32</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00265">NL3D::CMeshMRMSkinnedInstance::renderShadowSkinPrimitives()</a>. +<p> +<div class="fragment"><pre>01880 { +01881 <a class="code" href="a04199.html#a6">nlassert</a>(drv); +01882 +01883 <span class="keywordflow">if</span>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_1">_ShadowSkinTriangles</a>.empty()) +01884 <span class="keywordflow">return</span>; +01885 +01886 <span class="comment">// Profiling</span> +01887 <span class="comment">//===========</span> +01888 <a class="code" href="a04365.html#a7">H_AUTO_USE</a>( NL3D_MeshMRMGeom_RenderShadow ); +01889 +01890 <span class="comment">// NB: the skeleton matrix has already been setuped by CSkeletonModel</span> +01891 <span class="comment">// NB: the normalize flag has already been setuped by CSkeletonModel</span> +01892 +01893 <span class="comment">// TODO_SHADOW: optim: Special triangle cache for shadow!</span> +01894 <span class="keyword">static</span> vector<uint32> shiftedTris; +01895 <span class="keywordflow">if</span>(shiftedTris.size()<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_1">_ShadowSkinTriangles</a>.size()) +01896 { +01897 shiftedTris.resize(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_1">_ShadowSkinTriangles</a>.size()); +01898 } +01899 <a class="code" href="a04558.html#a11">uint32</a> *<a class="code" href="a04223.html#a652">src</a>= &<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_1">_ShadowSkinTriangles</a>[0]; +01900 <a class="code" href="a04558.html#a11">uint32</a> *dst= &shiftedTris[0]; +01901 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> n= _ShadowSkinTriangles.size();n>0;n--, <a class="code" href="a04223.html#a652">src</a>++, dst++) +01902 { +01903 *dst= *<a class="code" href="a04223.html#a652">src</a> + baseVertex; +01904 } +01905 +01906 <span class="comment">// Render Triangles with cache</span> +01907 <span class="comment">//===========</span> +01908 +01909 <a class="code" href="a04558.html#a15">uint</a> numTris= _ShadowSkinTriangles.size()/3; +01910 +01911 <span class="comment">// This speed up 4 ms for 80K polys.</span> +01912 <a class="code" href="a04558.html#a15">uint</a> memToCache= numTris*12; +01913 memToCache= <a class="code" href="a04061.html#a0">min</a>(memToCache, 4096U); +01914 CFastMem::precache(&shiftedTris[0], memToCache); +01915 +01916 <span class="comment">// Render with the Materials of the MeshInstance.</span> +01917 drv->renderTriangles(castMat, &shiftedTris[0], numTris); +01918 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz503_6" doxytag="NL3D::CMeshMRMSkinnedGeom::renderSkin" ></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::CMeshMRMSkinnedGeom::renderSkin </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02537.html">CTransformShape</a> * </td> + <td class="mdname" nowrap> <em>trans</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>alphaMRM</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +<a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz503_5">render()</a> this mesh as a skin +<p> + +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeoma7">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06011.html#l00714">714</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00159">NL3D::CMeshMRMSkinnedInstance::renderSkin()</a>. +<p> +<div class="fragment"><pre>00715 { +00716 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz511_0" doxytag="NL3D::CMeshMRMSkinnedGeom::renderSkinGroupGeom" ></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#a14">sint</a> NL3D::CMeshMRMSkinnedGeom::renderSkinGroupGeom </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> * </td> + <td class="mdname" nowrap> <em>mi</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>alphaMRM</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>remainingVertices</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a7">uint8</a> * </td> + <td class="mdname" nowrap> <em>vbDest</em></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="a06011.html#l00726">726</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06014.html#l00127">NL3D::CMeshMRMSkinnedInstance::_RawSkinCache</a>, <a class="el" href="a06011.html#l03320">applyRawSkinWithNormal()</a>, <a class="el" href="a06011.html#l00547">chooseLod()</a>, <a class="el" href="a06316.html#l00111">NL3D::CRawSkinnedNormalCache::Geomorphs</a>, <a class="el" href="a06330.html#l00133">NL3D::CRenderTrav::getDriver()</a>, <a class="el" href="a06569.html#l00105">NL3D::CTransform::getOwnerScene()</a>, <a class="el" href="a06349.html#l00479">NL3D::CScene::getRenderTrav()</a>, <a class="el" href="a06569.html#l00205">NL3D::CTransform::getSkeletonModel()</a>, <a class="el" href="a05788.html#l00056">H_AUTO</a>, <a class="el" href="a06569.html#l00423">NL3D::CTransform::isSkinned()</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a06012.html#l00351">NL3D::CMeshMRMSkinnedGeom::CLod::NWedges</a>, <a class="el" href="a06012.html#l00355">NL3D::CMeshMRMSkinnedGeom::CLod::RdrPass</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a06316.html#l00108">NL3D::CRawSkinnedNormalCache::TotalHardVertices</a>, <a class="el" href="a06316.html#l00107">NL3D::CRawSkinnedNormalCache::TotalSoftVertices</a>, <a class="el" href="a05981.html#l00105">uint</a>, <a class="el" href="a05981.html#l00096">uint8</a>, and <a class="el" href="a06011.html#l01568">updateRawSkinNormal()</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00199">NL3D::CMeshMRMSkinnedInstance::renderSkinGroupGeom()</a>. +<p> +<div class="fragment"><pre>00727 { +00728 <a class="code" href="a04365.html#a4">H_AUTO</a>( NL3D_MeshMRMGeom_rdrSkinGrpGeom ) +00729 +00730 <span class="comment">// get a ptr on scene</span> +00731 CScene *ownerScene= mi->getOwnerScene(); +00732 <span class="comment">// get a ptr on renderTrav</span> +00733 CRenderTrav *renderTrav= &ownerScene->getRenderTrav(); +00734 <span class="comment">// get a ptr on the driver</span> +00735 IDriver *drv= renderTrav->getDriver(); +00736 <a class="code" href="a04199.html#a6">nlassert</a>(drv); +00737 +00738 +00739 <span class="comment">// choose the lod.</span> +00740 <span class="keywordtype">float</span> alphaLod; +00741 <a class="code" href="a04558.html#a14">sint</a> numLod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd5">chooseLod</a>(alphaMRM, alphaLod); +00742 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr7">_LastLodComputed</a>= numLod; +00743 +00744 +00745 <span class="comment">// Render the choosen Lod.</span> +00746 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz515_0">CLod</a> &lod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[numLod]; +00747 <span class="keywordflow">if</span>(lod.RdrPass.size()==0) +00748 <span class="comment">// return no vertices added</span> +00749 <span class="keywordflow">return</span> 0; +00750 +00751 <span class="comment">// If the Lod is too big to render in the VBufferHard</span> +00752 <span class="keywordflow">if</span>(lod.NWedges>remainingVertices) +00753 <span class="comment">// return Failure</span> +00754 <span class="keywordflow">return</span> -1; +00755 +00756 <span class="comment">// get the skeleton model to which I am skinned</span> +00757 CSkeletonModel *skeleton; +00758 skeleton = mi->getSkeletonModel(); +00759 <span class="comment">// must be skinned for renderSkin()</span> +00760 <a class="code" href="a04199.html#a6">nlassert</a>(mi->isSkinned() && skeleton); +00761 +00762 +00763 <span class="comment">// Profiling</span> +00764 <span class="comment">//===========</span> +00765 <a class="code" href="a04365.html#a4">H_AUTO</a>( NL3D_MeshMRMGeom_rdrSkinGrpGeom_go ); +00766 +00767 +00768 <span class="comment">// Skinning.</span> +00769 <span class="comment">//===========</span> +00770 +00771 <span class="comment">// Use RawSkin if possible: only if no morph, and only Vertex/Normal</span> +00772 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_10">updateRawSkinNormal</a>(<span class="keyword">true</span>, mi, numLod); +00773 +00774 <span class="comment">// NB: the skeleton matrix has already been setuped by CSkeletonModel</span> +00775 <span class="comment">// NB: the normalize flag has already been setuped by CSkeletonModel</span> +00776 +00777 <span class="comment">// applySkin with RawSkin.</span> +00778 <span class="comment">//--------</span> +00779 <a class="code" href="a04199.html#a6">nlassert</a>(mi->_RawSkinCache); +00780 +00781 <a class="code" href="a04365.html#a4">H_AUTO</a>( NL3D_RawSkinning ); +00782 +00783 <span class="comment">// RawSkin do all the job in optimized way: Skinning, copy to VBHard and Geomorph.</span> +00784 +00785 <span class="comment">// skinning with normal, but no tangent space</span> +00786 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd4">applyRawSkinWithNormal</a> (lod, *(mi->_RawSkinCache), skeleton, vbDest, alphaLod); +00787 +00788 <span class="comment">// Vertices are packed in RawSkin mode (ie no holes due to MRM!)</span> +00789 <span class="keywordflow">return</span> mi->_RawSkinCache->Geomorphs.size() + +00790 mi->_RawSkinCache->TotalSoftVertices + +00791 mi->_RawSkinCache->TotalHardVertices; +00792 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz511_1" doxytag="NL3D::CMeshMRMSkinnedGeom::renderSkinGroupPrimitives" ></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::CMeshMRMSkinnedGeom::renderSkinGroupPrimitives </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> * </td> + <td class="mdname" nowrap> <em>mi</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>baseVertex</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>std::vector< <a class="el" href="a03407.html">CSkinSpecularRdrPass</a> > & </td> + <td class="mdname" nowrap> <em>specularRdrPasses</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>skinIndex</em></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="a06011.html#l00795">795</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06014.html#l00132">NL3D::CMeshMRMSkinnedInstance::_ShiftedTriangleCache</a>, <a class="el" href="a06330.html#l00133">NL3D::CRenderTrav::getDriver()</a>, <a class="el" href="a06569.html#l00105">NL3D::CTransform::getOwnerScene()</a>, <a class="el" href="a06349.html#l00479">NL3D::CScene::getRenderTrav()</a>, <a class="el" href="a05969.html#l00254">NL3D::CMaterial::getShader()</a>, <a class="el" href="a05641.html#l00046">NL3D::CMaterial::getTexture()</a>, <a class="el" href="a02434.html#NL3D_1_1IDrivera32">NL3D::IDriver::getTextureHandle()</a>, <a class="el" href="a05788.html#l00056">H_AUTO</a>, <a class="el" href="a06012.html#l00309">NL3D::CMeshMRMSkinnedGeom::CRdrPass::MaterialId</a>, <a class="el" href="a05994.html#l00075">NL3D::CMeshBaseInstance::Materials</a>, <a class="el" href="a05484.html#l00038">min</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a06387.html#l00052">NL3D::CShiftedTriangleCache::CRdrPass::NumTriangles</a>, <a class="el" href="a06387.html#l00059">NL3D::CShiftedTriangleCache::RdrPass</a>, <a class="el" href="a06012.html#l00355">NL3D::CMeshMRMSkinnedGeom::CLod::RdrPass</a>, <a class="el" href="a06394.html#l00063">NL3D::CSkinSpecularRdrPass::RdrPassIndex</a>, <a class="el" href="a02434.html#NL3D_1_1IDrivera56">NL3D::IDriver::renderTriangles()</a>, <a class="el" href="a06394.html#l00061">NL3D::CSkinSpecularRdrPass::SkinIndex</a>, <a class="el" href="a06394.html#l00065">NL3D::CSkinSpecularRdrPass::SpecId</a>, <a class="el" href="a06387.html#l00051">NL3D::CShiftedTriangleCache::CRdrPass::Triangles</a>, <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a06011.html#l00918">updateShiftedTriangleCache()</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00208">NL3D::CMeshMRMSkinnedInstance::renderSkinGroupPrimitives()</a>. +<p> +<div class="fragment"><pre>00796 { +00797 <a class="code" href="a04365.html#a4">H_AUTO</a>( NL3D_MeshMRMGeom_rdrSkinGrpPrimitives ); +00798 +00799 <span class="comment">// get a ptr on scene</span> +00800 CScene *ownerScene= mi->getOwnerScene(); +00801 <span class="comment">// get a ptr on renderTrav</span> +00802 CRenderTrav *renderTrav= &ownerScene->getRenderTrav(); +00803 <span class="comment">// get a ptr on the driver</span> +00804 IDriver *drv= renderTrav->getDriver(); +00805 <a class="code" href="a04199.html#a6">nlassert</a>(drv); +00806 +00807 <span class="comment">// Get the lod choosen in renderSkinGroupGeom()</span> +00808 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz515_0">CLod</a> &lod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr7">_LastLodComputed</a>]; +00809 +00810 +00811 <span class="comment">// must update primitive cache</span> +00812 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd7">updateShiftedTriangleCache</a>(mi, _LastLodComputed, baseVertex); +00813 <a class="code" href="a04199.html#a6">nlassert</a>(mi->_ShiftedTriangleCache); +00814 +00815 +00816 <span class="comment">// Render Triangles with cache</span> +00817 <span class="comment">//===========</span> +00818 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> i=0;i<lod.RdrPass.size();i++) +00819 { +00820 CRdrPass &rdrPass= lod.RdrPass[i]; +00821 +00822 <span class="comment">// CMaterial Ref</span> +00823 CMaterial &material=mi->Materials[rdrPass.MaterialId]; +00824 +00825 <span class="comment">// TestYoyo. Material Speed Test</span> +00826 <span class="comment">/*if( material.getDiffuse()!=CRGBA(250, 251, 252) )</span> +00827 <span class="comment"> {</span> +00828 <span class="comment"> material.setDiffuse(CRGBA(250, 251, 252));</span> +00829 <span class="comment"> // Set all texture the same.</span> +00830 <span class="comment"> static CSmartPtr<ITexture> pTexFile= new CTextureFile("fy_hom_visage_c1_fy_e1.tga");</span> +00831 <span class="comment"> material.setTexture(0, pTexFile );</span> +00832 <span class="comment"> // Remove Specular.</span> +00833 <span class="comment"> if(material.getShader()==CMaterial::Specular)</span> +00834 <span class="comment"> {</span> +00835 <span class="comment"> CSmartPtr<ITexture> tex= material.getTexture(0);</span> +00836 <span class="comment"> material.setShader(CMaterial::Normal);</span> +00837 <span class="comment"> material.setTexture(0, tex );</span> +00838 <span class="comment"> }</span> +00839 <span class="comment"> // Remove MakeUp</span> +00840 <span class="comment"> material.setTexture(1, NULL);</span> +00841 <span class="comment"> }*/</span> +00842 +00843 <span class="comment">// If the material is a specular material, don't render it now!</span> +00844 <span class="keywordflow">if</span>(material.getShader()==CMaterial::Specular) +00845 { +00846 <span class="comment">// Add it to the rdrPass to sort!</span> +00847 CSkinSpecularRdrPass specRdrPass; +00848 specRdrPass.SkinIndex= skinIndex; +00849 specRdrPass.RdrPassIndex= i; +00850 <span class="comment">// Get the handle of the specular Map as the sort Key</span> +00851 ITexture *specTex= material.getTexture(1); +00852 <span class="keywordflow">if</span>(!specTex) +00853 specRdrPass.SpecId= 0; +00854 <span class="keywordflow">else</span> +00855 specRdrPass.SpecId= drv->getTextureHandle( *specTex ); +00856 <span class="comment">// Append it to the list</span> +00857 specularRdrPasses.push_back(specRdrPass); +00858 } +00859 <span class="keywordflow">else</span> +00860 { +00861 <span class="comment">// Get the shifted triangles.</span> +00862 CShiftedTriangleCache::CRdrPass &shiftedRdrPass= mi->_ShiftedTriangleCache->RdrPass[i]; +00863 +00864 <span class="comment">// This speed up 4 ms for 80K polys.</span> +00865 <a class="code" href="a04558.html#a15">uint</a> memToCache= shiftedRdrPass.NumTriangles*12; +00866 memToCache= <a class="code" href="a04061.html#a0">min</a>(memToCache, 4096U); +00867 CFastMem::precache(shiftedRdrPass.Triangles, memToCache); +00868 +00869 <span class="comment">// Render with the Materials of the MeshInstance.</span> +00870 drv->renderTriangles(material, shiftedRdrPass.Triangles, shiftedRdrPass.NumTriangles); +00871 } +00872 } +00873 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz511_2" doxytag="NL3D::CMeshMRMSkinnedGeom::renderSkinGroupSpecularRdrPass" ></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::CMeshMRMSkinnedGeom::renderSkinGroupSpecularRdrPass </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> * </td> + <td class="mdname" nowrap> <em>mi</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>rdrPassId</em></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="a06011.html#l00877">877</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06014.html#l00132">NL3D::CMeshMRMSkinnedInstance::_ShiftedTriangleCache</a>, <a class="el" href="a06330.html#l00133">NL3D::CRenderTrav::getDriver()</a>, <a class="el" href="a06569.html#l00105">NL3D::CTransform::getOwnerScene()</a>, <a class="el" href="a06349.html#l00479">NL3D::CScene::getRenderTrav()</a>, <a class="el" href="a05788.html#l00056">H_AUTO</a>, <a class="el" href="a06012.html#l00309">NL3D::CMeshMRMSkinnedGeom::CRdrPass::MaterialId</a>, <a class="el" href="a05994.html#l00075">NL3D::CMeshBaseInstance::Materials</a>, <a class="el" href="a05484.html#l00038">min</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a06387.html#l00052">NL3D::CShiftedTriangleCache::CRdrPass::NumTriangles</a>, <a class="el" href="a06387.html#l00059">NL3D::CShiftedTriangleCache::RdrPass</a>, <a class="el" href="a06012.html#l00355">NL3D::CMeshMRMSkinnedGeom::CLod::RdrPass</a>, <a class="el" href="a02434.html#NL3D_1_1IDrivera56">NL3D::IDriver::renderTriangles()</a>, <a class="el" href="a06387.html#l00051">NL3D::CShiftedTriangleCache::CRdrPass::Triangles</a>, and <a class="el" href="a05981.html#l00105">uint</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00217">NL3D::CMeshMRMSkinnedInstance::renderSkinGroupSpecularRdrPass()</a>. +<p> +<div class="fragment"><pre>00878 { +00879 <a class="code" href="a04365.html#a4">H_AUTO</a>( NL3D_MeshMRMGeom_rdrSkinGrpSpecularRdrPass ); +00880 +00881 <span class="comment">// get a ptr on scene</span> +00882 CScene *ownerScene= mi->getOwnerScene(); +00883 <span class="comment">// get a ptr on renderTrav</span> +00884 CRenderTrav *renderTrav= &ownerScene->getRenderTrav(); +00885 <span class="comment">// get a ptr on the driver</span> +00886 IDriver *drv= renderTrav->getDriver(); +00887 <a class="code" href="a04199.html#a6">nlassert</a>(drv); +00888 +00889 <span class="comment">// Get the lod choosen in renderSkinGroupGeom()</span> +00890 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz515_0">CLod</a> &lod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr7">_LastLodComputed</a>]; +00891 +00892 +00893 <span class="comment">// _ShiftedTriangleCache must have been computed in renderSkinGroupPrimitives</span> +00894 <a class="code" href="a04199.html#a6">nlassert</a>(mi->_ShiftedTriangleCache); +00895 +00896 +00897 <span class="comment">// Render Triangles with cache</span> +00898 <span class="comment">//===========</span> +00899 CRdrPass &rdrPass= lod.RdrPass[rdrPassId]; +00900 +00901 <span class="comment">// CMaterial Ref</span> +00902 CMaterial &material=mi->Materials[rdrPass.MaterialId]; +00903 +00904 <span class="comment">// Get the shifted triangles.</span> +00905 CShiftedTriangleCache::CRdrPass &shiftedRdrPass= mi->_ShiftedTriangleCache->RdrPass[rdrPassId]; +00906 +00907 <span class="comment">// This speed up 4 ms for 80K polys.</span> +00908 <a class="code" href="a04558.html#a15">uint</a> memToCache= shiftedRdrPass.NumTriangles*12; +00909 memToCache= <a class="code" href="a04061.html#a0">min</a>(memToCache, 4096U); +00910 CFastMem::precache(shiftedRdrPass.Triangles, memToCache); +00911 +00912 <span class="comment">// Render with the Materials of the MeshInstance.</span> +00913 drv->renderTriangles(material, shiftedRdrPass.Triangles, shiftedRdrPass.NumTriangles); +00914 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz503_7" doxytag="NL3D::CMeshMRMSkinnedGeom::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 NL3D::CMeshMRMSkinnedGeom::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><code> [virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +serial this meshGeom. +<p> + +<p> +Implements <a class="el" href="a02867.html#NL3D_1_1ITrackDefaulta6">NLMISC::IStreamable</a>. +<p> +Definition at line <a class="el" href="a06011.html#l00991">991</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06011.html#l01273">compileRunTime()</a>, <a class="el" href="a06012.html#l00481">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::contReset()</a>, <a class="el" href="a06011.html#l01560">dirtMeshDataId()</a>, <a class="el" href="a06060.html#l00065">NL3D::CMRMLevelDetail::DistanceCoarsest</a>, <a class="el" href="a06060.html#l00061">NL3D::CMRMLevelDetail::DistanceFinest</a>, <a class="el" href="a06060.html#l00063">NL3D::CMRMLevelDetail::DistanceMiddle</a>, <a class="el" href="a06060.html#l00069">NL3D::CMRMLevelDetail::DistancePow</a>, <a class="el" href="a06463.html#l00064">NLMISC::IStream::isReading()</a>, <a class="el" href="a06060.html#l00058">NL3D::CMRMLevelDetail::MaxFaceUsed</a>, <a class="el" href="a06060.html#l00056">NL3D::CMRMLevelDetail::MinFaceUsed</a>, <a class="el" href="a06060.html#l00068">NL3D::CMRMLevelDetail::OODistanceDelta</a>, <a class="el" href="a06011.html#l01926">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::serial()</a>, <a class="el" href="a06462.html#l00232">NLMISC::IStream::serial()</a>, <a class="el" href="a06462.html#l00324">NLMISC::IStream::serialCont()</a>, <a class="el" href="a06461.html#l00266">NLMISC::IStream::serialVersion()</a>, and <a class="el" href="a05981.html#l00104">sint</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01482">NL3D::CMeshMRMSkinned::serial()</a>. +<p> +<div class="fragment"><pre>00992 { +00993 <span class="comment">// because of complexity, serial is separated in save / load.</span> +00994 +00995 <span class="comment">/*</span> +00996 <span class="comment"> Version 0:</span> +00997 <span class="comment"> - base version.</span> +00998 <span class="comment"> */</span> +00999 <a class="code" href="a04558.html#a14">sint</a> ver= f.<a class="code" href="a02270.html#NLMISC_1_1IStreamz2035_8">serialVersion</a>(0); +01000 +01001 +01002 <span class="comment">// serial bones names</span> +01003 f.<a class="code" href="a02270.html#NLMISC_1_1IStreamz2033_9">serialCont</a> (_BonesName); +01004 +01005 <span class="keywordflow">if</span> (f.<a class="code" href="a02270.html#NLMISC_1_1IStreama0">isReading</a>()) +01006 { +01007 <span class="comment">// Bones index are in skeleton model id list</span> +01008 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr1">_BoneIdComputed</a> = <span class="keyword">false</span>; +01009 +01010 <span class="comment">// Must always recompute usage of parents of bones used.</span> +01011 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr2">_BoneIdExtended</a> = <span class="keyword">false</span>; +01012 } +01013 +01014 <span class="comment">// serial Basic info.</span> +01015 <span class="comment">// ==================</span> +01016 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(_BBox); +01017 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.MaxFaceUsed); +01018 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.MinFaceUsed); +01019 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceFinest); +01020 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceMiddle); +01021 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistanceCoarsest); +01022 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.OODistanceDelta); +01023 f.<a class="code" href="a02270.html#NLMISC_1_1IStreama5">serial</a>(<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">_LevelDetail</a>.DistancePow); +01024 +01025 <span class="comment">// Prepare the VBuffer.</span> +01026 <span class="keywordflow">if</span> (f.<a class="code" href="a02270.html#NLMISC_1_1IStreama0">isReading</a>()) +01027 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera2">contReset</a>(); +01028 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera7">serial</a>(f); +01029 +01030 <span class="comment">// serial Shadow Skin Information</span> +01031 f.<a class="code" href="a02270.html#NLMISC_1_1IStreamz2033_9">serialCont</a> (_ShadowSkinVertices); +01032 f.<a class="code" href="a02270.html#NLMISC_1_1IStreamz2033_9">serialCont</a> (_ShadowSkinTriangles); +01033 +01034 <span class="comment">// resest the Lod arrays. NB: each Lod is empty, and ready to receive Lod data.</span> +01035 <span class="comment">// ==================</span> +01036 <span class="keywordflow">if</span> (f.<a class="code" href="a02270.html#NLMISC_1_1IStreama0">isReading</a>()) +01037 { +01038 <a class="code" href="a05378.html#a381">contReset</a>(_Lods); +01039 } +01040 +01041 f.<a class="code" href="a02270.html#NLMISC_1_1IStreamz2033_9">serialCont</a> (_Lods); +01042 +01043 <span class="keywordflow">if</span> (f.<a class="code" href="a02270.html#NLMISC_1_1IStreama0">isReading</a>()) +01044 { +01045 <span class="comment">// Inform that the mesh data has changed</span> +01046 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_9">dirtMeshDataId</a>(); +01047 +01048 <span class="comment">// Some runtime not serialized compilation</span> +01049 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomd6">compileRunTime</a>(); +01050 } +01051 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz513_3" doxytag="NL3D::CMeshMRMSkinnedGeom::setShadowMesh" ></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::CMeshMRMSkinnedGeom::setShadowMesh </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">const std::vector< <a class="el" href="a02907.html">CShadowVertex</a> > & </td> + <td class="mdname" nowrap> <em>shadowVertices</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>const std::vector< <a class="el" href="a04558.html#a11">uint32</a> > & </td> + <td class="mdname" nowrap> <em>triangles</em></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> +Setup the ShadowMesh. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l01826">1826</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06330.html#l00076">NL3D_SHADOW_MESH_SKIN_MANAGER_MAXVERTICES</a>, and <a class="el" href="a06330.html#l00075">NL3D_SHADOW_MESH_SKIN_MANAGER_VERTEXFORMAT</a>. +<p> +<div class="fragment"><pre>01827 { +01828 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">_ShadowSkinVertices</a>= shadowVertices; +01829 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_1">_ShadowSkinTriangles</a>= triangles; +01830 <span class="comment">// update flag. Support Shadow SkinGrouping if Shadow setuped, and if not too many vertices.</span> +01831 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_3">_SupportShadowSkinGrouping</a>= !<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">_ShadowSkinVertices</a>.empty() && +01832 <a class="code" href="a04907.html#a3">NL3D_SHADOW_MESH_SKIN_MANAGER_VERTEXFORMAT</a>==CVertexBuffer::PositionFlag && +01833 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">_ShadowSkinVertices</a>.size() <= <a class="code" href="a04907.html#a4">NL3D_SHADOW_MESH_SKIN_MANAGER_MAXVERTICES</a>; +01834 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz509_6" doxytag="NL3D::CMeshMRMSkinnedGeom::sortPerMaterial" ></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"> virtual bool NL3D::CMeshMRMSkinnedGeom::sortPerMaterial </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, virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +true if the sort criterion must be by material. Else, sort per instance. +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_10">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06012.html#l00229">229</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +<div class="fragment"><pre>00229 { <span class="keywordflow">return</span> <span class="keyword">false</span>; }; +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz509_7" doxytag="NL3D::CMeshMRMSkinnedGeom::supportMeshBlockRendering" ></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 NL3D::CMeshMRMSkinnedGeom::supportMeshBlockRendering </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> [virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +true if this meshGeom support meshBlock rendering. return false if skinned/meshMorphed. +<p> +Implements <a class="el" href="a02879.html#NL3D_1_1IMeshGeomz457_11">NL3D::IMeshGeom</a>. +<p> +Definition at line <a class="el" href="a06011.html#l01339">1339</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +<div class="fragment"><pre>01340 { +01341 <span class="comment">/*</span> +01342 <span class="comment"> Yoyo: Don't Support It for MRM because too Slow!!</span> +01343 <span class="comment"> The problem is that lock() unlock() on each instance, on the same VBHeap IS AS SLOWER AS</span> +01344 <span class="comment"> VB switching.</span> +01345 <span class="comment"></span> +01346 <span class="comment"> TODO_OPTIMIZE: find a way to optimize MRM.</span> +01347 <span class="comment"> */</span> +01348 <span class="keywordflow">return</span> <span class="keyword">false</span>; +01349 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz513_4" doxytag="NL3D::CMeshMRMSkinnedGeom::supportShadowSkinGrouping" ></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 NL3D::CMeshMRMSkinnedGeom::supportShadowSkinGrouping </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> +Render the ShadowSkin (SkinGroup like). +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00291">291</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00243">NL3D::CMeshMRMSkinnedInstance::supportShadowSkinGrouping()</a>. +<p> +<div class="fragment"><pre>00291 {<span class="keywordflow">return</span> <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_3">_SupportShadowSkinGrouping</a>;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz511_3" doxytag="NL3D::CMeshMRMSkinnedGeom::supportSkinGrouping" ></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 NL3D::CMeshMRMSkinnedGeom::supportSkinGrouping </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="a06011.html#l00720">720</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +Referenced by <a class="el" href="a06013.html#l00188">NL3D::CMeshMRMSkinnedInstance::supportSkinGrouping()</a>. +<p> +<div class="fragment"><pre>00721 { +00722 <span class="keywordflow">return</span> <span class="keyword">true</span>; +00723 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_10" doxytag="NL3D::CMeshMRMSkinnedGeom::updateRawSkinNormal" ></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::CMeshMRMSkinnedGeom::updateRawSkinNormal </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">bool </td> + <td class="mdname" nowrap> <em>enabled</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> * </td> + <td class="mdname" nowrap> <em>mi</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a14">sint</a> </td> + <td class="mdname" nowrap> <em>curLodId</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +compute RawSkin info in the MRMInstance according to current skin setup. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l01568">1568</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06014.html#l00127">NL3D::CMeshMRMSkinnedInstance::_RawSkinCache</a>, <a class="el" href="a06315.html#l00037">NL3D::CRawSkinnedNormalCache::clearArrays()</a>, <a class="el" href="a06013.html#l00069">NL3D::CMeshMRMSkinnedInstance::clearRawSkinCache()</a>, <a class="el" href="a06316.html#l00111">NL3D::CRawSkinnedNormalCache::Geomorphs</a>, <a class="el" href="a06012.html#l00353">NL3D::CMeshMRMSkinnedGeom::CLod::Geomorphs</a>, <a class="el" href="a06012.html#l00442">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::getNormal()</a>, <a class="el" href="a06012.html#l00505">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getNumVertices()</a>, <a class="el" href="a06012.html#l00487">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getPackedVertices()</a>, <a class="el" href="a06012.html#l00511">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::getPos()</a>, <a class="el" href="a06012.html#l00448">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::getU()</a>, <a class="el" href="a06012.html#l00452">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::getV()</a>, <a class="el" href="a06012.html#l00456">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::getWeight()</a>, <a class="el" href="a05788.html#l00056">H_AUTO</a>, <a class="el" href="a06316.html#l00105">NL3D::CRawSkinnedNormalCache::HardVertices</a>, <a class="el" href="a06012.html#l00360">NL3D::CMeshMRMSkinnedGeom::CLod::InfluencedVertices</a>, <a class="el" href="a06316.html#l00116">NL3D::CRawSkinnedNormalCache::LodId</a>, <a class="el" href="a06012.html#l00432">NL3D::CMeshMRMSkinnedGeom::CPackedVertexBuffer::CPackedVertex::Matrices</a>, <a class="el" href="a06316.html#l00118">NL3D::CRawSkinnedNormalCache::MeshDataId</a>, <a class="el" href="a05990.html#l00063">NL3D_MESH_SKINNING_MAX_MATRIX</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a06012.html#l00355">NL3D::CMeshMRMSkinnedGeom::CLod::RdrPass</a>, <a class="el" href="a06316.html#l00113">NL3D::CRawSkinnedNormalCache::RdrPass</a>, <a class="el" href="a06116.html#l00142">NLMISC::CObjectVector< CRawVertexNormalSkinned4, false >::resize()</a>, <a class="el" href="a06116.html#l00142">NLMISC::CObjectVector< CRawVertexNormalSkinned3, false >::resize()</a>, <a class="el" href="a06116.html#l00142">NLMISC::CObjectVector< CRawVertexNormalSkinned2, false >::resize()</a>, <a class="el" href="a06116.html#l00142">NLMISC::CObjectVector< CRawVertexNormalSkinned1, false >::resize()</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a06116.html#l00184">NLMISC::CObjectVector< CRawVertexNormalSkinned4, false >::size()</a>, <a class="el" href="a06116.html#l00184">NLMISC::CObjectVector< CRawVertexNormalSkinned3, false >::size()</a>, <a class="el" href="a06116.html#l00184">NLMISC::CObjectVector< CRawVertexNormalSkinned2, false >::size()</a>, <a class="el" href="a06116.html#l00184">NLMISC::CObjectVector< CRawVertexNormalSkinned1, false >::size()</a>, <a class="el" href="a06316.html#l00104">NL3D::CRawSkinnedNormalCache::SoftVertices</a>, <a class="el" href="a06316.html#l00108">NL3D::CRawSkinnedNormalCache::TotalHardVertices</a>, <a class="el" href="a06316.html#l00107">NL3D::CRawSkinnedNormalCache::TotalSoftVertices</a>, <a class="el" href="a05981.html#l00105">uint</a>, <a class="el" href="a05981.html#l00098">uint16</a>, <a class="el" href="a05981.html#l00100">uint32</a>, <a class="el" href="a06316.html#l00095">NL3D::CRawSkinnedNormalCache::Vertices1</a>, <a class="el" href="a06316.html#l00097">NL3D::CRawSkinnedNormalCache::Vertices2</a>, <a class="el" href="a06316.html#l00099">NL3D::CRawSkinnedNormalCache::Vertices3</a>, and <a class="el" href="a06316.html#l00101">NL3D::CRawSkinnedNormalCache::Vertices4</a>. +<p> +Referenced by <a class="el" href="a06011.html#l00726">renderSkinGroupGeom()</a>. +<p> +<div class="fragment"><pre>01569 { +01570 <span class="keywordflow">if</span>(!enabled) +01571 { +01572 <span class="comment">// if the instance cache is not cleared, must clear.</span> +01573 mi->clearRawSkinCache(); +01574 } +01575 <span class="keywordflow">else</span> +01576 { +01577 <span class="comment">// If the instance has no RawSkin, or has a too old RawSkin cache, must delete it, and recreate</span> +01578 <span class="keywordflow">if</span> ((mi->_RawSkinCache == NULL) || (mi->_RawSkinCache->MeshDataId!=<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_11">_MeshDataId</a>)) +01579 { +01580 <span class="comment">// first delete if too old.</span> +01581 mi->clearRawSkinCache(); +01582 +01583 <span class="comment">// Then recreate, and use _MeshDataId to verify that the instance works with same data.</span> +01584 mi->_RawSkinCache= <span class="keyword">new</span> CRawSkinnedNormalCache; +01585 mi->_RawSkinCache->MeshDataId= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_11">_MeshDataId</a>; +01586 mi->_RawSkinCache->LodId= -1; +01587 } +01588 +01589 +01590 <span class="comment">/* If the instance rawSkin has a different Lod (or if -1), then must recreate it.</span> +01591 <span class="comment"> NB: The lod may change each frame per instance, but suppose not so many change, so we can cache those data.</span> +01592 <span class="comment"> */</span> +01593 <span class="keywordflow">if</span>( mi->_RawSkinCache->LodId != curLodId ) +01594 { +01595 <a class="code" href="a04365.html#a4">H_AUTO</a>( NL3D_CMeshMRMGeom_updateRawSkinNormal ); +01596 +01597 CRawSkinnedNormalCache &skinLod= *mi->_RawSkinCache; +01598 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz515_0">CLod</a> &lod= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">_Lods</a>[curLodId]; +01599 <a class="code" href="a04558.html#a15">uint</a> i; +01600 <a class="code" href="a04558.html#a14">sint</a> rawIdx; +01601 +01602 <span class="comment">// Clear the raw skin mesh.</span> +01603 skinLod.clearArrays(); +01604 +01605 <span class="comment">// Cache this lod</span> +01606 mi->_RawSkinCache->LodId= curLodId; +01607 +01608 <span class="comment">// For each matrix influence.</span> +01609 <a class="code" href="a04199.html#a6">nlassert</a>(NL3D_MESH_SKINNING_MAX_MATRIX==4); +01610 +01611 <span class="comment">// For each vertex, acknowledge if it is a src for geomorph.</span> +01612 <span class="keyword">static</span> vector<uint8> softVertices; +01613 softVertices.clear(); +01614 softVertices.resize( <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera3">getNumVertices</a>(), 0 ); +01615 <span class="keywordflow">for</span>(i=0;i<lod.Geomorphs.size();i++) +01616 { +01617 softVertices[lod.Geomorphs[i].Start]= 1; +01618 softVertices[lod.Geomorphs[i].End]= 1; +01619 } +01620 +01621 <span class="comment">// The remap from old index in _VBufferFinal to RawSkin vertices (without Geomorphs).</span> +01622 <span class="keyword">static</span> vector<uint32> vertexRemap; +01623 vertexRemap.resize( <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera3">getNumVertices</a>() ); +01624 <a class="code" href="a04558.html#a14">sint</a> softSize[4]; +01625 <a class="code" href="a04558.html#a14">sint</a> hardSize[4]; +01626 <a class="code" href="a04558.html#a14">sint</a> softStart[4]; +01627 <a class="code" href="a04558.html#a14">sint</a> hardStart[4]; +01628 <span class="comment">// count vertices</span> +01629 skinLod.TotalSoftVertices= 0; +01630 skinLod.TotalHardVertices= 0; +01631 <span class="keywordflow">for</span>(i=0;i<4;i++) +01632 { +01633 softSize[i]= 0; +01634 hardSize[i]= 0; +01635 <span class="comment">// Count.</span> +01636 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> j=0;j<lod.InfluencedVertices[i].size();j++) +01637 { +01638 <a class="code" href="a04558.html#a15">uint</a> vid= lod.InfluencedVertices[i][j]; +01639 <span class="keywordflow">if</span>(softVertices[vid]) +01640 softSize[i]++; +01641 <span class="keywordflow">else</span> +01642 hardSize[i]++; +01643 } +01644 skinLod.TotalSoftVertices+= softSize[i]; +01645 skinLod.TotalHardVertices+= hardSize[i]; +01646 skinLod.SoftVertices[i]= softSize[i]; +01647 skinLod.HardVertices[i]= hardSize[i]; +01648 } +01649 <span class="comment">// compute offsets</span> +01650 softStart[0]= 0; +01651 hardStart[0]= skinLod.TotalSoftVertices; +01652 <span class="keywordflow">for</span>(i=1;i<4;i++) +01653 { +01654 softStart[i]= softStart[i-1]+softSize[i-1]; +01655 hardStart[i]= hardStart[i-1]+hardSize[i-1]; +01656 } +01657 <span class="comment">// compute remap</span> +01658 <span class="keywordflow">for</span>(i=0;i<4;i++) +01659 { +01660 <a class="code" href="a04558.html#a15">uint</a> softIdx= softStart[i]; +01661 <a class="code" href="a04558.html#a15">uint</a> hardIdx= hardStart[i]; +01662 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> j=0;j<lod.InfluencedVertices[i].size();j++) +01663 { +01664 <a class="code" href="a04558.html#a15">uint</a> vid= lod.InfluencedVertices[i][j]; +01665 <span class="keywordflow">if</span>(softVertices[vid]) +01666 vertexRemap[vid]= softIdx++; +01667 <span class="keywordflow">else</span> +01668 vertexRemap[vid]= hardIdx++; +01669 } +01670 } +01671 +01672 +01673 <span class="comment">// Resize the dest array.</span> +01674 skinLod.Vertices1.resize(lod.InfluencedVertices[0].size()); +01675 skinLod.Vertices2.resize(lod.InfluencedVertices[1].size()); +01676 skinLod.Vertices3.resize(lod.InfluencedVertices[2].size()); +01677 skinLod.Vertices4.resize(lod.InfluencedVertices[3].size()); +01678 +01679 <span class="comment">// Vertex buffer pointers</span> +01680 <span class="keyword">const</span> CPackedVertexBuffer::CPackedVertex *vertices = <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera5">getPackedVertices</a>(); +01681 +01682 <span class="comment">// 1 Matrix skinning.</span> +01683 <span class="comment">//========</span> +01684 <span class="keywordflow">for</span>(i=0;i<skinLod.Vertices1.size();i++) +01685 { +01686 <span class="comment">// get the dest vertex.</span> +01687 <a class="code" href="a04558.html#a15">uint</a> vid= lod.InfluencedVertices[0][i]; +01688 <span class="comment">// where to store?</span> +01689 rawIdx= vertexRemap[vid]; +01690 <span class="keywordflow">if</span>(softVertices[vid]) +01691 rawIdx-= softStart[0]; +01692 <span class="keywordflow">else</span> +01693 rawIdx+= softSize[0]-hardStart[0]; +01694 +01695 <span class="comment">// fill raw struct</span> +01696 <span class="keyword">const</span> CPackedVertexBuffer::CPackedVertex &vertex = vertices[vid]; +01697 skinLod.Vertices1[rawIdx].MatrixId[0]= vertex.Matrices[0]; +01698 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera6">getPos</a> (skinLod.Vertices1[rawIdx].Vertex, vertex); +01699 vertex.getNormal (skinLod.Vertices1[rawIdx].Normal); +01700 vertex.getU (skinLod.Vertices1[rawIdx].UV.U); +01701 vertex.getV (skinLod.Vertices1[rawIdx].UV.V); +01702 } +01703 +01704 <span class="comment">// 2 Matrix skinning.</span> +01705 <span class="comment">//========</span> +01706 <span class="keywordflow">for</span>(i=0;i<skinLod.Vertices2.size();i++) +01707 { +01708 <span class="comment">// get the dest vertex.</span> +01709 <a class="code" href="a04558.html#a15">uint</a> vid= lod.InfluencedVertices[1][i]; +01710 <span class="comment">// where to store?</span> +01711 rawIdx= vertexRemap[vid]; +01712 <span class="keywordflow">if</span>(softVertices[vid]) +01713 rawIdx-= softStart[1]; +01714 <span class="keywordflow">else</span> +01715 rawIdx+= softSize[1]-hardStart[1]; +01716 <span class="comment">// fill raw struct</span> +01717 <span class="keyword">const</span> CPackedVertexBuffer::CPackedVertex &vertex = vertices[vid]; +01718 skinLod.Vertices2[rawIdx].MatrixId[0]= vertex.Matrices[0]; +01719 skinLod.Vertices2[rawIdx].MatrixId[1]= vertex.Matrices[1]; +01720 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera6">getPos</a> (skinLod.Vertices2[rawIdx].Vertex, vertex); +01721 vertex.getWeight (skinLod.Vertices2[rawIdx].Weights[0], 0); +01722 vertex.getWeight (skinLod.Vertices2[rawIdx].Weights[1], 1); +01723 vertex.getNormal (skinLod.Vertices2[rawIdx].Normal); +01724 vertex.getU (skinLod.Vertices2[rawIdx].UV.U); +01725 vertex.getV (skinLod.Vertices2[rawIdx].UV.V); +01726 } +01727 +01728 <span class="comment">// 3 Matrix skinning.</span> +01729 <span class="comment">//========</span> +01730 <span class="keywordflow">for</span>(i=0;i<skinLod.Vertices3.size();i++) +01731 { +01732 <span class="comment">// get the dest vertex.</span> +01733 <a class="code" href="a04558.html#a15">uint</a> vid= lod.InfluencedVertices[2][i]; +01734 <span class="comment">// where to store?</span> +01735 rawIdx= vertexRemap[vid]; +01736 <span class="keywordflow">if</span>(softVertices[vid]) +01737 rawIdx-= softStart[2]; +01738 <span class="keywordflow">else</span> +01739 rawIdx+= softSize[2]-hardStart[2]; +01740 <span class="comment">// fill raw struct</span> +01741 <span class="keyword">const</span> CPackedVertexBuffer::CPackedVertex &vertex = vertices[vid]; +01742 skinLod.Vertices3[rawIdx].MatrixId[0]= vertex.Matrices[0]; +01743 skinLod.Vertices3[rawIdx].MatrixId[1]= vertex.Matrices[1]; +01744 skinLod.Vertices3[rawIdx].MatrixId[2]= vertex.Matrices[2]; +01745 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera6">getPos</a> (skinLod.Vertices3[rawIdx].Vertex, vertex); +01746 vertex.getWeight (skinLod.Vertices3[rawIdx].Weights[0], 0); +01747 vertex.getWeight (skinLod.Vertices3[rawIdx].Weights[1], 1); +01748 vertex.getWeight (skinLod.Vertices3[rawIdx].Weights[2], 2); +01749 vertex.getNormal (skinLod.Vertices3[rawIdx].Normal); +01750 vertex.getU (skinLod.Vertices3[rawIdx].UV.U); +01751 vertex.getV (skinLod.Vertices3[rawIdx].UV.V); +01752 } +01753 +01754 <span class="comment">// 4 Matrix skinning.</span> +01755 <span class="comment">//========</span> +01756 <span class="keywordflow">for</span>(i=0;i<skinLod.Vertices4.size();i++) +01757 { +01758 <span class="comment">// get the dest vertex.</span> +01759 <a class="code" href="a04558.html#a15">uint</a> vid= lod.InfluencedVertices[3][i]; +01760 <span class="comment">// where to store?</span> +01761 rawIdx= vertexRemap[vid]; +01762 <span class="keywordflow">if</span>(softVertices[vid]) +01763 rawIdx-= softStart[3]; +01764 <span class="keywordflow">else</span> +01765 rawIdx+= softSize[3]-hardStart[3]; +01766 <span class="comment">// fill raw struct</span> +01767 <span class="keyword">const</span> CPackedVertexBuffer::CPackedVertex &vertex = vertices[vid]; +01768 skinLod.Vertices4[rawIdx].MatrixId[0]= vertex.Matrices[0]; +01769 skinLod.Vertices4[rawIdx].MatrixId[1]= vertex.Matrices[1]; +01770 skinLod.Vertices4[rawIdx].MatrixId[2]= vertex.Matrices[2]; +01771 skinLod.Vertices4[rawIdx].MatrixId[3]= vertex.Matrices[3]; +01772 <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">_VBufferFinal</a>.<a class="code" href="a02904.html#NL3D_1_1CMeshMRMSkinnedGeom_1_1CPackedVertexBuffera6">getPos</a> (skinLod.Vertices4[rawIdx].Vertex, vertex); +01773 vertex.getWeight (skinLod.Vertices4[rawIdx].Weights[0], 0); +01774 vertex.getWeight (skinLod.Vertices4[rawIdx].Weights[1], 1); +01775 vertex.getWeight (skinLod.Vertices4[rawIdx].Weights[2], 2); +01776 vertex.getWeight (skinLod.Vertices4[rawIdx].Weights[3], 3); +01777 vertex.getNormal (skinLod.Vertices4[rawIdx].Normal); +01778 vertex.getU (skinLod.Vertices4[rawIdx].UV.U); +01779 vertex.getV (skinLod.Vertices4[rawIdx].UV.V); +01780 } +01781 +01782 <span class="comment">// Remap Geomorphs.</span> +01783 <span class="comment">//========</span> +01784 <a class="code" href="a04558.html#a15">uint</a> numGeoms= lod.Geomorphs.size(); +01785 skinLod.Geomorphs.resize( numGeoms ); +01786 <span class="keywordflow">for</span>(i=0;i<numGeoms;i++) +01787 { +01788 <span class="comment">// NB: don't add "numGeoms" to the index because RawSkin look in a TempArray in RAM, wich start at 0...</span> +01789 skinLod.Geomorphs[i].Start= vertexRemap[lod.Geomorphs[i].Start]; +01790 skinLod.Geomorphs[i].End= vertexRemap[lod.Geomorphs[i].End]; +01791 } +01792 +01793 <span class="comment">// Remap RdrPass.</span> +01794 <span class="comment">//========</span> +01795 skinLod.RdrPass.resize(lod.RdrPass.size()); +01796 <span class="keywordflow">for</span>(i=0;i<skinLod.RdrPass.size();i++) +01797 { +01798 <span class="comment">// remap tris.</span> +01799 skinLod.RdrPass[i].setNumTri(lod.RdrPass[i].getNumTriangle()); +01800 <a class="code" href="a04558.html#a9">uint16</a> *srcTriPtr= &(lod.RdrPass[i].PBlock[0]); +01801 <a class="code" href="a04558.html#a11">uint32</a> *dstTriPtr= skinLod.RdrPass[i].getTriPointer(); +01802 <a class="code" href="a04558.html#a11">uint32</a> numIndices= lod.RdrPass[i].PBlock.size(); +01803 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> j=0;j<numIndices;j++, srcTriPtr++, dstTriPtr++) +01804 { +01805 <a class="code" href="a04558.html#a15">uint</a> vid= (<a class="code" href="a04558.html#a15">uint</a>)*srcTriPtr; +01806 <span class="comment">// If this index refers to a Geomorphed vertex, don't modify!</span> +01807 <span class="keywordflow">if</span>(vid<numGeoms) +01808 *dstTriPtr= vid; +01809 <span class="keywordflow">else</span> +01810 *dstTriPtr= vertexRemap[vid] + numGeoms; +01811 } +01812 } +01813 } +01814 } +01815 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomd7" doxytag="NL3D::CMeshMRMSkinnedGeom::updateShiftedTriangleCache" ></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::CMeshMRMSkinnedGeom::updateShiftedTriangleCache </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02909.html">CMeshMRMSkinnedInstance</a> * </td> + <td class="mdname" nowrap> <em>mi</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap><a class="el" href="a04558.html#a14">sint</a> </td> + <td class="mdname" nowrap> <em>curLodId</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>baseVertex</em></td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"><code> [private]</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="a06011.html#l00918">918</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06014.html#l00127">NL3D::CMeshMRMSkinnedInstance::_RawSkinCache</a>, <a class="el" href="a06014.html#l00132">NL3D::CMeshMRMSkinnedInstance::_ShiftedTriangleCache</a>, <a class="el" href="a06387.html#l00066">NL3D::CShiftedTriangleCache::BaseVertex</a>, <a class="el" href="a06013.html#l00076">NL3D::CMeshMRMSkinnedInstance::clearShiftedTriangleCache()</a>, <a class="el" href="a06116.html#l00195">NLMISC::CObjectVector< uint32, false >::getPtr()</a>, <a class="el" href="a06387.html#l00062">NL3D::CShiftedTriangleCache::LodId</a>, <a class="el" href="a06387.html#l00064">NL3D::CShiftedTriangleCache::MeshDataId</a>, <a class="el" href="a05622.html#l00290">nlassert</a>, <a class="el" href="a06387.html#l00052">NL3D::CShiftedTriangleCache::CRdrPass::NumTriangles</a>, <a class="el" href="a06387.html#l00057">NL3D::CShiftedTriangleCache::RawIndices</a>, <a class="el" href="a06387.html#l00059">NL3D::CShiftedTriangleCache::RdrPass</a>, <a class="el" href="a06316.html#l00113">NL3D::CRawSkinnedNormalCache::RdrPass</a>, <a class="el" href="a06116.html#l00142">NLMISC::CObjectVector< uint32, false >::resize()</a>, <a class="el" href="a06116.html#l00142">NLMISC::CObjectVector< CRdrPass, false >::resize()</a>, <a class="el" href="a05981.html#l00104">sint</a>, <a class="el" href="a06387.html#l00051">NL3D::CShiftedTriangleCache::CRdrPass::Triangles</a>, <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a05981.html#l00100">uint32</a>. +<p> +Referenced by <a class="el" href="a06011.html#l00795">renderSkinGroupPrimitives()</a>. +<p> +<div class="fragment"><pre>00919 { +00920 <span class="comment">// if the instance has a cache, but not sync to us, delete it.</span> +00921 <span class="keywordflow">if</span>( mi->_ShiftedTriangleCache && ( +00922 mi->_ShiftedTriangleCache->MeshDataId != <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_11">_MeshDataId</a> || +00923 mi->_ShiftedTriangleCache->LodId != curLodId || +00924 mi->_ShiftedTriangleCache->BaseVertex != baseVertex) ) +00925 { +00926 mi->clearShiftedTriangleCache(); +00927 } +00928 +00929 <span class="comment">// If the instance has not a valid cache, must create it.</span> +00930 <span class="keywordflow">if</span>( !mi->_ShiftedTriangleCache ) +00931 { +00932 mi->_ShiftedTriangleCache= <span class="keyword">new</span> CShiftedTriangleCache; +00933 <span class="comment">// Fill the cache Key.</span> +00934 mi->_ShiftedTriangleCache->MeshDataId= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_11">_MeshDataId</a>; +00935 mi->_ShiftedTriangleCache->LodId= curLodId; +00936 mi->_ShiftedTriangleCache->BaseVertex= baseVertex; +00937 +00938 <span class="comment">// Build list of PBlock. From Lod, or from RawSkin cache.</span> +00939 <span class="keyword">static</span> vector<CPrimitiveBlock*> pbList; +00940 pbList.clear(); +00941 <a class="code" href="a04199.html#a6">nlassert</a>(mi->_RawSkinCache); +00942 pbList.resize(mi->_RawSkinCache->RdrPass.size()); +00943 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> i=0;i<pbList.size();i++) +00944 { +00945 pbList[i]= &mi->_RawSkinCache->RdrPass[i]; +00946 } +00947 +00948 <span class="comment">// Build RdrPass</span> +00949 mi->_ShiftedTriangleCache->RdrPass.resize(pbList.size()); +00950 +00951 <span class="comment">// First pass, count number of triangles, and fill header info</span> +00952 <a class="code" href="a04558.html#a15">uint</a> totalTri= 0; +00953 <a class="code" href="a04558.html#a15">uint</a> i; +00954 <span class="keywordflow">for</span>(i=0;i<pbList.size();i++) +00955 { +00956 mi->_ShiftedTriangleCache->RdrPass[i].NumTriangles= pbList[i]->getNumTri(); +00957 totalTri+= pbList[i]->getNumTri(); +00958 } +00959 +00960 <span class="comment">// Allocate triangles indices.</span> +00961 mi->_ShiftedTriangleCache->RawIndices.resize(totalTri*3); +00962 <a class="code" href="a04558.html#a11">uint32</a> *rawPtr= mi->_ShiftedTriangleCache->RawIndices.getPtr(); +00963 +00964 <span class="comment">// Second pass, fill ptrs, and fill Arrays</span> +00965 <a class="code" href="a04558.html#a15">uint</a> indexTri= 0; +00966 <span class="keywordflow">for</span>(i=0;i<pbList.size();i++) +00967 { +00968 CShiftedTriangleCache::CRdrPass &dstRdrPass= mi->_ShiftedTriangleCache->RdrPass[i]; +00969 dstRdrPass.Triangles= rawPtr + indexTri*3; +00970 +00971 <span class="comment">// Fill the array</span> +00972 <a class="code" href="a04558.html#a15">uint</a> numTris= pbList[i]->getNumTri(); +00973 <span class="keywordflow">if</span>(numTris) +00974 { +00975 <a class="code" href="a04558.html#a15">uint</a> nIds= numTris*3; +00976 <span class="comment">// index, and fill</span> +00977 <a class="code" href="a04558.html#a11">uint32</a> *pSrcTri= pbList[i]->getTriPointer(); +00978 <a class="code" href="a04558.html#a11">uint32</a> *pDstTri= dstRdrPass.Triangles; +00979 <span class="keywordflow">for</span>(;nIds>0;nIds--,pSrcTri++,pDstTri++) +00980 *pDstTri= *pSrcTri + baseVertex; +00981 } +00982 +00983 <span class="comment">// Next</span> +00984 indexTri+= dstRdrPass.NumTriangles; +00985 } +00986 } +00987 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz507_3" doxytag="NL3D::CMeshMRMSkinnedGeom::updateSkeletonUsage" ></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::CMeshMRMSkinnedGeom::updateSkeletonUsage </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a03399.html">CSkeletonModel</a> * </td> + <td class="mdname" nowrap> <em>sm</em>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>bool </td> + <td class="mdname" nowrap> <em>increment</em></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> +update Skeleton Usage. increment or decrement. computeBonesId must has been called before. +<p> + +<p> +Definition at line <a class="el" href="a06011.html#l01254">1254</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. +<p> +References <a class="el" href="a06394.html#l00098">NL3D::CSkeletonModel::Bones</a>, <a class="el" href="a06393.html#l00213">NL3D::CSkeletonModel::decBoneUsage()</a>, <a class="el" href="a06393.html#l00189">NL3D::CSkeletonModel::incBoneUsage()</a>, <a class="el" href="a05622.html#l00154">nlerror</a>, and <a class="el" href="a05981.html#l00105">uint</a>. +<p> +Referenced by <a class="el" href="a06011.html#l01520">NL3D::CMeshMRMSkinned::updateSkeletonUsage()</a>. +<p> +<div class="fragment"><pre>01255 { +01256 <span class="comment">// For all Bones used.</span> +01257 <span class="keywordflow">for</span>(<a class="code" href="a04558.html#a15">uint</a> i=0; i<<a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr4">_BonesIdExt</a>.size();i++) +01258 { +01259 <a class="code" href="a04558.html#a15">uint</a> boneId= <a class="code" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr4">_BonesIdExt</a>[i]; +01260 <span class="comment">// Some explicit Error.</span> +01261 <span class="keywordflow">if</span>(boneId>=sm->Bones.size()) +01262 <a class="code" href="a04199.html#a3">nlerror</a>(<span class="stringliteral">" Skin is incompatible with Skeleton: tries to use bone %d"</span>, boneId); +01263 <span class="comment">// increment or decrement not Forced, because CMeshGeom use getActiveBoneSkinMatrix().</span> +01264 <span class="keywordflow">if</span>(increment) +01265 sm->incBoneUsage(boneId, CSkeletonModel::UsageNormal); +01266 <span class="keywordflow">else</span> +01267 sm->decBoneUsage(boneId, CSkeletonModel::UsageNormal); +01268 } +01269 } +</pre></div> </td> + </tr> +</table> +<hr><h2>Friends And Related Function Documentation</h2> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz515_0" doxytag="NL3D::CMeshMRMSkinnedGeom::CLod" ></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"> friend class <a class="el" href="a02902.html">CLod</a><code> [friend]</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="a06012.html#l00383">383</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomn0" doxytag="NL3D::CMeshMRMSkinnedGeom::CMRMBuilder" ></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"> friend class <a class="el" href="a02951.html">CMRMBuilder</a><code> [friend]</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="a06012.html#l00299">299</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<hr><h2>Field Documentation</h2> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomr0" doxytag="NL3D::CMeshMRMSkinnedGeom::_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="a02157.html">NLMISC::CAABBoxExt</a> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr0">NL3D::CMeshMRMSkinnedGeom::_BBox</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +For clipping. this is the BB of all vertices of all Lods. +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00552">552</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomr1" doxytag="NL3D::CMeshMRMSkinnedGeom::_BoneIdComputed" ></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 <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr1">NL3D::CMeshMRMSkinnedGeom::_BoneIdComputed</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +This boolean is true if the bones id have been passed in the skeleton. +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00533">533</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomr2" doxytag="NL3D::CMeshMRMSkinnedGeom::_BoneIdExtended" ></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 <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr2">NL3D::CMeshMRMSkinnedGeom::_BoneIdExtended</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +true if the _BonesIdExt have been computed (for bone Usage). +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00535">535</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomr3" doxytag="NL3D::CMeshMRMSkinnedGeom::_BonesId" ></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"> std::vector<<a class="el" href="a04558.html#a10">sint32</a>> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr3">NL3D::CMeshMRMSkinnedGeom::_BonesId</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +This array give the index in the skeleton of the local bones used. computed at first computeBoneId(). +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00543">543</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomr4" doxytag="NL3D::CMeshMRMSkinnedGeom::_BonesIdExt" ></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"> std::vector<<a class="el" href="a04558.html#a10">sint32</a>> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr4">NL3D::CMeshMRMSkinnedGeom::_BonesIdExt</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Same as _BonesId but with parent of bones added. (used for bone usage). +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00545">545</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomr5" doxytag="NL3D::CMeshMRMSkinnedGeom::_BonesName" ></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"> std::vector<std::string> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr5">NL3D::CMeshMRMSkinnedGeom::_BonesName</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +This array give the name of the local bones. +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00541">541</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomr6" doxytag="NL3D::CMeshMRMSkinnedGeom::_BonesSphere" ></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"> std::vector<<a class="el" href="a02291.html">NLMISC::CBSphere</a>> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr6">NL3D::CMeshMRMSkinnedGeom::_BonesSphere</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +see <a class="el" href="a02316.html#NL3D_1_1CWaveMakerModelz1032_0">CTransform::getSkinBoneSphere()</a> doc for the meaning of this value +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00547">547</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomr7" doxytag="NL3D::CMeshMRMSkinnedGeom::_LastLodComputed" ></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="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr7">NL3D::CMeshMRMSkinnedGeom::_LastLodComputed</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Last lod rendered. used with renderSkinGroup*() only. +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00538">538</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz516_0" doxytag="NL3D::CMeshMRMSkinnedGeom::_LevelDetail" ></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="a02959.html">CMRMLevelDetail</a> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz516_0">NL3D::CMeshMRMSkinnedGeom::_LevelDetail</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="a06012.html#l00557">557</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomr8" doxytag="NL3D::CMeshMRMSkinnedGeom::_Lods" ></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"> std::vector<<a class="el" href="a02902.html">CLod</a>> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr8">NL3D::CMeshMRMSkinnedGeom::_Lods</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +List of Lods. +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00550">550</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_11" doxytag="NL3D::CMeshMRMSkinnedGeom::_MeshDataId" ></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#a15">uint</a> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_11">NL3D::CMeshMRMSkinnedGeom::_MeshDataId</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Each time the mesh is loaded/built, this increment. +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00614">614</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz518_1" doxytag="NL3D::CMeshMRMSkinnedGeom::_PreciseClipping" ></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 <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz518_1">NL3D::CMeshMRMSkinnedGeom::_PreciseClipping</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +NB: HERE FOR PACKING ONLY. For clipping. Estimate if we must do a Precise clipping (ie with bboxes). +<p> + +<p> +Definition at line <a class="el" href="a06012.html#l00565">565</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz520_1" doxytag="NL3D::CMeshMRMSkinnedGeom::_ShadowSkinTriangles" ></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"> std::vector<<a class="el" href="a04558.html#a11">uint32</a>> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_1">NL3D::CMeshMRMSkinnedGeom::_ShadowSkinTriangles</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="a06012.html#l00575">575</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz520_2" doxytag="NL3D::CMeshMRMSkinnedGeom::_ShadowSkinVertices" ></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"> std::vector<<a class="el" href="a02907.html">CShadowVertex</a>> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_2">NL3D::CMeshMRMSkinnedGeom::_ShadowSkinVertices</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="a06012.html#l00574">574</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz520_3" doxytag="NL3D::CMeshMRMSkinnedGeom::_SupportShadowSkinGrouping" ></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 <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz520_3">NL3D::CMeshMRMSkinnedGeom::_SupportShadowSkinGrouping</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="a06012.html#l00576">576</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomr9" doxytag="NL3D::CMeshMRMSkinnedGeom::_VBufferFinal" ></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="a02904.html">CPackedVertexBuffer</a> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomr9">NL3D::CMeshMRMSkinnedGeom::_VBufferFinal</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="a06012.html#l00530">530</a> of file <a class="el" href="a06012.html">mesh_mrm_skinned.h</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_0" doxytag="NL3D::CMeshMRMSkinnedGeom::NumCacheVertexNormal1" ></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#a15">uint</a> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_0">NL3D::CMeshMRMSkinnedGeom::NumCacheVertexNormal1</a> = <a class="el" href="a05363.html#a134">NL_BlockByteL1</a> / sizeof(<a class="el" href="a03313.html">CRawVertexNormalSkinned1</a>)<code> [static]</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="a06011.html#l02324">2324</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_1" doxytag="NL3D::CMeshMRMSkinnedGeom::NumCacheVertexNormal2" ></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#a15">uint</a> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_1">NL3D::CMeshMRMSkinnedGeom::NumCacheVertexNormal2</a> = <a class="el" href="a05363.html#a134">NL_BlockByteL1</a> / sizeof(<a class="el" href="a03314.html">CRawVertexNormalSkinned2</a>)<code> [static]</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="a06011.html#l02326">2326</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_2" doxytag="NL3D::CMeshMRMSkinnedGeom::NumCacheVertexNormal3" ></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#a15">uint</a> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_2">NL3D::CMeshMRMSkinnedGeom::NumCacheVertexNormal3</a> = <a class="el" href="a05363.html#a134">NL_BlockByteL1</a> / sizeof(<a class="el" href="a03315.html">CRawVertexNormalSkinned3</a>)<code> [static]</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="a06011.html#l02328">2328</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_3" doxytag="NL3D::CMeshMRMSkinnedGeom::NumCacheVertexNormal4" ></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#a15">uint</a> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_3">NL3D::CMeshMRMSkinnedGeom::NumCacheVertexNormal4</a> = <a class="el" href="a05363.html#a134">NL_BlockByteL1</a> / sizeof(<a class="el" href="a03316.html">CRawVertexNormalSkinned4</a>)<code> [static]</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="a06011.html#l02330">2330</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. </td> + </tr> +</table> +<a class="anchor" name="NL3D_1_1CMeshMRMSkinnedGeomz522_4" doxytag="NL3D::CMeshMRMSkinnedGeom::NumCacheVertexShadow" ></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#a15">uint</a> <a class="el" href="a02901.html#NL3D_1_1CMeshMRMSkinnedGeomz522_4">NL3D::CMeshMRMSkinnedGeom::NumCacheVertexShadow</a> = <a class="el" href="a05363.html#a134">NL_BlockByteL1</a> / sizeof(<a class="el" href="a02907.html">CMeshMRMSkinnedGeom::CShadowVertex</a>)<code> [static]</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="a06011.html#l02333">2333</a> of file <a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a>. </td> + </tr> +</table> +<hr>The documentation for this class was generated from the following files:<ul> +<li><a class="el" href="a06012.html">mesh_mrm_skinned.h</a><li><a class="el" href="a06011.html">mesh_mrm_skinned.cpp</a></ul> +<hr size="1"><address style="align: right;"><small>Generated on Tue Mar 16 06:54:20 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> |