TreesGeometry.html 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>TreesGeometry - Three.js Docs</title>
  6. <meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
  7. <script src="../scripts/highlight.min.js"></script>
  8. <link type="text/css" rel="stylesheet" href="../styles/highlight-three.css">
  9. <link type="text/css" rel="stylesheet" href="../styles/page.css">
  10. </head>
  11. <body>
  12. <p class="inheritance" translate="no"><a href="EventDispatcher.html">EventDispatcher</a> → <a href="BufferGeometry.html">BufferGeometry</a> → </p>
  13. <h1 translate="no">TreesGeometry</h1>
  14. <section>
  15. <header>
  16. <div class="class-description"><p>A procedural trees geometry.</p></div>
  17. </header>
  18. <article>
  19. <h2 class="subsection-title">Import</h2>
  20. <p><span translate="no">TreesGeometry</span> is an addon, and must be imported explicitly, see <a href="https://threejs.org/manual/#en/installation" target="_blank" rel="noopener">Installation#Addons</a>.</p>
  21. <pre><code class="language-js">import { TreesGeometry } from 'three/addons/misc/RollerCoaster.js';</code></pre>
  22. <div class="container-overview">
  23. <h2>Constructor</h2>
  24. <h3 class="name name-method" id="TreesGeometry" translate="no">new <a href="#TreesGeometry">TreesGeometry</a><span class="signature">( landscape : <span class="param-type"><a href="Mesh.html">Mesh</a></span> )</span> </h3>
  25. <div class="method">
  26. <div class="description">
  27. <p>Constructs a new geometry.</p>
  28. </div>
  29. <table class="params">
  30. <tbody>
  31. <tr>
  32. <td class="name">
  33. <strong>landscape</strong>
  34. </td>
  35. <td class="description last">
  36. <p>A mesh representing the landscape. Trees will be positioned
  37. randomly on the landscape's surface.</p>
  38. </td>
  39. </tr>
  40. </tbody>
  41. </table>
  42. </div>
  43. </div>
  44. <h2 class="subsection-title">Source</h2>
  45. <p>
  46. <a href="https://github.com/mrdoob/three.js/blob/master/examples/jsm/misc/RollerCoaster.js" translate="no" target="_blank" rel="noopener">examples/jsm/misc/RollerCoaster.js</a>
  47. </p>
  48. </article>
  49. </section>
  50. <script src="../scripts/linenumber.js"></script>
  51. <script src="../scripts/page.js"></script>
  52. </body>
  53. </html>
粤ICP备19079148号