module-ParametricFunctions.html 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>ParametricFunctions - 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. <h1 translate="no">ParametricFunctions</h1>
  13. <section>
  14. <header>
  15. </header>
  16. <article>
  17. <h2 class="subsection-title">Import</h2>
  18. <p><span translate="no">ParametricFunctions</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>
  19. <pre><code class="language-js">import * as ParametricFunctions from 'three/addons/geometries/ParametricFunctions.js';</code></pre>
  20. <div class="container-overview">
  21. </div>
  22. <h2 class="subsection-title">Methods</h2>
  23. <h3 class="name name-method" id="~klein" translate="no">.<a href="#~klein">klein</a><span class="signature">( v : <span class="param-type">number</span>, u : <span class="param-type">number</span>, target : <span class="param-type"><a href="Vector3.html">Vector3</a></span> )</span> <span class="type-signature">(inner) </span></h3>
  24. <div class="method">
  25. <div class="description">
  26. <p>A parametric function representing the Klein bottle.</p>
  27. </div>
  28. <table class="params">
  29. <tbody>
  30. <tr>
  31. <td class="name">
  32. <strong>v</strong>
  33. </td>
  34. <td class="description last">
  35. <p>The <code>v</code> coordinate on the surface in the range <code>[0,1]</code>.</p>
  36. </td>
  37. </tr>
  38. <tr>
  39. <td class="name">
  40. <strong>u</strong>
  41. </td>
  42. <td class="description last">
  43. <p>The <code>u</code> coordinate on the surface in the range <code>[0,1]</code>.</p>
  44. </td>
  45. </tr>
  46. <tr>
  47. <td class="name">
  48. <strong>target</strong>
  49. </td>
  50. <td class="description last">
  51. <p>The target vector that is used to store the method's result.</p>
  52. </td>
  53. </tr>
  54. </tbody>
  55. </table>
  56. </div>
  57. <h3 class="name name-method" id="~mobius" translate="no">.<a href="#~mobius">mobius</a><span class="signature">( u : <span class="param-type">number</span>, t : <span class="param-type">number</span>, target : <span class="param-type"><a href="Vector3.html">Vector3</a></span> )</span> <span class="type-signature">(inner) </span></h3>
  58. <div class="method">
  59. <div class="description">
  60. <p>A parametric function representing a flat mobius strip.</p>
  61. </div>
  62. <table class="params">
  63. <tbody>
  64. <tr>
  65. <td class="name">
  66. <strong>u</strong>
  67. </td>
  68. <td class="description last">
  69. <p>The <code>u</code> coordinate on the surface in the range <code>[0,1]</code>.</p>
  70. </td>
  71. </tr>
  72. <tr>
  73. <td class="name">
  74. <strong>t</strong>
  75. </td>
  76. <td class="description last">
  77. <p>The <code>v</code> coordinate on the surface in the range <code>[0,1]</code>.</p>
  78. </td>
  79. </tr>
  80. <tr>
  81. <td class="name">
  82. <strong>target</strong>
  83. </td>
  84. <td class="description last">
  85. <p>The target vector that is used to store the method's result.</p>
  86. </td>
  87. </tr>
  88. </tbody>
  89. </table>
  90. </div>
  91. <h3 class="name name-method" id="~mobius3d" translate="no">.<a href="#~mobius3d">mobius3d</a><span class="signature">( u : <span class="param-type">number</span>, t : <span class="param-type">number</span>, target : <span class="param-type"><a href="Vector3.html">Vector3</a></span> )</span> <span class="type-signature">(inner) </span></h3>
  92. <div class="method">
  93. <div class="description">
  94. <p>A parametric function representing a volumetric mobius strip.</p>
  95. </div>
  96. <table class="params">
  97. <tbody>
  98. <tr>
  99. <td class="name">
  100. <strong>u</strong>
  101. </td>
  102. <td class="description last">
  103. <p>The <code>u</code> coordinate on the surface in the range <code>[0,1]</code>.</p>
  104. </td>
  105. </tr>
  106. <tr>
  107. <td class="name">
  108. <strong>t</strong>
  109. </td>
  110. <td class="description last">
  111. <p>The <code>v</code> coordinate on the surface in the range <code>[0,1]</code>.</p>
  112. </td>
  113. </tr>
  114. <tr>
  115. <td class="name">
  116. <strong>target</strong>
  117. </td>
  118. <td class="description last">
  119. <p>The target vector that is used to store the method's result.</p>
  120. </td>
  121. </tr>
  122. </tbody>
  123. </table>
  124. </div>
  125. <h3 class="name name-method" id="~plane" translate="no">.<a href="#~plane">plane</a><span class="signature">( u : <span class="param-type">number</span>, v : <span class="param-type">number</span>, target : <span class="param-type"><a href="Vector3.html">Vector3</a></span> )</span> <span class="type-signature">(inner) </span></h3>
  126. <div class="method">
  127. <div class="description">
  128. <p>A parametric function representing a flat plane.</p>
  129. </div>
  130. <table class="params">
  131. <tbody>
  132. <tr>
  133. <td class="name">
  134. <strong>u</strong>
  135. </td>
  136. <td class="description last">
  137. <p>The <code>u</code> coordinate on the surface in the range <code>[0,1]</code>.</p>
  138. </td>
  139. </tr>
  140. <tr>
  141. <td class="name">
  142. <strong>v</strong>
  143. </td>
  144. <td class="description last">
  145. <p>The <code>v</code> coordinate on the surface in the range <code>[0,1]</code>.</p>
  146. </td>
  147. </tr>
  148. <tr>
  149. <td class="name">
  150. <strong>target</strong>
  151. </td>
  152. <td class="description last">
  153. <p>The target vector that is used to store the method's result.</p>
  154. </td>
  155. </tr>
  156. </tbody>
  157. </table>
  158. </div>
  159. <h2 class="subsection-title">Source</h2>
  160. <p>
  161. <a href="https://github.com/mrdoob/three.js/blob/master/examples/jsm/geometries/ParametricFunctions.js" translate="no" target="_blank" rel="noopener">examples/jsm/geometries/ParametricFunctions.js</a>
  162. </p>
  163. </article>
  164. </section>
  165. <script src="../scripts/linenumber.js"></script>
  166. <script src="../scripts/page.js"></script>
  167. </body>
  168. </html>
粤ICP备19079148号