PageRenderTime 54ms CodeModel.GetById 18ms RepoModel.GetById 0ms app.codeStats 1ms

/OgreSDK_vc10_v1-7-2/Docs/api/html/OgreTerrain_8h_source.html

https://bitbucket.org/rosselm/projects
HTML | 904 lines | 895 code | 2 blank | 7 comment | 0 complexity | 43a2da8647484b1f69df1bf5d5aaa1f5 MD5 | raw file
Possible License(s): GPL-2.0, MIT, GPL-3.0, BSD-3-Clause, LGPL-3.0

Large files files are truncated, but you can click here to view the full file

  1. <html>
  2. <head>
  3. <title>OGRE: OgreTerrain.h Source File - OGRE Documentation</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
  4. <link type="text/css" rel="stylesheet" href="doxygen.css">
  5. <link type="text/css" rel="stylesheet" href="tabs.css">
  6. </head>
  7. <body>
  8. <!-- Generated by Doxygen 1.6.3 -->
  9. <div class="navigation" id="top">
  10. <div class="tabs">
  11. <ul>
  12. <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
  13. <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
  14. <li><a href="modules.html"><span>Modules</span></a></li>
  15. <li><a href="namespaces.html"><span>Namespaces</span></a></li>
  16. <li><a href="annotated.html"><span>Classes</span></a></li>
  17. <li class="current"><a href="files.html"><span>Files</span></a></li>
  18. <li><a href="dirs.html"><span>Directories</span></a></li>
  19. </ul>
  20. </div>
  21. <div class="tabs">
  22. <ul>
  23. <li><a href="files.html"><span>File&nbsp;List</span></a></li>
  24. <li><a href="globals.html"><span>File&nbsp;Members</span></a></li>
  25. </ul>
  26. </div>
  27. <div class="navpath"><a class="el" href="dir_31f376a044494af80f84bb936424f217.html">Components</a>&nbsp;&raquo;&nbsp;<a class="el" href="dir_6dbe611a17cc54c3a264a5b73389fb7a.html">Terrain</a>&nbsp;&raquo;&nbsp;<a class="el" href="dir_84d9154b975b37e472c7c06343b217bf.html">include</a>
  28. </div>
  29. </div>
  30. <div class="contents">
  31. <h1>OgreTerrain.h</h1><a href="OgreTerrain_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
  32. <a name="l00002"></a>00002 <span class="comment">-----------------------------------------------------------------------------</span>
  33. <a name="l00003"></a>00003 <span class="comment">This source file is part of OGRE</span>
  34. <a name="l00004"></a>00004 <span class="comment">(Object-oriented Graphics Rendering Engine)</span>
  35. <a name="l00005"></a>00005 <span class="comment">For the latest info, see http://www.ogre3d.org/</span>
  36. <a name="l00006"></a>00006 <span class="comment"></span>
  37. <a name="l00007"></a>00007 <span class="comment">Copyright (c) 2000-2009 Torus Knot Software Ltd</span>
  38. <a name="l00008"></a>00008 <span class="comment"></span>
  39. <a name="l00009"></a>00009 <span class="comment">Permission is hereby granted, free of charge, to any person obtaining a copy</span>
  40. <a name="l00010"></a>00010 <span class="comment">of this software and associated documentation files (the &quot;Software&quot;), to deal</span>
  41. <a name="l00011"></a>00011 <span class="comment">in the Software without restriction, including without limitation the rights</span>
  42. <a name="l00012"></a>00012 <span class="comment">to use, copy, modify, merge, publish, distribute, sublicense, and/or sell</span>
  43. <a name="l00013"></a>00013 <span class="comment">copies of the Software, and to permit persons to whom the Software is</span>
  44. <a name="l00014"></a>00014 <span class="comment">furnished to do so, subject to the following conditions:</span>
  45. <a name="l00015"></a>00015 <span class="comment"></span>
  46. <a name="l00016"></a>00016 <span class="comment">The above copyright notice and this permission notice shall be included in</span>
  47. <a name="l00017"></a>00017 <span class="comment">all copies or substantial portions of the Software.</span>
  48. <a name="l00018"></a>00018 <span class="comment"></span>
  49. <a name="l00019"></a>00019 <span class="comment">THE SOFTWARE IS PROVIDED &quot;AS IS&quot;, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR</span>
  50. <a name="l00020"></a>00020 <span class="comment">IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,</span>
  51. <a name="l00021"></a>00021 <span class="comment">FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE</span>
  52. <a name="l00022"></a>00022 <span class="comment">AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER</span>
  53. <a name="l00023"></a>00023 <span class="comment">LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,</span>
  54. <a name="l00024"></a>00024 <span class="comment">OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN</span>
  55. <a name="l00025"></a>00025 <span class="comment">THE SOFTWARE.</span>
  56. <a name="l00026"></a>00026 <span class="comment">-----------------------------------------------------------------------------</span>
  57. <a name="l00027"></a>00027 <span class="comment">*/</span>
  58. <a name="l00028"></a>00028
  59. <a name="l00029"></a>00029 <span class="preprocessor">#ifndef __Ogre_Terrain_H__</span>
  60. <a name="l00030"></a>00030 <span class="preprocessor"></span><span class="preprocessor">#define __Ogre_Terrain_H__</span>
  61. <a name="l00031"></a>00031 <span class="preprocessor"></span>
  62. <a name="l00032"></a>00032 <span class="preprocessor">#include &quot;<a class="code" href="OgreTerrainPrerequisites_8h.html">OgreTerrainPrerequisites.h</a>&quot;</span>
  63. <a name="l00033"></a>00033 <span class="preprocessor">#include &quot;<a class="code" href="OgreCommon_8h.html">OgreCommon.h</a>&quot;</span>
  64. <a name="l00034"></a>00034 <span class="preprocessor">#include &quot;<a class="code" href="OgreVector3_8h.html">OgreVector3.h</a>&quot;</span>
  65. <a name="l00035"></a>00035 <span class="preprocessor">#include &quot;<a class="code" href="OgreAxisAlignedBox_8h.html">OgreAxisAlignedBox.h</a>&quot;</span>
  66. <a name="l00036"></a>00036 <span class="preprocessor">#include &quot;<a class="code" href="OgreSceneManager_8h.html">OgreSceneManager.h</a>&quot;</span>
  67. <a name="l00037"></a>00037 <span class="preprocessor">#include &quot;<a class="code" href="OgreTerrainMaterialGenerator_8h.html">OgreTerrainMaterialGenerator.h</a>&quot;</span>
  68. <a name="l00038"></a>00038 <span class="preprocessor">#include &quot;<a class="code" href="OgreTerrainLayerBlendMap_8h.html">OgreTerrainLayerBlendMap.h</a>&quot;</span>
  69. <a name="l00039"></a>00039 <span class="preprocessor">#include &quot;<a class="code" href="OgreWorkQueue_8h.html">OgreWorkQueue.h</a>&quot;</span>
  70. <a name="l00040"></a>00040
  71. <a name="l00041"></a>00041 <span class="keyword">namespace </span>Ogre
  72. <a name="l00042"></a>00042 {
  73. <a name="l00261"></a>00261 <span class="keyword">class </span><a class="code" href="OgreTerrainPrerequisites_8h.html#a2fbe49b54cb4b3c3e2757cd3ac167068">_OgreTerrainExport</a> Terrain : <span class="keyword">public</span> SceneManager::Listener,
  74. <a name="l00262"></a>00262 <span class="keyword">public</span> WorkQueue::RequestHandler, <span class="keyword">public</span> WorkQueue::ResponseHandler, <span class="keyword">public</span> <a class="code" href="namespaceOgre.html#ae9aa0b56067c2069d99ccc9894cf9a03">TerrainAlloc</a>
  75. <a name="l00263"></a>00263 {
  76. <a name="l00264"></a>00264 <span class="keyword">public</span>:
  77. <a name="l00268"></a><a class="code" href="classOgre_1_1Terrain.html#ad1b6d65618e1ebc55155214f3b10b337">00268</a> <a class="code" href="classOgre_1_1Terrain.html" title="The main containing class for a chunk of terrain.">Terrain</a>(<a class="code" href="classOgre_1_1SceneManager.html" title="Manages the organisation and rendering of a &amp;#39;scene&amp;#39; i.e.">SceneManager</a>* sm);
  78. <a name="l00269"></a><a class="code" href="classOgre_1_1Terrain.html#afd3641ddf000f3e2ca771408f558131b">00269</a> <span class="keyword">virtual</span> ~<a class="code" href="classOgre_1_1Terrain.html" title="The main containing class for a chunk of terrain.">Terrain</a>();
  79. <a name="l00270"></a><a class="code" href="classOgre_1_1Terrain.html#a5c204799a40adae8b01411ec05dbc841">00270</a>
  80. <a name="l00271"></a>00271 <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#adf2a0cf2e77143b5ee1d38a75e289545">uint32</a> TERRAIN_CHUNK_ID;
  81. <a name="l00272"></a><a class="code" href="classOgre_1_1Terrain.html#ac83d9fa6c4ba65db9c7ad66bbd01b0de">00272</a> <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> TERRAIN_CHUNK_VERSION;
  82. <a name="l00273"></a><a class="code" href="classOgre_1_1Terrain.html#a14ce718231ed706aec11489fc6843d76">00273</a> <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> TERRAIN_MAX_BATCH_SIZE;
  83. <a name="l00274"></a><a class="code" href="classOgre_1_1Terrain.html#a53d1561777a42b20c5aa5a42dd96bf9b">00274</a>
  84. <a name="l00275"></a><a class="code" href="classOgre_1_1Terrain.html#a369a6d0c5e30874dd103c7089406be6c">00275</a> <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#adf2a0cf2e77143b5ee1d38a75e289545">uint32</a> TERRAINLAYERDECLARATION_CHUNK_ID;
  85. <a name="l00276"></a><a class="code" href="classOgre_1_1Terrain.html#adf20ab502696a7e4acf28dec2ebdd0c7">00276</a> <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> TERRAINLAYERDECLARATION_CHUNK_VERSION;
  86. <a name="l00277"></a><a class="code" href="classOgre_1_1Terrain.html#a6b4dc148f017fbd6441bc81f79fe743d">00277</a> <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#adf2a0cf2e77143b5ee1d38a75e289545">uint32</a> TERRAINLAYERSAMPLER_CHUNK_ID;
  87. <a name="l00278"></a><a class="code" href="classOgre_1_1Terrain.html#acb18d059e425a9e6f7677d4dfb2d43ee">00278</a> <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> TERRAINLAYERSAMPLER_CHUNK_VERSION;
  88. <a name="l00279"></a><a class="code" href="classOgre_1_1Terrain.html#ac7837f27d59df9244743172d331e2fb3">00279</a> <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#adf2a0cf2e77143b5ee1d38a75e289545">uint32</a> TERRAINLAYERSAMPLERELEMENT_CHUNK_ID;
  89. <a name="l00280"></a><a class="code" href="classOgre_1_1Terrain.html#a50efd0b73343b76d8cfae1366cfd1cd0">00280</a> <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> TERRAINLAYERSAMPLERELEMENT_CHUNK_VERSION;
  90. <a name="l00281"></a><a class="code" href="classOgre_1_1Terrain.html#a935d5fea06bddac979ae56c7fa13d9da">00281</a> <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#adf2a0cf2e77143b5ee1d38a75e289545">uint32</a> TERRAINLAYERINSTANCE_CHUNK_ID;
  91. <a name="l00282"></a>00282 <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> TERRAINLAYERINSTANCE_CHUNK_VERSION;
  92. <a name="l00283"></a><a class="code" href="classOgre_1_1Terrain.html#aefb36415178b8e15aac901f87b61d3da">00283</a> <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#adf2a0cf2e77143b5ee1d38a75e289545">uint32</a> TERRAINDERIVEDDATA_CHUNK_ID;
  93. <a name="l00284"></a>00284 <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> TERRAINDERIVEDDATA_CHUNK_VERSION;
  94. <a name="l00285"></a><a class="code" href="classOgre_1_1Terrain.html#aa2b09fef0fe773201df2e55cc995d312">00285</a>
  95. <a name="l00286"></a>00286 <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">size_t</span> LOD_MORPH_CUSTOM_PARAM;
  96. <a name="l00287"></a>00287
  97. <a name="l00288"></a>00288 <span class="keyword">typedef</span> <a class="code" href="structOgre_1_1vector.html">vector&lt;Real&gt;::type</a> RealVector;
  98. <a name="l00289"></a><a class="code" href="structOgre_1_1Terrain_1_1LayerInstance.html">00289</a>
  99. <a name="l00292"></a><a class="code" href="structOgre_1_1Terrain_1_1LayerInstance.html#a54f726e8a0c17ec1579a16afa1a9398c">00292</a> <span class="keyword">struct </span><a class="code" href="OgreTerrainPrerequisites_8h.html#a2fbe49b54cb4b3c3e2757cd3ac167068">_OgreTerrainExport</a> <a class="code" href="structOgre_1_1Terrain_1_1LayerInstance.html" title="An instance of a layer, with specific texture names.">LayerInstance</a>
  100. <a name="l00293"></a>00293 {
  101. <a name="l00295"></a>00295 <a class="code" href="namespaceOgre.html#aa3a7b6dfb905e6572d62f0dfa3d4274d" title="Software floating point type.">Real</a> worldSize;
  102. <a name="l00297"></a>00297 <a class="code" href="group__General.html#ga0899c03496d3c25c6555889aa76a78db">StringVector</a> textureNames;
  103. <a name="l00298"></a>00298
  104. <a name="l00299"></a><a class="code" href="classOgre_1_1Terrain.html#a7f4f256f962849538b8e46eebd6da94c">00299</a> <a class="code" href="structOgre_1_1Terrain_1_1LayerInstance.html" title="An instance of a layer, with specific texture names.">LayerInstance</a>()
  105. <a name="l00300"></a>00300 : worldSize(100) {}
  106. <a name="l00301"></a>00301 };
  107. <a name="l00302"></a><a class="code" href="classOgre_1_1Terrain.html#aca4fcebfb7ed4684682347d325477e91">00302</a> <span class="keyword">typedef</span> <a class="code" href="structOgre_1_1vector.html">vector&lt;LayerInstance&gt;::type</a> LayerInstanceList;
  108. <a name="l00303"></a>00303
  109. <a name="l00305"></a><a class="code" href="classOgre_1_1Terrain.html#aca4fcebfb7ed4684682347d325477e91ac4699c4f99bea344a309d5544b33c140">00305</a> <span class="keyword">enum</span> <a class="code" href="classOgre_1_1Terrain.html#aca4fcebfb7ed4684682347d325477e91" title="The alignment of the terrain.">Alignment</a>
  110. <a name="l00306"></a>00306 {
  111. <a name="l00308"></a>00308 ALIGN_X_Z = 0,
  112. <a name="l00310"></a>00310 ALIGN_X_Y = 1,
  113. <a name="l00312"></a>00312 ALIGN_Y_Z = 2
  114. <a name="l00313"></a>00313 };
  115. <a name="l00314"></a>00314
  116. <a name="l00318"></a><a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a9cc48b1e14f6974f46bf9da947f8fc76">00318</a> <span class="keyword">struct </span><a class="code" href="structOgre_1_1Terrain_1_1ImportData.html" title="Structure encapsulating import data that you may use to bootstrap the terrain without...">ImportData</a>
  117. <a name="l00319"></a>00319 {
  118. <a name="l00321"></a>00321 <a class="code" href="classOgre_1_1Terrain.html#aca4fcebfb7ed4684682347d325477e91" title="The alignment of the terrain.">Alignment</a> terrainAlign;
  119. <a name="l00323"></a>00323 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> terrainSize;
  120. <a name="l00329"></a>00329 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> maxBatchSize;
  121. <a name="l00340"></a>00340 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> minBatchSize;
  122. <a name="l00341"></a>00341
  123. <a name="l00346"></a><a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a43509d8a986b1b733d010300487425a5">00346</a> <a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a> pos;
  124. <a name="l00347"></a>00347
  125. <a name="l00349"></a>00349 <a class="code" href="namespaceOgre.html#aa3a7b6dfb905e6572d62f0dfa3d4274d" title="Software floating point type.">Real</a> worldSize;
  126. <a name="l00350"></a>00350
  127. <a name="l00356"></a>00356 <a class="code" href="classOgre_1_1Image.html" title="Class representing an image file.">Image</a>* inputImage;
  128. <a name="l00357"></a>00357
  129. <a name="l00362"></a>00362 <span class="keywordtype">float</span>* inputFloat;
  130. <a name="l00363"></a>00363
  131. <a name="l00367"></a>00367 <span class="keywordtype">float</span> constantHeight;
  132. <a name="l00368"></a>00368
  133. <a name="l00376"></a><a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#ae97c725c89e0c789e5099fd387953020">00376</a> <span class="keywordtype">bool</span> deleteInputData;
  134. <a name="l00377"></a>00377
  135. <a name="l00379"></a>00379 <a class="code" href="namespaceOgre.html#aa3a7b6dfb905e6572d62f0dfa3d4274d" title="Software floating point type.">Real</a> inputScale;
  136. <a name="l00381"></a>00381 <a class="code" href="namespaceOgre.html#aa3a7b6dfb905e6572d62f0dfa3d4274d" title="Software floating point type.">Real</a> inputBias;
  137. <a name="l00382"></a>00382
  138. <a name="l00387"></a>00387 <a class="code" href="structOgre_1_1TerrainLayerDeclaration.html" title="The definition of the information each layer will contain in this terrain.">TerrainLayerDeclaration</a> layerDeclaration;
  139. <a name="l00392"></a>00392 LayerInstanceList layerList;
  140. <a name="l00393"></a>00393
  141. <a name="l00394"></a>00394 <a class="code" href="structOgre_1_1Terrain_1_1ImportData.html" title="Structure encapsulating import data that you may use to bootstrap the terrain without...">ImportData</a>()
  142. <a name="l00395"></a>00395 : terrainAlign(ALIGN_X_Z)
  143. <a name="l00396"></a>00396 , terrainSize(1025)
  144. <a name="l00397"></a>00397 , maxBatchSize(65)
  145. <a name="l00398"></a>00398 , minBatchSize(17)
  146. <a name="l00399"></a>00399 , pos(<a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a>::ZERO)
  147. <a name="l00400"></a>00400 , worldSize(1000)
  148. <a name="l00401"></a>00401 , inputImage(0)
  149. <a name="l00402"></a>00402 , inputFloat(0)
  150. <a name="l00403"></a>00403 , constantHeight(0)
  151. <a name="l00404"></a>00404 , deleteInputData(false)
  152. <a name="l00405"></a>00405 , inputScale(1.0)
  153. <a name="l00406"></a>00406 , inputBias(0.0)
  154. <a name="l00407"></a>00407 {
  155. <a name="l00408"></a><a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a94c34664786d5059f7a9ef36e061890e">00408</a>
  156. <a name="l00409"></a>00409 }
  157. <a name="l00410"></a>00410
  158. <a name="l00411"></a>00411 <a class="code" href="structOgre_1_1Terrain_1_1ImportData.html" title="Structure encapsulating import data that you may use to bootstrap the terrain without...">ImportData</a>(<span class="keyword">const</span> <a class="code" href="structOgre_1_1Terrain_1_1ImportData.html" title="Structure encapsulating import data that you may use to bootstrap the terrain without...">ImportData</a>&amp; rhs)
  159. <a name="l00412"></a>00412 : terrainAlign(ALIGN_X_Z)
  160. <a name="l00413"></a>00413 , terrainSize(1025)
  161. <a name="l00414"></a>00414 , maxBatchSize(65)
  162. <a name="l00415"></a>00415 , minBatchSize(17)
  163. <a name="l00416"></a>00416 , pos(<a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a>::ZERO)
  164. <a name="l00417"></a>00417 , worldSize(1000)
  165. <a name="l00418"></a>00418 , inputImage(0)
  166. <a name="l00419"></a>00419 , inputFloat(0)
  167. <a name="l00420"></a>00420 , constantHeight(0)
  168. <a name="l00421"></a>00421 , deleteInputData(false)
  169. <a name="l00422"></a>00422 , inputScale(1.0)
  170. <a name="l00423"></a>00423 , inputBias(0.0)
  171. <a name="l00424"></a>00424 {
  172. <a name="l00425"></a><a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#aabbbf63a35790a9b414acaa1e20baf93">00425</a> *<span class="keyword">this</span> = rhs;
  173. <a name="l00426"></a>00426 }
  174. <a name="l00427"></a>00427
  175. <a name="l00428"></a>00428 <a class="code" href="structOgre_1_1Terrain_1_1ImportData.html" title="Structure encapsulating import data that you may use to bootstrap the terrain without...">ImportData</a>&amp; operator=(<span class="keyword">const</span> <a class="code" href="structOgre_1_1Terrain_1_1ImportData.html" title="Structure encapsulating import data that you may use to bootstrap the terrain without...">ImportData</a>&amp; rhs)
  176. <a name="l00429"></a>00429 {
  177. <a name="l00430"></a>00430 <span class="comment">// basic copy</span>
  178. <a name="l00431"></a>00431 terrainAlign = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a9cc48b1e14f6974f46bf9da947f8fc76" title="The alignment of the terrain.">terrainAlign</a>;
  179. <a name="l00432"></a>00432 terrainSize = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a0b5bc1f24bcc9003e5ed0ccb850711f8" title="Terrain size (along one edge) in vertices; must be 2^n+1.">terrainSize</a>;
  180. <a name="l00433"></a>00433 maxBatchSize = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#acebf6cfa7dcb63b4725ed1dc2e63a9f2" title="Maximum batch size (along one edge) in vertices; must be 2^n+1 and &amp;lt;= 65.">maxBatchSize</a>;
  181. <a name="l00434"></a>00434 minBatchSize = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a60b1682048188053cc885097eb2383c6" title="Minimum batch size (along one edge) in vertices; must be 2^n+1.">minBatchSize</a>;
  182. <a name="l00435"></a>00435 pos = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#ade0d3e9baacc9408bc08ce2531f177b4" title="Position of the terrain.">pos</a>;
  183. <a name="l00436"></a>00436 worldSize = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a43509d8a986b1b733d010300487425a5" title="The world size of the terrain.">worldSize</a>;
  184. <a name="l00437"></a>00437 constantHeight = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a210633812bf4ae671e19736a934079b3" title="If neither inputImage or inputFloat are supplied, the constant height at which the...">constantHeight</a>;
  185. <a name="l00438"></a>00438 deleteInputData = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#ab5bbdf7852ee1d2192c421c17df237e7" title="Whether this structure should &amp;#39;own&amp;#39; the input data (inputImage and inputFloat)...">deleteInputData</a>;
  186. <a name="l00439"></a>00439 inputScale = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#ae97c725c89e0c789e5099fd387953020" title="How to scale the input values provided (if any).">inputScale</a>;
  187. <a name="l00440"></a>00440 inputBias = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#aa92240ffea408a3ff250e8e8233789bb" title="How to bias the input values provided (if any).">inputBias</a>;
  188. <a name="l00441"></a>00441 layerDeclaration = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#ae3203cf7a78bd3ed0cd75ffe3c107a2e" title="Definition of the contents of each layer (required).">layerDeclaration</a>;
  189. <a name="l00442"></a>00442 layerList = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a3d892ce610f8e6aec873528d042fe72b" title="List of layer structures, one for each layer required.">layerList</a>;
  190. <a name="l00443"></a>00443
  191. <a name="l00444"></a>00444 <span class="comment">// By-value copies in ownership cases</span>
  192. <a name="l00445"></a>00445 <span class="keywordflow">if</span> (rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#ab5bbdf7852ee1d2192c421c17df237e7" title="Whether this structure should &amp;#39;own&amp;#39; the input data (inputImage and inputFloat)...">deleteInputData</a>)
  193. <a name="l00446"></a>00446 {
  194. <a name="l00447"></a>00447 <span class="keywordflow">if</span> (rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a61b189d3b9768810d747f35f7d141e79" title="Optional heightmap providing the initial heights for the terrain.">inputImage</a>)
  195. <a name="l00448"></a>00448 inputImage = <a class="code" href="group__Memory.html#gab5fc1358fd5a889de0a06d07e45df1ff">OGRE_NEW</a> <a class="code" href="classOgre_1_1Image.html" title="Class representing an image file.">Image</a>(*rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a61b189d3b9768810d747f35f7d141e79" title="Optional heightmap providing the initial heights for the terrain.">inputImage</a>);
  196. <a name="l00449"></a>00449 <span class="keywordflow">else</span>
  197. <a name="l00450"></a>00450 inputImage = 0;
  198. <a name="l00451"></a>00451
  199. <a name="l00452"></a>00452 <span class="keywordflow">if</span> (rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#aaab91a388f7bab0e1d00a858bbeb5902" title="Optional list of terrainSize * terrainSize floats defining the terrain.">inputFloat</a>)
  200. <a name="l00453"></a>00453 {
  201. <a name="l00454"></a>00454 inputFloat = <a class="code" href="group__Memory.html#ga3211e4a6a806aa789b38dce2432ef472" title="Allocate a block of memory for a primitive type, and indicate the category of usage...">OGRE_ALLOC_T</a>(<span class="keywordtype">float</span>, terrainSize*terrainSize, <a class="code" href="group__Memory.html#gga830fab51be174d6f2849857cb1abb36aaf9e04ff475de4493bc942a9c73da4c2e" title="Geometry held in main memory.">MEMCATEGORY_GEOMETRY</a>);
  202. <a name="l00455"></a>00455 memcpy(inputFloat, rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#aaab91a388f7bab0e1d00a858bbeb5902" title="Optional list of terrainSize * terrainSize floats defining the terrain.">inputFloat</a>, <span class="keyword">sizeof</span>(<span class="keywordtype">float</span>) * terrainSize*terrainSize);
  203. <a name="l00456"></a>00456 }
  204. <a name="l00457"></a>00457 <span class="keywordflow">else</span>
  205. <a name="l00458"></a>00458 inputFloat = 0;
  206. <a name="l00459"></a>00459 }
  207. <a name="l00460"></a>00460 <span class="keywordflow">else</span>
  208. <a name="l00461"></a>00461 {
  209. <a name="l00462"></a>00462 <span class="comment">// re-use pointers</span>
  210. <a name="l00463"></a>00463 inputImage = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a61b189d3b9768810d747f35f7d141e79" title="Optional heightmap providing the initial heights for the terrain.">inputImage</a>;
  211. <a name="l00464"></a>00464 inputFloat = rhs.<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#aaab91a388f7bab0e1d00a858bbeb5902" title="Optional list of terrainSize * terrainSize floats defining the terrain.">inputFloat</a>;
  212. <a name="l00465"></a>00465 }
  213. <a name="l00466"></a>00466 <span class="keywordflow">return</span> *<span class="keyword">this</span>;
  214. <a name="l00467"></a><a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#a7a5f66953eabbc5221f36ee476f98d47">00467</a> }
  215. <a name="l00468"></a>00468
  216. <a name="l00470"></a>00470 <span class="keywordtype">void</span> destroy()
  217. <a name="l00471"></a>00471 {
  218. <a name="l00472"></a>00472 <span class="keywordflow">if</span> (deleteInputData)
  219. <a name="l00473"></a>00473 {
  220. <a name="l00474"></a>00474 <a class="code" href="group__Memory.html#gad18eff671a00617b21c8e35a7f545690">OGRE_DELETE</a> inputImage;
  221. <a name="l00475"></a>00475 <a class="code" href="group__Memory.html#gacfd8dc937cf390c7bff05495f0dc10cf" title="Free the memory allocated with OGRE_MALLOC or OGRE_ALLOC_T. Category is required...">OGRE_FREE</a>(inputFloat, <a class="code" href="group__Memory.html#gga830fab51be174d6f2849857cb1abb36aaf9e04ff475de4493bc942a9c73da4c2e" title="Geometry held in main memory.">MEMCATEGORY_GEOMETRY</a>);
  222. <a name="l00476"></a>00476 inputImage = 0;
  223. <a name="l00477"></a>00477 inputFloat = 0;
  224. <a name="l00478"></a>00478 }
  225. <a name="l00479"></a><a class="code" href="structOgre_1_1Terrain_1_1ImportData.html#ab44221d85f1c10b8c2be75b476d89440">00479</a>
  226. <a name="l00480"></a>00480 }
  227. <a name="l00481"></a>00481
  228. <a name="l00482"></a>00482 ~<a class="code" href="structOgre_1_1Terrain_1_1ImportData.html" title="Structure encapsulating import data that you may use to bootstrap the terrain without...">ImportData</a>()
  229. <a name="l00483"></a>00483 {
  230. <a name="l00484"></a>00484 destroy();
  231. <a name="l00485"></a>00485 }
  232. <a name="l00486"></a>00486
  233. <a name="l00487"></a><a class="code" href="classOgre_1_1Terrain.html#a2d0c6e14298e6a196148388ca2ffa9e2">00487</a> };
  234. <a name="l00488"></a>00488
  235. <a name="l00490"></a><a class="code" href="classOgre_1_1Terrain.html#a2d0c6e14298e6a196148388ca2ffa9e2aed82e8f7f45fcb5faeef6158c9d1ff3a">00490</a> <span class="keyword">enum</span> <a class="code" href="classOgre_1_1Terrain.html#a2d0c6e14298e6a196148388ca2ffa9e2" title="Neighbour index enumeration - indexed anticlockwise from East like angles.">NeighbourIndex</a>
  236. <a name="l00491"></a><a class="code" href="classOgre_1_1Terrain.html#a2d0c6e14298e6a196148388ca2ffa9e2a07b3c537d34f5c7e1e3e79634dfcac1d">00491</a> {
  237. <a name="l00492"></a><a class="code" href="classOgre_1_1Terrain.html#a2d0c6e14298e6a196148388ca2ffa9e2a8795dff5bfc2240747ee0a843a900c71">00492</a> NEIGHBOUR_EAST = 0,
  238. <a name="l00493"></a><a class="code" href="classOgre_1_1Terrain.html#a2d0c6e14298e6a196148388ca2ffa9e2a3a45b8d00d2ba435e61cdc99c94b0a91">00493</a> NEIGHBOUR_NORTHEAST = 1,
  239. <a name="l00494"></a><a class="code" href="classOgre_1_1Terrain.html#a2d0c6e14298e6a196148388ca2ffa9e2aec43a04404ef9873e7d43c094e097e40">00494</a> NEIGHBOUR_NORTH = 2,
  240. <a name="l00495"></a><a class="code" href="classOgre_1_1Terrain.html#a2d0c6e14298e6a196148388ca2ffa9e2a8c91ce1d5f82d7525102bc91fde0df2d">00495</a> NEIGHBOUR_NORTHWEST = 3,
  241. <a name="l00496"></a><a class="code" href="classOgre_1_1Terrain.html#a2d0c6e14298e6a196148388ca2ffa9e2a4183a4a8b0f78832395fa0aa981f07bf">00496</a> NEIGHBOUR_WEST = 4,
  242. <a name="l00497"></a>00497 NEIGHBOUR_SOUTHWEST = 5,
  243. <a name="l00498"></a><a class="code" href="classOgre_1_1Terrain.html#a2d0c6e14298e6a196148388ca2ffa9e2a5ba448a51833e6c8eea28884a706834c">00498</a> NEIGHBOUR_SOUTH = 6,
  244. <a name="l00499"></a>00499 NEIGHBOUR_SOUTHEAST = 7,
  245. <a name="l00500"></a>00500
  246. <a name="l00501"></a><a class="code" href="classOgre_1_1Terrain.html#a7c381de393a45f50b946a0deb82d3e94">00501</a> NEIGHBOUR_COUNT = 8
  247. <a name="l00502"></a>00502 };
  248. <a name="l00503"></a>00503
  249. <a name="l00504"></a><a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781">00504</a> <a class="code" href="classOgre_1_1SceneManager.html" title="Manages the organisation and rendering of a &amp;#39;scene&amp;#39; i.e.">SceneManager</a>* getSceneManager()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> mSceneMgr; }
  250. <a name="l00505"></a>00505
  251. <a name="l00507"></a><a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781a0a7049246e4a77e37dcea36fd35c4daf">00507</a> <span class="keyword">enum</span> <a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781" title="Enumeration of relative spaces that you might want to use to address the terrain...">Space</a>
  252. <a name="l00508"></a>00508 {
  253. <a name="l00510"></a>00510 WORLD_SPACE = 0,
  254. <a name="l00512"></a>00512 LOCAL_SPACE = 1,
  255. <a name="l00516"></a>00516 TERRAIN_SPACE = 2,
  256. <a name="l00520"></a>00520 POINT_SPACE = 3
  257. <a name="l00521"></a>00521 };
  258. <a name="l00522"></a>00522
  259. <a name="l00527"></a><a class="code" href="classOgre_1_1Terrain_1_1GpuBufferAllocator.html#adafa196fd89b566090806bde188bbf33">00527</a> <span class="keyword">class </span><a class="code" href="OgreTerrainPrerequisites_8h.html#a2fbe49b54cb4b3c3e2757cd3ac167068">_OgreTerrainExport</a> <a class="code" href="classOgre_1_1Terrain_1_1GpuBufferAllocator.html" title="Interface used to by the Terrain instance to allocate GPU buffers.">GpuBufferAllocator</a> : <span class="keyword">public</span> <a class="code" href="classOgre_1_1AllocatedObject.html" title="Superclass for all objects that wish to use custom memory allocators when their new...">TerrainAlloc</a>
  260. <a name="l00528"></a><a class="code" href="classOgre_1_1Terrain_1_1GpuBufferAllocator.html#ab50e9928256ddbd09462938a7e13e3c8">00528</a> {
  261. <a name="l00529"></a>00529 <span class="keyword">public</span>:
  262. <a name="l00530"></a>00530 <a class="code" href="classOgre_1_1Terrain_1_1GpuBufferAllocator.html" title="Interface used to by the Terrain instance to allocate GPU buffers.">GpuBufferAllocator</a>() {}
  263. <a name="l00531"></a>00531 <span class="keyword">virtual</span> ~<a class="code" href="classOgre_1_1Terrain_1_1GpuBufferAllocator.html" title="Interface used to by the Terrain instance to allocate GPU buffers.">GpuBufferAllocator</a>() {}
  264. <a name="l00532"></a>00532
  265. <a name="l00538"></a>00538 <span class="keyword">virtual</span> <span class="keywordtype">void</span> allocateVertexBuffers(<a class="code" href="classOgre_1_1Terrain.html" title="The main containing class for a chunk of terrain.">Terrain</a>* forTerrain, <span class="keywordtype">size_t</span> numVertices, <a class="code" href="classOgre_1_1HardwareVertexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareVertexBufferSharedPtr</a>&amp; destPos, <a class="code" href="classOgre_1_1HardwareVertexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareVertexBufferSharedPtr</a>&amp; destDelta) = 0;
  266. <a name="l00541"></a>00541 <span class="keyword">virtual</span> <span class="keywordtype">void</span> freeVertexBuffers(<span class="keyword">const</span> <a class="code" href="classOgre_1_1HardwareVertexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareVertexBufferSharedPtr</a>&amp; posbuf, <span class="keyword">const</span> <a class="code" href="classOgre_1_1HardwareVertexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareVertexBufferSharedPtr</a>&amp; deltabuf) = 0;
  267. <a name="l00542"></a>00542
  268. <a name="l00557"></a>00557 <span class="keyword">virtual</span> <a class="code" href="classOgre_1_1HardwareIndexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareIndexBufferSharedPtr</a> getSharedIndexBuffer(<a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> batchSize,
  269. <a name="l00558"></a>00558 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> vdatasize, <span class="keywordtype">size_t</span> vertexIncrement, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> xoffset, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> yoffset, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> numSkirtRowsCols,
  270. <a name="l00559"></a>00559 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> skirtRowColSkip) = 0;
  271. <a name="l00560"></a>00560
  272. <a name="l00562"></a>00562 <span class="keyword">virtual</span> <span class="keywordtype">void</span> freeAllBuffers() = 0;
  273. <a name="l00563"></a><a class="code" href="classOgre_1_1Terrain_1_1DefaultGpuBufferAllocator.html">00563</a>
  274. <a name="l00564"></a>00564 };
  275. <a name="l00566"></a>00566 <span class="keyword">class </span><a class="code" href="OgreTerrainPrerequisites_8h.html#a2fbe49b54cb4b3c3e2757cd3ac167068">_OgreTerrainExport</a> <a class="code" href="classOgre_1_1Terrain_1_1DefaultGpuBufferAllocator.html" title="Standard implementation of a buffer allocator which re-uses buffers.">DefaultGpuBufferAllocator</a> : <span class="keyword">public</span> <a class="code" href="classOgre_1_1Terrain_1_1GpuBufferAllocator.html" title="Interface used to by the Terrain instance to allocate GPU buffers.">GpuBufferAllocator</a>
  276. <a name="l00567"></a>00567 {
  277. <a name="l00568"></a>00568 <span class="keyword">public</span>:
  278. <a name="l00569"></a>00569 <a class="code" href="classOgre_1_1Terrain_1_1DefaultGpuBufferAllocator.html" title="Standard implementation of a buffer allocator which re-uses buffers.">DefaultGpuBufferAllocator</a>();
  279. <a name="l00570"></a>00570 ~<a class="code" href="classOgre_1_1Terrain_1_1DefaultGpuBufferAllocator.html" title="Standard implementation of a buffer allocator which re-uses buffers.">DefaultGpuBufferAllocator</a>();
  280. <a name="l00571"></a>00571 <span class="keywordtype">void</span> allocateVertexBuffers(<a class="code" href="classOgre_1_1Terrain.html" title="The main containing class for a chunk of terrain.">Terrain</a>* forTerrain, <span class="keywordtype">size_t</span> numVertices, <a class="code" href="classOgre_1_1HardwareVertexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareVertexBufferSharedPtr</a>&amp; destPos, <a class="code" href="classOgre_1_1HardwareVertexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareVertexBufferSharedPtr</a>&amp; destDelta);
  281. <a name="l00572"></a>00572 <span class="keywordtype">void</span> freeVertexBuffers(<span class="keyword">const</span> <a class="code" href="classOgre_1_1HardwareVertexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareVertexBufferSharedPtr</a>&amp; posbuf, <span class="keyword">const</span> <a class="code" href="classOgre_1_1HardwareVertexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareVertexBufferSharedPtr</a>&amp; deltabuf);
  282. <a name="l00573"></a>00573 <a class="code" href="classOgre_1_1HardwareIndexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareIndexBufferSharedPtr</a> getSharedIndexBuffer(<a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> batchSize,
  283. <a name="l00574"></a>00574 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> vdatasize, <span class="keywordtype">size_t</span> vertexIncrement, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> xoffset, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> yoffset, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> numSkirtRowsCols,
  284. <a name="l00575"></a>00575 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> skirtRowColSkip);
  285. <a name="l00576"></a>00576 <span class="keywordtype">void</span> freeAllBuffers();
  286. <a name="l00577"></a>00577
  287. <a name="l00581"></a>00581 <span class="keywordtype">void</span> warmStart(<span class="keywordtype">size_t</span> numInstances, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> terrainSize, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> maxBatchSize,
  288. <a name="l00582"></a><a class="code" href="classOgre_1_1Terrain_1_1DefaultGpuBufferAllocator.html#a55379cc5331736568c8a73ad2cc5c5ed">00582</a> <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> minBatchSize);
  289. <a name="l00583"></a><a class="code" href="classOgre_1_1Terrain_1_1DefaultGpuBufferAllocator.html#a8820ed742f93ba0b13da637d71b934a9">00583</a>
  290. <a name="l00584"></a><a class="code" href="classOgre_1_1Terrain_1_1DefaultGpuBufferAllocator.html#a1f0cda9f231eb97e7fd0367ddc8055c9">00584</a> <span class="keyword">protected</span>:
  291. <a name="l00585"></a><a class="code" href="classOgre_1_1Terrain_1_1DefaultGpuBufferAllocator.html#aaa440fddd2249c96890533c6d20e21a6">00585</a> <span class="keyword">typedef</span> <a class="code" href="structOgre_1_1list.html">list&lt;HardwareVertexBufferSharedPtr&gt;::type</a> VBufList;
  292. <a name="l00586"></a><a class="code" href="classOgre_1_1Terrain_1_1DefaultGpuBufferAllocator.html#a80d57bd40f5fa54dc002dc208fc096bb">00586</a> VBufList mFreePosBufList;
  293. <a name="l00587"></a>00587 VBufList mFreeDeltaBufList;
  294. <a name="l00588"></a>00588 <span class="keyword">typedef</span> <a class="code" href="structOgre_1_1map.html">map&lt;uint32, HardwareIndexBufferSharedPtr&gt;::type</a> IBufMap;
  295. <a name="l00589"></a>00589 IBufMap mSharedIBufMap;
  296. <a name="l00590"></a>00590
  297. <a name="l00591"></a>00591 <a class="code" href="namespaceOgre.html#adf2a0cf2e77143b5ee1d38a75e289545">uint32</a> hashIndexBuffer(<a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> batchSize,
  298. <a name="l00592"></a>00592 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> vdatasize, <span class="keywordtype">size_t</span> vertexIncrement, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> xoffset, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> yoffset, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> numSkirtRowsCols,
  299. <a name="l00593"></a>00593 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> skirtRowColSkip);
  300. <a name="l00594"></a>00594 <a class="code" href="classOgre_1_1HardwareVertexBufferSharedPtr.html" title="Shared pointer implementation used to share index buffers.">HardwareVertexBufferSharedPtr</a> getVertexBuffer(VBufList&amp; <a class="code" href="structOgre_1_1list.html">list</a>, <span class="keywordtype">size_t</span> vertexSize, <span class="keywordtype">size_t</span> numVertices);
  301. <a name="l00595"></a>00595
  302. <a name="l00596"></a>00596 };
  303. <a name="l00597"></a>00597
  304. <a name="l00602"></a>00602 <span class="keywordtype">void</span> setGpuBufferAllocator(<a class="code" href="classOgre_1_1Terrain_1_1GpuBufferAllocator.html" title="Interface used to by the Terrain instance to allocate GPU buffers.">GpuBufferAllocator</a>* alloc);
  305. <a name="l00603"></a>00603
  306. <a name="l00605"></a>00605 <a class="code" href="classOgre_1_1Terrain_1_1GpuBufferAllocator.html" title="Interface used to by the Terrain instance to allocate GPU buffers.">GpuBufferAllocator</a>* getGpuBufferAllocator();
  307. <a name="l00606"></a>00606
  308. <a name="l00608"></a>00608 <span class="keyword">static</span> <span class="keywordtype">size_t</span> _getNumIndexesForBatchSize(<a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> batchSize);
  309. <a name="l00620"></a>00620 <span class="keyword">static</span> <span class="keywordtype">void</span> _populateIndexBuffer(<a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a>* pIndexes, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> batchSize,
  310. <a name="l00621"></a>00621 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> vdatasize, <span class="keywordtype">size_t</span> vertexIncrement, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> xoffset, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> yoffset, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> numSkirtRowsCols,
  311. <a name="l00622"></a>00622 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> skirtRowColSkip);
  312. <a name="l00623"></a>00623
  313. <a name="l00625"></a>00625 <span class="keyword">static</span> <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> _calcSkirtVertexIndex(<a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> mainIndex, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> vdatasize, <span class="keywordtype">bool</span> isCol,
  314. <a name="l00626"></a>00626 <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> numSkirtRowsCols, <a class="code" href="namespaceOgre.html#aa8263b218e7d187ad5ef03a73a6ad7fd">uint16</a> skirtRowColSkip);
  315. <a name="l00627"></a>00627
  316. <a name="l00634"></a>00634 <span class="keywordtype">void</span> convertPosition(<a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781" title="Enumeration of relative spaces that you might want to use to address the terrain...">Space</a> inSpace, <span class="keyword">const</span> <a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a>&amp; inPos, <a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781" title="Enumeration of relative spaces that you might want to use to address the terrain...">Space</a> outSpace, <a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a>&amp; outPos) <span class="keyword">const</span>;
  317. <a name="l00641"></a>00641 <a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a> convertPosition(<a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781" title="Enumeration of relative spaces that you might want to use to address the terrain...">Space</a> inSpace, <span class="keyword">const</span> <a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a>&amp; inPos, <a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781" title="Enumeration of relative spaces that you might want to use to address the terrain...">Space</a> outSpace) <span class="keyword">const</span>;
  318. <a name="l00648"></a>00648 <span class="keywordtype">void</span> convertDirection(<a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781" title="Enumeration of relative spaces that you might want to use to address the terrain...">Space</a> inSpace, <span class="keyword">const</span> <a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a>&amp; inDir, <a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781" title="Enumeration of relative spaces that you might want to use to address the terrain...">Space</a> outSpace, <a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a>&amp; outDir) <span class="keyword">const</span>;
  319. <a name="l00655"></a>00655 <a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a> convertDirection(<a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781" title="Enumeration of relative spaces that you might want to use to address the terrain...">Space</a> inSpace, <span class="keyword">const</span> <a class="code" href="classOgre_1_1Vector3.html" title="Standard 3-dimensional vector.">Vector3</a>&amp; inDir, <a class="code" href="classOgre_1_1Terrain.html#aebf8a7aadb5de3a0669d41acfd58d781" title="Enumeration of relative spaces that you might want to use to address the terrain...">Space</a> outSpace) <span class="keyword">const</span>;
  320. <a name="l00656"></a>00656
  321. <a name="l00661"></a>00661 <span class="keywordtype">void</span> setResourceGroup(<span class="keyword">const</span> <a class="code" href="namespaceOgre.html#af73bbdc8bed8a3e6fcd56bb8fa188c45">String</a>&amp; resGroup) { mResourceGroup = resGroup; }
  322. <a name="l00662"></a>00662
  323. <a name="l00666"></a>00666 <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#af73bbdc8bed8a3e6fcd56bb8fa188c45">String</a>&amp; getResourceGroup()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> mResourceGroup; }
  324. <a name="l00667"></a>00667
  325. <a name="l00670"></a>00670 <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#af73bbdc8bed8a3e6fcd56bb8fa188c45">String</a>&amp; _getDerivedResourceGroup() <span class="keyword">const</span>;
  326. <a name="l00671"></a>00671
  327. <a name="l00680"></a>00680 <span class="keywordtype">void</span> save(<span class="keyword">const</span> <a class="code" href="namespaceOgre.html#af73bbdc8bed8a3e6fcd56bb8fa188c45">String</a>&amp; filename);
  328. <a name="l00686"></a>00686 <span class="keywordtype">void</span> save(StreamSerialiser&amp; stream);
  329. <a name="l00687"></a>00687
  330. <a name="l00694"></a>00694 <span class="keywordtype">bool</span> prepare(<span class="keyword">const</span> <a class="code" href="namespaceOgre.html#af73bbdc8bed8a3e6fcd56bb8fa188c45">String</a>&amp; filename);
  331. <a name="l00701"></a>00701 <span class="keywordtype">bool</span> prepare(StreamSerialiser&amp; stream);
  332. <a name="l00702"></a>00702
  333. <a name="l00708"></a>00708 <span class="keywordtype">bool</span> prepare(<span class="keyword">const</span> ImportData&amp; importData);
  334. <a name="l00709"></a>00709
  335. <a name="l00715"></a>00715 <span class="keywordtype">void</span> load(<span class="keyword">const</span> <a cl

Large files files are truncated, but you can click here to view the full file