Cylindrical.html 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>Cylindrical - 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">Cylindrical</h1>
  13. <section>
  14. <header>
  15. <div class="class-description"><p>This class can be used to represent points in 3D space as
  16. <a href="https://en.wikipedia.org/wiki/Cylindrical_coordinate_system" target="_blank" rel="noopener">Cylindrical coordinates</a>.</p></div>
  17. </header>
  18. <article>
  19. <div class="container-overview">
  20. <h2>Constructor</h2>
  21. <h3 class="name name-method" id="Cylindrical" translate="no">new <a href="#Cylindrical">Cylindrical</a><span class="signature">( radius : <span class="param-type">number</span>, theta : <span class="param-type">number</span>, y : <span class="param-type">number</span> )</span> </h3>
  22. <div class="method">
  23. <div class="description">
  24. <p>Constructs a new cylindrical.</p>
  25. </div>
  26. <table class="params">
  27. <tbody>
  28. <tr>
  29. <td class="name">
  30. <strong>radius</strong>
  31. </td>
  32. <td class="description last">
  33. <p>The distance from the origin to a point in the x-z plane.</p>
  34. <p>Default is <code>1</code>.</p>
  35. </td>
  36. </tr>
  37. <tr>
  38. <td class="name">
  39. <strong>theta</strong>
  40. </td>
  41. <td class="description last">
  42. <p>A counterclockwise angle in the x-z plane measured in radians from the positive z-axis.</p>
  43. <p>Default is <code>0</code>.</p>
  44. </td>
  45. </tr>
  46. <tr>
  47. <td class="name">
  48. <strong>y</strong>
  49. </td>
  50. <td class="description last">
  51. <p>The height above the x-z plane.</p>
  52. <p>Default is <code>0</code>.</p>
  53. </td>
  54. </tr>
  55. </tbody>
  56. </table>
  57. </div>
  58. </div>
  59. <h2 class="subsection-title">Properties</h2>
  60. <div class="member">
  61. <h3 class="name" id="radius" translate="no">.<a href="#radius">radius</a><span class="type-signature"> : number</span> </h3>
  62. <div class="description">
  63. <p>The distance from the origin to a point in the x-z plane.</p>
  64. <p>Default is <code>1</code>.</p>
  65. </div>
  66. </div>
  67. <div class="member">
  68. <h3 class="name" id="theta" translate="no">.<a href="#theta">theta</a><span class="type-signature"> : number</span> </h3>
  69. <div class="description">
  70. <p>A counterclockwise angle in the x-z plane measured in radians from the positive z-axis.</p>
  71. <p>Default is <code>0</code>.</p>
  72. </div>
  73. </div>
  74. <div class="member">
  75. <h3 class="name" id="y" translate="no">.<a href="#y">y</a><span class="type-signature"> : number</span> </h3>
  76. <div class="description">
  77. <p>The height above the x-z plane.</p>
  78. <p>Default is <code>0</code>.</p>
  79. </div>
  80. </div>
  81. <h2 class="subsection-title">Methods</h2>
  82. <h3 class="name name-method" id="clone" translate="no">.<a href="#clone">clone</a><span class="signature">()</span><span class="type-signature"> : <a href="Cylindrical.html">Cylindrical</a></span> </h3>
  83. <div class="method">
  84. <div class="description">
  85. <p>Returns a new cylindrical with copied values from this instance.</p>
  86. </div>
  87. <dl class="details">
  88. <dt class="tag-returns"><strong>Returns:</strong> A clone of this instance.</dt>
  89. </dl>
  90. </div>
  91. <h3 class="name name-method" id="copy" translate="no">.<a href="#copy">copy</a><span class="signature">( other : <span class="param-type"><a href="Cylindrical.html">Cylindrical</a></span> )</span><span class="type-signature"> : <a href="Cylindrical.html">Cylindrical</a></span> </h3>
  92. <div class="method">
  93. <div class="description">
  94. <p>Copies the values of the given cylindrical to this instance.</p>
  95. </div>
  96. <table class="params">
  97. <tbody>
  98. <tr>
  99. <td class="name">
  100. <strong>other</strong>
  101. </td>
  102. <td class="description last">
  103. <p>The cylindrical to copy.</p>
  104. </td>
  105. </tr>
  106. </tbody>
  107. </table>
  108. <dl class="details">
  109. <dt class="tag-returns"><strong>Returns:</strong> A reference to this cylindrical.</dt>
  110. </dl>
  111. </div>
  112. <h3 class="name name-method" id="set" translate="no">.<a href="#set">set</a><span class="signature">( radius : <span class="param-type">number</span>, theta : <span class="param-type">number</span>, y : <span class="param-type">number</span> )</span><span class="type-signature"> : <a href="Cylindrical.html">Cylindrical</a></span> </h3>
  113. <div class="method">
  114. <div class="description">
  115. <p>Sets the cylindrical components by copying the given values.</p>
  116. </div>
  117. <table class="params">
  118. <tbody>
  119. <tr>
  120. <td class="name">
  121. <strong>radius</strong>
  122. </td>
  123. <td class="description last">
  124. <p>The radius.</p>
  125. </td>
  126. </tr>
  127. <tr>
  128. <td class="name">
  129. <strong>theta</strong>
  130. </td>
  131. <td class="description last">
  132. <p>The theta angle.</p>
  133. </td>
  134. </tr>
  135. <tr>
  136. <td class="name">
  137. <strong>y</strong>
  138. </td>
  139. <td class="description last">
  140. <p>The height value.</p>
  141. </td>
  142. </tr>
  143. </tbody>
  144. </table>
  145. <dl class="details">
  146. <dt class="tag-returns"><strong>Returns:</strong> A reference to this cylindrical.</dt>
  147. </dl>
  148. </div>
  149. <h3 class="name name-method" id="setFromCartesianCoords" translate="no">.<a href="#setFromCartesianCoords">setFromCartesianCoords</a><span class="signature">( x : <span class="param-type">number</span>, y : <span class="param-type">number</span>, z : <span class="param-type">number</span> )</span><span class="type-signature"> : <a href="Cylindrical.html">Cylindrical</a></span> </h3>
  150. <div class="method">
  151. <div class="description">
  152. <p>Sets the cylindrical components from the given Cartesian coordinates.</p>
  153. </div>
  154. <table class="params">
  155. <tbody>
  156. <tr>
  157. <td class="name">
  158. <strong>x</strong>
  159. </td>
  160. <td class="description last">
  161. <p>The x value.</p>
  162. </td>
  163. </tr>
  164. <tr>
  165. <td class="name">
  166. <strong>y</strong>
  167. </td>
  168. <td class="description last">
  169. <p>The x value.</p>
  170. </td>
  171. </tr>
  172. <tr>
  173. <td class="name">
  174. <strong>z</strong>
  175. </td>
  176. <td class="description last">
  177. <p>The x value.</p>
  178. </td>
  179. </tr>
  180. </tbody>
  181. </table>
  182. <dl class="details">
  183. <dt class="tag-returns"><strong>Returns:</strong> A reference to this cylindrical.</dt>
  184. </dl>
  185. </div>
  186. <h3 class="name name-method" id="setFromVector3" translate="no">.<a href="#setFromVector3">setFromVector3</a><span class="signature">( v : <span class="param-type"><a href="Vector3.html">Vector3</a></span> )</span><span class="type-signature"> : <a href="Cylindrical.html">Cylindrical</a></span> </h3>
  187. <div class="method">
  188. <div class="description">
  189. <p>Sets the cylindrical components from the given vector which is assumed to hold
  190. Cartesian coordinates.</p>
  191. </div>
  192. <table class="params">
  193. <tbody>
  194. <tr>
  195. <td class="name">
  196. <strong>v</strong>
  197. </td>
  198. <td class="description last">
  199. <p>The vector to set.</p>
  200. </td>
  201. </tr>
  202. </tbody>
  203. </table>
  204. <dl class="details">
  205. <dt class="tag-returns"><strong>Returns:</strong> A reference to this cylindrical.</dt>
  206. </dl>
  207. </div>
  208. <h2 class="subsection-title">Source</h2>
  209. <p>
  210. <a href="https://github.com/mrdoob/three.js/blob/master/src/math/Cylindrical.js" translate="no" target="_blank" rel="noopener">src/math/Cylindrical.js</a>
  211. </p>
  212. </article>
  213. </section>
  214. <script src="../scripts/linenumber.js"></script>
  215. <script src="../scripts/page.js"></script>
  216. </body>
  217. </html>
粤ICP备19079148号